Getting Started with M68K Coral 66: Compilation System for the Motorola M68000 Family | ||
---|---|---|
Prev | Appendix B. Options for the M68000 Family | Next |
Certain pseudo opcodes are permitted for branch instructions. They expand to the shortest branch instructions that reach the target. Generally these mnemonics are made by substituting j for b at the start of a Motorola mnemonic.
The following table summarizes the pseudo-operations.
Table B-1. Assembler Pseudo Operations
Displacement | |||||
---|---|---|---|---|---|
Pseudo-Op | BYTE | WORD | 68020 LONG | 68000/10 LONG | non-PC relative |
jbsr | bsr | bsrw | bsrl | jsr | jsr |
jra | bras | bra | bral | jmp | jmp |
jXX[a] | bXXs | bXX | bXXl | bNXs; jmpl | bNXs; jmp |
dbXX[a] | dbXXs | dbXX | dbXX; bra; jmpl | ||
fjXX[a] | fbXXw | fbXXw | fbXXl | N/A | fbNXw; jmp |
Notes: a. XX: condition, NX: negative of condition, see full description below. |
These are the simplest jump pseudo-operations; they always map to one particular machine instruction, depending on the displacement to the branch target.
Here, jXX stands for an entire family of pseudo-operations, where XX is a conditional branch or condition-code test. The full list of pseudo-ops in this family is:
jhi | jls | jcc | jcs | jne | jeq | jvc | jvs |
jpl | jmi | jge | jlt | jgt | jle |
For the cases of non-PC relative displacements and long displacements on the 68000 or 68010, the Assembler issues a longer code fragment in terms of NX, the opposite condition to XX. For example, for the non-PC relative case:
gives
The full family of pseudo-operations covered here is:
dbhi | dbls | dbcc | dbcs | dbne | dbeq | dbvc | dbvs |
dbpl | dbmi | dbge | dblt | dbgt | dble | dbf | dbra |
dbt |
Other than for word and byte displacements, when the source reads dbXX foo, the Assembler emits
This family includes the following:
fjne | fjeq | fjge | fjlt | fjgt | fjle | fjf | fjt |
fjgl | fjgle | fjnge | fjngl | fjngle | fjngt | fjnle | fjnlt |
fjoge | fjogl | fjogt | fjole | fjolt | fjor | fjseq | fjsf |
fjsne | fjst | fjueq | fjuge | fjugt | fjule | fjult | fjun |
For branch targets that are not PC relative, the Assembler emits:
when it encounters fjXX foo.