Skip to content

Commit

Permalink
document these
Browse files Browse the repository at this point in the history
  • Loading branch information
xubiod committed Mar 7, 2024
1 parent 7354b37 commit 8c6af60
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 4 deletions.
3 changes: 2 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"cSpell.words": [
"NMOS"
"NMOS",
"toggleable"
]
}
20 changes: 17 additions & 3 deletions cpu/core.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,24 @@ type Core struct {
// bytes) as an operand.
execMapShort map[byte]func(uint16)

execMapNilCMOS map[byte]func()
execMapByteCMOS map[byte]func(uint8)
// The byte -> implementation map for instructions with no operands for 65c02
// instructions. Separated to make CMOS toggleable.
execMapNilCMOS map[byte]func()

// The byte -> implementation map for instructions with a byte as an operand
// for 65c02 instructions. Signed or not is instruction dependent, and separated
// to make CMOS toggleable.
execMapByteCMOS map[byte]func(uint8)

// The byte -> implementation map for instructions with two byte operands for
// 65c02 instructions, which are for the branch if bit set/cleared instructions
// for how unique their structure is. Separated to make CMOS toggleable.
execMapBitBranchCMOS map[byte]func(uint8, uint8)
execMapShortCMOS map[byte]func(uint16)

// The byte -> implementation map for instructions with an unsigned short (2
// bytes) as an operand for 65c02 instructions. Separated to make CMOS
// toggleable.
execMapShortCMOS map[byte]func(uint16)

writingPointer uint16 // The pointer to writing to memory with `*Core.Write()`.
}
Expand Down

0 comments on commit 8c6af60

Please sign in to comment.