MCPcopy Create free account
hub / github.com/AppleWin/AppleWin / _6502_IsOpcodeBranch

Function _6502_IsOpcodeBranch

source/Debugger/Debugger_Assembler.cpp:912–934  ·  view source on GitHub ↗

===========================================================================

Source from the content-addressed store, hash-verified

910
911//===========================================================================
912bool _6502_IsOpcodeBranch ( int iOpcode )
913{
914 // 76543210 Bit
915 // xxx10000 Branch
916 if (iOpcode == OPCODE_BRA)
917 return true;
918
919 if ((iOpcode & 0x1F) != 0x10) // low nibble not zero?
920 return false;
921
922 if ((iOpcode >> 4) & 1)
923 return true;
924
925// (nOpcode == 0x10) || // BPL
926// (nOpcode == 0x30) || // BMI
927// (nOpcode == 0x50) || // BVC
928// (nOpcode == 0x70) || // BVS
929// (nOpcode == 0x90) || // BCC
930// (nOpcode == 0xB0) || // BCS
931// (nOpcode == 0xD0) || // BNE
932// (nOpcode == 0xF0) || // BEQ
933 return false;
934}
935
936
937//===========================================================================

Callers 1

_6502_CalcRelativeOffsetFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected