opcodedata

package
v0.0.0-...-5cf090d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 9, 2023 License: BSD-3-Clause Imports: 3 Imported by: 0

Documentation

Overview

Package opcodedata provides JSON based opcode data

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Document

type Document struct {
	Unprefixed InstructionMap `json:"unprefixed"`
	CBPrefixed InstructionMap `json:"cbprefixed"`
}
var OpcodeData Document

OpcodeData exports the root JSON document as a variable

type Flags

type Flags struct {
	Z string
	N string
	H string
	C string
}

type InstructionInfo

type InstructionInfo struct {
	Mnemonic  string     `json:"mnemonic"`
	Bytes     int        `json:"bytes"`
	Cycles    []int      `json:"cycles"`
	Operands  []*Operand `json:"operands"`
	Immediate bool       `json:"immediate"`
	Flags     Flags      `json:"flags"`
}

type InstructionMap

type InstructionMap map[Opcode]*InstructionInfo

type Opcode

type Opcode = string

type Operand

type Operand struct {
	Name      string `json:"name"`
	Bytes     int    `json:"bytes"`
	Immediate bool   `json:"immediate"`
	Increment bool   `json:"increment"`
	Decrement bool   `json:"decrement"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL