Signature byte

In 65x parlance, a signature byte is the second byte of certain two-byte instructions, including:


 * BRK
 * COP
 * WDM

When a programmer has sprinkled many BRKs throughout a large codebase, it can be difficult to tell which BRK breakpoint has been tripped. That is why it can be useful to specify a unique signature byte after BRK, allowing up to 256 unique breakpoints.

For co-processor empowerment, the signature byte can be used to specify which command the co-processor should run.

The signature byte following WDM was originally intended to extend the 65c816's opcode space and allow for up to 256 more unique instructions, but this was never implemented. As of 2023 when using Mesen for SNES homebrew, WDM can be used as an even simpler (because it does not need a handler routine) breakpoint by checking the "Break on.." WDM checkbox in the debugger.