mirror of
https://github.com/cc65/cc65.git
synced 2024-11-19 06:31:31 +00:00
The longbranch macros did not work with numeric addresses
git-svn-id: svn://svn.cc65.org/cc65/trunk@1039 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
f0ed4af252
commit
46209118b1
@ -72,7 +72,10 @@ static const char MacGeneric [] = /* Generic macros */
|
||||
|
||||
static const char MacLongBranch [] = /* Long branch macros */
|
||||
".macro jeq Target\n"
|
||||
" .if .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" .if .match(Target, 0)\n"
|
||||
" bne *+5\n"
|
||||
" jmp Target\n"
|
||||
" .elseif .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" beq Target\n"
|
||||
" .else\n"
|
||||
" bne *+5\n"
|
||||
@ -80,7 +83,10 @@ static const char MacLongBranch [] = /* Long branch macros */
|
||||
" .endif\n"
|
||||
".endmacro\n"
|
||||
".macro jne Target\n"
|
||||
" .if .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" .if .match(Target, 0)\n"
|
||||
" beq *+5\n"
|
||||
" jmp Target\n"
|
||||
" .elseif .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" bne Target\n"
|
||||
" .else\n"
|
||||
" beq *+5\n"
|
||||
@ -88,7 +94,10 @@ static const char MacLongBranch [] = /* Long branch macros */
|
||||
" .endif\n"
|
||||
".endmacro\n"
|
||||
".macro jmi Target\n"
|
||||
" .if .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" .if .match(Target, 0)\n"
|
||||
" bpl *+5\n"
|
||||
" jmp Target\n"
|
||||
" .elseif .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" bmi Target\n"
|
||||
" .else\n"
|
||||
" bpl *+5\n"
|
||||
@ -96,7 +105,10 @@ static const char MacLongBranch [] = /* Long branch macros */
|
||||
" .endif\n"
|
||||
".endmacro\n"
|
||||
".macro jpl Target\n"
|
||||
" .if .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" .if .match(Target, 0)\n"
|
||||
" bmi *+5\n"
|
||||
" jmp Target\n"
|
||||
" .elseif .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" bpl Target\n"
|
||||
" .else\n"
|
||||
" bmi *+5\n"
|
||||
@ -104,7 +116,10 @@ static const char MacLongBranch [] = /* Long branch macros */
|
||||
" .endif\n"
|
||||
".endmacro\n"
|
||||
".macro jcs Target\n"
|
||||
" .if .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" .if .match(Target, 0)\n"
|
||||
" bcc *+5\n"
|
||||
" jmp Target\n"
|
||||
" .elseif .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" bcs Target\n"
|
||||
" .else\n"
|
||||
" bcc *+5\n"
|
||||
@ -112,7 +127,10 @@ static const char MacLongBranch [] = /* Long branch macros */
|
||||
" .endif\n"
|
||||
".endmacro\n"
|
||||
".macro jcc Target\n"
|
||||
" .if .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" .if .match(Target, 0)\n"
|
||||
" bcs *+5\n"
|
||||
" jmp Target\n"
|
||||
" .elseif .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" bcc Target\n"
|
||||
" .else\n"
|
||||
" bcs *+5\n"
|
||||
@ -120,7 +138,10 @@ static const char MacLongBranch [] = /* Long branch macros */
|
||||
" .endif\n"
|
||||
".endmacro\n"
|
||||
".macro jvs Target\n"
|
||||
" .if .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" .if .match(Target, 0)\n"
|
||||
" bvc *+5\n"
|
||||
" jmp Target\n"
|
||||
" .elseif .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" bvs Target\n"
|
||||
" .else\n"
|
||||
" bvc *+5\n"
|
||||
@ -128,7 +149,10 @@ static const char MacLongBranch [] = /* Long branch macros */
|
||||
" .endif\n"
|
||||
".endmacro\n"
|
||||
".macro jvc Target\n"
|
||||
" .if .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" .if .match(Target, 0)\n"
|
||||
" bvs *+5\n"
|
||||
" jmp Target\n"
|
||||
" .elseif .def(Target) .and ((*+2)-(Target) <= 127)\n"
|
||||
" bvc Target\n"
|
||||
" .else\n"
|
||||
" bvs *+5\n"
|
||||
|
Loading…
Reference in New Issue
Block a user