home *** CD-ROM | disk | FTP | other *** search
- Invoking XASM68K.COM
- Pseudo-ops
- Register referencing
- Labels
- Assembly options
- Comment fields
- Overriding automatic size determination
- Symbols
- Constants
- Strings
- Operator precedence
- Automatic conversions
- Addressing mode syntax interpretation
- :Command line to invoke the assembler
-
- XASM68K <filename> ; short form
- XASM68K <object>,<listing>=<source> ; full form
-
- ----------------- Equivalence ----------------
-
- XYZ XYZ.HEX,XYZ.PRN=XYZ.ASM
- ,CON:=XYZ NUL:,CON:=XYZ.ASM
- XYZ,=XYZ XYZ.HEX,NUL:=XYZ.ASM
- XYZ.OBJ=XYZ.SRC XYZ.OBJ,XYZ.PRN=XYZ.SRC
- ,CON:=CON: NUL:,CON:=CON:
-
- Object file may be in Motorola S-record (default)
- or Intel HEX format.
-
- :Pseudo-ops
-
-
- <symbol> SET <expression> ; temp val
- <symbol> EQU <expression> ; perm val
- <symbol> REG <register expression> ; perm val
-
- Note that a size attribute may be tacked onto
- SET or EQU to govern the way string constants
- appearing in the expression are handled. The
- default size is long. String constants are
- left justified according to size and zero
- filled.
-
-
- :Register referencing
-
-
- <register expression> for use in MOVEM
- <Rn> <next reg>
-
- <next reg>
- - <Rn> <next reg>
- / <register expression>
-
- <Rn>
- è A <rnum>
- D <rnum>
-
- :Labels
-
-
- Labels are symbols which receive the current value of
- the program counter.
- For labels beginning in column 1, colon is optional.
- For labels preceded by blanks, colon is required.
-
- :Assembly options
-
-
- OPT <option>,<option>,.....
-
- <option>
- BRL ; long branch forward ref. - default
- BRS ; short branch forward ref.
- FRL ; long absolute fwd. ref. - default
- FRS ; short absolute fwd. ref.
- OBJ-S ; hex file Motorola style - default
- OBJ-H ; hex file Intel style (16 bit address limit)
- NOP1L ; no pass 1 listing - default
- P1L ; pass 1 listing
-
- :Comment fields
-
-
- * <comment>
-
- :Overriding automatic size determination
-
-
- .S & .L may be appended to BRA, BSR, Bcc, JMP and JSR
- to override automatic size determination.
- They may also be appended to absolute address
- operands in other instructions. But, it is necessary
- to isolate the period from a symbol by enclosing
- the symbol in parentheses. This is due to the fact
- that period is a valid character in symbols.
-
- :Symbols
-
-
- <symbol>
- Symbols begin with a letter or period. Additional
- characters may be letters, digits, periods, dollar
- signs and underscores.
-
- * represents the program counter
-
- Symbols may have up to 31 significant characters.
-
- The symbol table is currently of fixed size:
- è 500 Symbols max
- 2000 Characters max
-
- :Constants
-
-
- Constants begin with
- char - '
- hex - $
- octal - @
- binary - %
- decimal - 0 thru 9
-
- :Strings
-
-
- Strings:
- Delimited by '
- '' represents '
-
- :Operator precedence
-
- Expressions and symbols are classified as constants
- or addresses.
-
- Operators for expressions (in precedence group order)
-
- + -
-
- * / only implemented for 16 bits now
- \ mod - only 16 bits for now
-
- & AND
- ! | both allowed for OR
- ^ exclusive OR
-
- << shift left
- >> shift right
-
- - unary minus
- ~ unary NOT
- Except for + and -, only expressions which evaluate
- constants are allowed as operands to operators. For
- + and -, (a + a) and (c - a) produce errors. Embedded
- spaces are not allowed in expressions (spaces serve as
- field delimiters).
- :Automatic conversions
-
-
- ADD #e ,<ea> ADDQ or ADDI when possible
- <ea> ,An ADDA
-
- SUB #e ,<ea> SUBQ or SUBI when possible
- <ea> ,An ADDA
-
- CMP #e ,<ea> CMPI when possible
- (An)+,(An)+ CMPM
- <ea> ,An CMPA
-
- AND #e ,<ea> ANDI when possible
-
- OR #e ,<ea> ORI when possible
-
- EOR #e ,<ea> EORI when possible
- :Addressing Mode Syntax Interpretation
-
- c expression must evaluate to constant
- a expression must evaluate to address
- b expression may evaluate to either
-
- Syntax used Interpreted as Mode,reg
-
- # e #c 7,4
-
- D n Dn 0
-
- A n An 1
-
- - ( A n ) -(An) 4
-
- ( A n ) + (An)+ 3
-
- ( A n ) (An) 2
- Syntax used Interpreted as Mode,reg
-
- ( A n , R i )
- ( A n , R i . W ) 0(An,Ri.s) 6
- ( A n , R i . L )
-
- e ( A n , R i )
- e ( A n , R i . W ) c(An,Ri.s) 6
- e ( A n , R i . L )
-
- e ( A n ) c(An) 5
-
- e ( D i )
-
- e ( R i . W ) a(PC,Ri.s) 7,3
- e ( R i . L )
-
- Syntax used Interpreted as Mode,reg
-
- e ( PC , R i )
- e ( PC , R i . W ) a(PC,Ri.s) 7,3
- e ( PC , R i . L )
-
- e ( PC ) a(PC) 7,2
-
- e . L b.L 7,1 **
-
- e . S b.S 7,0 **
-
- e b 7,0 or 7,1 **
-
- ***¬ S╨ ma∙ bσ useΣ fo≥ A╖ anywherσ Aε appears¼á bu⌠ no⌠ wherσ RΘ appear≤ ì
- fo≥ inde° specification.
-
- *¬á Explici⌠á rangσ specificatioε viß (.╙ o≥ .L⌐ override≤á thσ ì
- automatiπá rangσ selectioε fo≥ absolutσ addressing«á Fo≥ auto¼á iµá thσ ì
- expressioε contain≤ forwarΣ references¼á thσ rangσ i≤ determineΣ b∙á thσ ì
- "FRóá optioεá currentl∙á iε effec⌠ (FR╠ default)«á Iµá thσá expressioε ì
- contain≤ n∩ forwarΣ references¼ thσ rangσ i≤ madσ shor⌠ iµ thσ expressioε ì
- lie≤ betweeε -3276╕ anΣ +32767.
-