home *** CD-ROM | disk | FTP | other *** search
/ ARM Club 1 / ARM_CLUB_CD.iso / contents / apps / program / a / as1_23 / source / HelpAs next >
Encoding:
Text File  |  1993-12-26  |  61.5 KB  |  1,391 lines

  1. %ltorg
  2. Usage:     ltorg
  3. Summary:   Tells the assembler that it is okey to place literals at this
  4.            position. An ltorg is inserted at the end of all areas but it 
  5.            can be necessary to insert ltorgs at other positions in the file
  6.            as there must not be more than 4095 bytes between any use of a
  7.            litarate load (e.g., ldr r0,=31415) and the closest literate area.
  8.  
  9. %lnk
  10. Usage:     lnk filename
  11. Summary:   The assembler switches input to the given file. The rest of the
  12.            current file is ignored.
  13.  
  14. %get
  15. Usage:     get filename 
  16. Summary:   The assembler switches input to the new file, and returns to
  17.            the old file afterwords. The result is as if the new file was
  18.            textually inserted at the position of get.
  19.  
  20. %bin
  21. Usage:     bin filename
  22. Summary:   The assembler includes the contents of the file in the object
  23.            file. No check is done of the contents of the file.
  24.  
  25. %rn
  26. Usage:     <Identifier> rn <Expression>
  27. Summary:   The identifier can now be used as a cpu register in future
  28.            instructions. The expression must be in the interval 0 to 15
  29.            inclusive.
  30.  
  31. %fn
  32. Usage:     <Identifier> rn <Expression>
  33. Summary:   The identifier can now be used as a fpu register in future
  34.            instructions. The expression must be in the interval 0 to 7
  35.            inclusive
  36.  
  37. %cn
  38. Usage:     <Identifier> rn <Expression>
  39. Summary:   The identifier can now be used as a coprocessor register in
  40.            future instructions. The expression must be in the interval 
  41.            0 to 15 inclusive.
  42.  
  43. %equ
  44. Usage:     <Identifier> equ <Expression>
  45. Summary:   Defines an numerical identifier. '*' is a short form of equ.
  46.  
  47. %*
  48. Usage:     <Identifier> * <Expression>
  49. Summary:   Defines an numerical identifier. '*' is a short form of equ.
  50.  
  51. %dcb
  52. Usage:          dcb <Expression> {,<Expression>}*
  53. Summary:   Dcb defines one or more bytes. String constants are allowed as
  54.            expressions, which causes the characters of the string to be
  55.            loaded in consecutive bytes. '=' is a short form of dcb.
  56.  
  57. %=
  58. Usage:          = <Expression> {,<Expression>}*
  59. Summary:   '=' defines one or more bytes. String constants are allowed as
  60.            expressions, which causes the characters of the string to be
  61.            loaded in consecutive bytes. '=' is a short form of dcb.
  62.            (See ldr and str for alternative use of '='.)
  63.  
  64. %dcw
  65. Usage:          dcw <Expression> {,<Expression>}*
  66. Summary:   Dcw defines one or more 16-bits word. String constants can not
  67.            contain more than two characters and are converted to 16-bits
  68.            integers, 1:st character + (2:nd character << 8).
  69.  
  70. %dcd
  71. Usage:          dcd <Expression> {,<Expression>}*
  72. Summary:   Dcw defines one or more 32-bits word. String constants can not
  73.            contain more than four characters and are converted to 32-bits
  74.            integers, 1:st character + (2:nd character << 8) + (3:rd
  75.            character << 16) + (4:th character << 24).
  76.            '&' is a short form of dcd.
  77.  
  78. %&
  79. Usage:          & <Expression> {,<Expression>}*
  80. Summary:   '&' defines one or more 32-bits word. String constants can not
  81.            contain more than four characters and are converted to 32-bits
  82.            integers, 1:st character + (2:nd character << 8) + (3:rd
  83.            character << 16) + (4:th character << 24).
  84.            '&' is a short form of dcd.
  85.  
  86. %dcfs
  87. Usage:          dcfs <FloatExpression> {,<FloatExpression>}*
  88. Summary:   Dcfs defines one or more 32-bits floats.
  89.  
  90. %dcfd
  91. Usage:          dcfd <FloatExpression> {,<FloatExpression>}*
  92. Summary:   Dcfd defines one or more 64-bits floats.
  93.  
  94. %dcfe
  95. Usage:          dcfe <FloatExpression> {,<FloatExpression>}*
  96. Summary:   Dcfe defines one or more 96-bits floats.
  97. Note:      Dcfe is not implemented!
  98.  
  99. %dcfp
  100. Usage:          dcfp <FloatExpression> {,<FloatExpression>}*
  101. Summary:   Dcfp defines one or more 96-bits packed decimal floats.
  102. Note:      Dcfp is not implemented!
  103.  
  104. %area
  105. Usage:          area <Identifier> {,Attributes}*
  106. Summary:   Area selects a new area for storage. If the identifier is new
  107.            then a new area will be defined with the selected attributes.
  108.            It is not necessary to give the attributes if an old area is
  109.            reselected. Currently implemented attributes are:
  110.            CODE      This area is for code, this is only for the linker.
  111.            DATA      This area is for data, this is only for the linker.
  112.            NOINIT    This area is for zero initsialized data. The assembler
  113.                      will check that this is true.
  114.            READONLY  This area is read only, this is only for the linker.
  115.  
  116. %CODE
  117. Usage:          area <Identifier> , CODE {,<Attributes>}*
  118. Summary:   This tells the linker that this area contains code.
  119.            Other attributes are DATA,NOINIT and READONLY.    
  120.  
  121. %DATA
  122. Usage:          area <Identifier> , DATA {,<Attributes>}*
  123. Summary:   This tells the linker that this area contains data.
  124.            Other attributes are CODE,NOINIT and READONLY.    
  125.  
  126. %NOINIT
  127. Usage:          area <Identifier> , NOINIT {,<Attributes>}*
  128. Summary:   This tells the linker that this area contains zero initsialized
  129.            data. The assembler will check that this is true.
  130.            Other attributes are CODE,DATA and READONLY.    
  131.  
  132. %READONLY
  133. Usage:          area <Identifier> , READONLY {,<Attributes>}*
  134. Summary:   This tells the linker that this area is read only.
  135.            Other attributes are CODE,DATA and NOINIT.
  136.     
  137.  
  138. %align
  139. Usage:          align <Expression>
  140. Summary:   Align moves the next item in the current area to an address which
  141.            is an even multiplier of the expression. Note that the linker
  142.            does not support bigger alignment than four.
  143. Note:      The pad bytes are NOT set to zero! No default value exist as in
  144.            Acorn's assembler and it is not possible to give an offset.
  145.  
  146. %%
  147. Usage:          % <Expression>
  148. Summary:   '%' reserves the given numbers of bytes in the current area.
  149. Note:      The bytes are NOT set to zero!
  150.  
  151. %entry
  152. Usage:          entry
  153. Summary:   This is the entry point for the finished program. 
  154.  
  155. %^
  156. Usage:          ^ <Expression>
  157. Summary:   '^' sets the storage counter used in '#' for laying out areas.
  158. Note:      It is not possible to create register relative addresses as in 
  159.            Acorn's assembler.
  160. %#
  161. Usage:     <Identifier> # <Expression>
  162. Summary:   '#' sets the identifier equal to the storage counter, and then
  163.            increments the counter with the expression. The expression must
  164.            be positive.
  165.  
  166. %{VAR}
  167. Usage:     Don't, use @ instead.
  168. Summary:   This is a synonym for @ in Acorn's assembler it is not availible
  169.            in this assembler.
  170.  
  171. %{PC}
  172. Usage:     Don't, use . instead.
  173. Summary:   This is a synonym for . in Acorn's assembler it is not availible
  174.            in this assembler.
  175.  
  176. %.
  177. E.g:       CurrentPosition *  .  ; Gets the current position in the current area
  178. Summary:   ',' returns the current position in the current area.
  179.  
  180. %@
  181. E.g:       FillArea   # 10-@     ; Makes the storage counter equal to 10,
  182.                                  ; or gives an error if it already is larger.
  183. Summary:   '@' returns the current value of the storage counter.
  184.  
  185. %globl
  186. Usage:          globl <Identifier>
  187. Summary:   Globl instructs the assembler, and the linker, to keep this symbol
  188.            in the object file. Globl is also used to introduce an identifier 
  189.            which is defined in another assembler file. The later usage is
  190.            not compulsary as the assembler treats all undefined identifier as
  191.            introduced by globl. This behaviour may however change.
  192. Note:      Globl will probably be removed in future versions, use export, if the
  193.            identifier is defined in this assembler file, and import if it is not.
  194.  
  195. %export
  196. Usage:          export <Identifier>
  197. Summary:   Export instructs the assembler, and the linker, to keep this symbol
  198.            in the object file.
  199.  
  200. %import
  201. Usage:          import <Identifier> {, WEAK }
  202. Summary:   Import is used to introduce an identifier which is defined in
  203.            another assembler file. It is not compulsary as the assembler
  204.            treats all undefined identifier as if they where imported. But
  205.            it is nice for people who read the code, and the assembler may
  206.            demand it in future versions.
  207.            The attribute WEAK makes the reference a weak symbol i.e., it's
  208.            not an error if the symbol isn't resolved during linking.
  209.  
  210. %Cond
  211. Usage:     Don't
  212. Summary:   This is only a short description of the condition codes.
  213.            All instructons can take a condition code. the condition code is
  214.            written directly after the mnemonic and before options, if it is
  215.            present, e.g.:
  216.              addeq         add  if equal.
  217.              orrgts        or if greater than, and update flags.
  218.              bcs           branch if carry set.
  219.              ldmneib       load multiple, with increment before, if not equal.
  220.            The instruction will be executed if the conition is true.
  221.            The possible conditions are:  and they are true if:
  222.                al     Always,            always.
  223.                nv     Never,             never, this condition code should not be used!
  224.                                          Use mov r0,r0 if a no-operation is needed.
  225.                eq     Equal,             Z is set.
  226.                ne     Not Equal,         Z is cleared.
  227.                vs     Overflow,          V is set.
  228.                vc     No overflow,       V is cleared.
  229.                mi     Minus,             N is set.
  230.                pl     Plus,              N is cleared.
  231.                cs     Carry set,         C is set.
  232.                cc     Carry clear,       C is cleared.
  233.                hi     Higher,            C is set and Z is cleared.
  234.                ls     Lower or same,     C is cleared or Z is set. 
  235.                ge     Greater or equal,  N is cleared and V is cleared,
  236.                                                or N is set and V is set.
  237.                lt     Less,              N is set and V is cleared,
  238.                                                or N is cleared and V is set.
  239.                gt     Greater,           'ge' is true and Z is cleared. 
  240.                le     Less or equal,     'lt' is true or Z is set. 
  241.                hs     Higher or same,    'cs' is true.
  242.                lo     Lower              'cc' is true.
  243.            If no condition is given then 'al' (Always) is assumed.
  244.  
  245. %ShiftOp
  246. Usage:     Don't
  247. Summary:   This is only a short description of the possible shift operations.
  248.            It is sometimes possible to shift the right operand in an instruction.
  249.            The shift amount is a 5 bit constant or, in some instructions, the
  250.            contents of the lowest byte in a register. E.g.:
  251.              r0,lsl #1     shift r0 left one step.
  252.              r2,ror r1     rotate r2 right the number of step given in lowest
  253.                            byte in r1.
  254.              r3,rrx        rotate r3, extended with the carry, right one step.
  255.            Possible shifts are:             Number of steps (if constant):
  256.                lsl  Logical   shift left      0 to 31
  257.                lsr  Logical   shift right     0 to 32
  258.                asl  Atitmetic shift left      0 to 32
  259.                asr  Aritmetic shift right     0 to 32
  260.                ror  Rotate rigth              0 to 31
  261.                rrx  Rotate right extended     Always 1 step.
  262.            For a description of how the shift is done see the shift
  263.            operation in question.
  264.  
  265. %lsl
  266. E.g.:           adds r1,r2,r3,lsl #2  ; r1 = r2+r3<<2 = r2+r3*4
  267. Summary:  Lsl shifts a register left inserting zeroes at the right end:
  268.              C<--bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb<--0
  269.           The last bit moved out from the register is inserted in the carry
  270.           if the main instruction does not affect the carry and the s-option
  271.           is given, e.g., the lsl in the example will not set the carry as add
  272.           sets the carry itself. The number of steps can be from 0 to 31
  273.           inclusive.
  274.           It is sometimes possible to shift by the context of a register:
  275.             adds r1,r2,r3,lsl r4
  276.           Only the eigth lowest bits in the register are used allowing shifts
  277.           of up to 255 steps.
  278. Note:     Lsl is identical to asl.
  279.  
  280. %lsr
  281. E.g.:           adds r1,r2,r3,lsr #2  ; r1 = r2+r3>>2 = r2+r3/4 (if r3 is unsigned)
  282. Summary:  Lsr shifts a register right inserting zeroes at the left end:
  283.              0-->bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb-->C
  284.           The last bit moved out from the register is inserted in the carry
  285.           if the main instruction does not affect the carry and the s-option
  286.           is given, e.g., the lsr in the example will not set the carry as add
  287.           sets the carry itself. The number of steps can be from 0 to 32
  288.           inclusive.
  289.           It is sometimes possible to shift by the context of a register:
  290.             adds r1,r2,r3,lsr r4
  291.           Only the eigth lowest bits in the register are used allowing shifts
  292.           of up to 255 steps.
  293.  
  294. %asl
  295. E.g.:           adds r1,r2,r3,lsl #2  ; r1 = r2+r3<<2 = r2+r3*4
  296. Summary:  Asl shifts a register left inserting zeroes at the right end:
  297.              C<--bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb<--0
  298.           The last bit moved out from the register is inserted in the carry
  299.           if the main instruction does not affect the carry and the s-option
  300.           is given, e.g., the asl in the example will not set the carry as add
  301.           sets the carry itself. The number of steps can be from 0 to 32
  302.           inclusive.
  303.           It is sometimes possible to shift by the context of a register:
  304.             adds r1,r2,r3,asl r4
  305.           Only the eigth lowest bits in the register are used allowing shifts
  306.           of up to 255 steps.
  307. Note:     Asl is identical to lsl.
  308.  
  309. %asr
  310. E.g.:           adds r1,r2,r3,asr #2  ; r1 = r2+r3>>>2
  311. Summary:  Asr shifts a register right inserting copies of the highest bit at
  312.           the left end, i.e., the n most significants bits becomes equal to
  313.           bit 31:
  314.              /--\
  315.              \->bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb--->C
  316.           The last bit moved out from the register is inserted in the carry
  317.           if the main instruction does not affect the carry and the s-option
  318.           is given, e.g., the asr in the example will not set the carry as add
  319.           sets the carry itself. The number of steps can be from 0 to 32
  320.           inclusive.
  321.           It is sometimes possible to shift by the context of a register:
  322.             adds r1,r2,r3,asr r4
  323.           Only the eigth lowest bits in the register are used allowing shifts
  324.           of up to 255 steps.
  325.  
  326. %ror
  327. E.g.:           adds r1,r2,r3,ror #2
  328. Summary:  Ror rotates the register right:
  329.              /-----------------------------------\
  330.              \->bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb--->C
  331.           The last bit moved out from the register is inserted in the carry
  332.           if the main instruction does not affect the carry andthe s-option
  333.           is given, e.g., the ror in the example will not set the carry as add
  334.           sets the carry itself. The number of steps can be from 0 to 31
  335.           inclusive.
  336.           It is sometimes possible to rotate by the context of a register:
  337.             adds r1,r2,r3,ror r4
  338.           Only the eigth lowest bits in the register are used allowing
  339.           rotates of up to 255 steps.
  340.  
  341. %rrx
  342. E.g.:           adds r1,r2,r3,rrx
  343. Summary:  Rr rotates the register extended by the carry one step right:
  344.              /-----------------------------------------\
  345.              \->bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb--->C--/
  346.           The lowest bit is inserted in the carry if the main instruction
  347.           does not affect the carry and the s-option is given, e.g.,
  348.           the rrx in the example will not set the carry as add sets the
  349.           carry itself.
  350.  
  351. %Core3Op
  352. Usage:     Don't
  353. Summary:   This is only a short description of some cpu instructions.
  354. Syntax:    <Core3Op><Cond><Sflag> <Dst>,<Lhs>,<Rhs>
  355.            where
  356.            <Core3Op> is one of:                    which can update the following flags:
  357.                add     <Dst> = <Lhs> +  <Rhs>          NCVZ
  358.                adc     <Dst> = <Lhs> +  <Rhs> +  C     NCVZ
  359.                sub     <Dst> = <Lhs> -  <Rhs>          NCVZ
  360.                sbc     <Dst> = <Lhs> -  <Rhs> - ~C     NCVZ
  361.                rsb     <Dst> = <Rhs> -  <Lhs>          NCVZ
  362.                rsc     <Dst> = <Rhs> -  <Lhs> - ~C     NCVZ
  363.                eor     <Dst> = <Lhs> ^  <Rhs>          NZ   and <Rhs> can update C
  364.                orr     <Dst> = <Lhs> |  <Rhs>          NZ   and <Rhs> can update C
  365.                and     <Dst> = <Lhs> &  <Rhs>          NZ   and <Rhs> can update C
  366.                bic     <Dst> = <Lhs> & ~<Rhs>          NZ   and <Rhs> can update C
  367.            <Cond>  see Cond.
  368.            <Sflag> is one of:
  369.                s               Flags are updated according to the result.
  370.                        (empty) No flag is updated.
  371.            <Dst> and <Lhs> are registers, (identifiers defined with 'rn').
  372.            <Rhs> is one of:
  373.                #<Expression>   An integer which is possible to express as an 8 bit value
  374.                                rotated an even numbers of bits. The assembler will change
  375.                                the mnemonic, if necessary, to achieve this. Mnemonics that
  376.                                are changed are add/sub, adc/sbc and and/bic.
  377.                Register
  378.                Register,rrx                       see rrx
  379.                Register,<ShiftOp> #<Expression>   see ShiftOp
  380.                Register,<ShiftOp> Register        see ShiftOp
  381.  
  382.  
  383. %CoreCmp   
  384. Usage:     Don't
  385. Summary:   This is only a short description of some cpu instructions.
  386. Syntax:    <CoreCmp><Cond><Sflag><Pflag> <Lhs>,<Rhs>
  387.            where
  388.            <CoreCmp> is one of:              which updates the following flags:
  389.                cmp     <Lhs> - <Rhs>                   NCVZ 
  390.                cmn     <Lhs> + <Rhs>                   NCVZ 
  391.                tst     <Lhs> & <Rhs>                   NZ   and <Rhs> can update C
  392.                teq     <Lhs> ^ <Rhs>                   NZ   and <Rhs> can update C
  393.            <Cond>  see Cond.
  394.            <Sflag> is not used, flags are always uppdated according to the result.
  395.                An 's' can be given but it is ignored.
  396.            <Pflag> is one of:
  397.                p               The result of the operation is moved to the
  398.                                PSR, i.e., the NCVZ flags are set from the top
  399.                                four bits of the result. In modes other than
  400.                                the user mode the NCVZIF flags are set from
  401.                                the top six bits and the mode bits are set
  402.                                from the two lowest bits. 
  403.                        (empty) The flags are updated according to the result of
  404.                                the operation
  405.  
  406.            <Dst> and <Lhs> are registers, (identifiers defined with 'rn').
  407.            <Rhs> is one of:
  408.                #<Expression>   An integer which is possible to express as an 8 bit value
  409.                                rotated an even numbers of bits. The assembler will change
  410.                                the mnemonic, if necessary, to achieve this. Mnemonics that
  411.                                are changed are cmp/cmn.
  412.                Register
  413.                Register,rrx                       see rrx
  414.                Register,<ShiftOp> #<Expression>   see ShiftOp
  415.                Register,<ShiftOp> Register        see ShiftOp
  416.  
  417. %add
  418. E.g.:           add r0,r1,r2
  419. Summary:   Add.
  420. See:       Core3Op
  421.  
  422. %adc
  423. E.g.:           adc r0,r1,r2
  424. Summary:   Add with carry.
  425. See:       Core3Op
  426.  
  427. %syb
  428. E.g.:           sub r0,r1,r2
  429. Summary:   Subtract.
  430. See:       Core3Op
  431.  
  432. %sbc
  433. E.g.:           sbc r0,r1,r2
  434. Summary:   Subtract with carry.
  435. See:       Core3Op
  436.  
  437. %rsb
  438. E.g.:           rsb r0,r1,r2
  439. Summary:   Reverse subtract.
  440. See:       Core3Op
  441.  
  442. %rsc
  443. E.g.:           rsc r0,r1,r2
  444. Summary:   Reverse subtract with carry.
  445. See:       Core3Op
  446.  
  447. %eor
  448. E.g.:           eor r0,r1,r2
  449. Summary:   Bitwise exclusive or.
  450. See:       Core3Op
  451.  
  452. %orr
  453. E.g.:           orr r0,r1,r2
  454. Summary:   Bitwise or. Acorn choosed this spelling!
  455. See:       Core3Op
  456.  
  457. %and
  458. E.g.:           and r0,r1,r2
  459. Summary:   Bitwise and.
  460. See:       Core3Op
  461.  
  462. %bic
  463. E.g.:           bic r0,r1,r2
  464. Summary:   Bit clear, this is an and where the right operand is inverted.
  465. See:       Core3Op
  466.  
  467. %mvn
  468. E.g.:           mvn r0,r1
  469. Summary:   Move not, i.e., the source operand is inverted.
  470. Syntax:    mvn<Cond><Sflag> <Dst>,<Rhs>
  471.            Mvn updates the N and Z flags if the Sflag is given, <Rhs> can
  472.            update the carry.
  473.            <Cond>  see Cond.
  474.            <Sflag> is one of:
  475.                s               Flags are updated according to the result.
  476.                        (empty) No flag is updated.
  477.            <Dst> is a register, (identifiers defined with 'rn').
  478.            <Rhs> is one of:
  479.                #<Expression>   An integer which is possible to express as an 8 bit value
  480.                                rotated an even numbers of bits. The assembler will change
  481.                                the mnemonic, if necessary, to a mov to achieve this.
  482.                Register
  483.                Register,rrx                       see rrx
  484.                Register,<ShiftOp> #<Expression>   see ShiftOp
  485.                Register,<ShiftOp> Register        see ShiftOp
  486.  
  487.  
  488. %mov
  489. E.g.:           mov r0,r1
  490. Summary:   Move, can also be used for shifts (,if you can not integrate the
  491.            shift in another instruction):
  492.             mov r0,r1,lsl #2
  493. Syntax:    mov<Cond><Sflag> <Dst>,<Rhs>
  494.            Mov updates the N and Z flags if the Sflag is given, <Rhs> can
  495.            update the carry.
  496.            <Cond>  see Cond.
  497.            <Sflag> is one of:
  498.                s               Flags are updated according to the result.
  499.                        (empty) No flag is updated.
  500.            <Dst> is a register, (identifiers defined with 'rn').
  501.            <Rhs> is one of:
  502.                #<Expression>   An integer which is possible to express as an 8 bit value
  503.                                rotated an even numbers of bits. The assembler will change
  504.                                the mnemonic, if necessary, to a mvn to achieve this.
  505.                Register
  506.                Register,rrx                       see rrx
  507.                Register,<ShiftOp> #<Expression>   see ShiftOp
  508.                Register,<ShiftOp> Register        see ShiftOp
  509.  
  510. %tst
  511. E.g.:           tst r0,r1
  512. Summary:   Test, a bitwise and where the result isn't saved.
  513. See:       CoreCmp
  514.  
  515. %teq
  516. E.g.:           teq r0,r1
  517. Summary:   Test if equal, a bitwise exclusive or where the result isn't
  518.            saved.
  519. See:       CoreCmp
  520.  
  521. %cmp
  522. E.g.:           cmp r0,r1
  523. Summary:   Compare, a subtraction where the result isn't saved.
  524. See:       CoreCmp
  525.  
  526. %cmn
  527. E.g.:           cmn r0,r1
  528. Summary:   Compare negated, i.e., the second operand is negated before
  529.            comparasion. Cmn is an addition where the result isn't saved.
  530. See:       CoreCmp
  531.  
  532. %mul
  533. E.g.:           mul r0,r1,r2
  534. Summary:   Integer multiplication. The destination and the left operand
  535.            must be different, the assembler will change the order of the
  536.            operands to achieve this.
  537. Syntax:    mul<Cond><Sflag> <Dst>,<Lhs>,<Rhs>
  538.            <Cond>  see Cond.
  539.            <Sflag> is one of:
  540.                s               The NZ flags are updated according to the result,
  541.                                and the carry is undefined.
  542.                        (empty) No flag is updated.
  543.            <Dst>,<Lhs> and <Rhs> are registers, (identifiers defined with 'rn').
  544.  
  545. %mla
  546. E.g.:           mla r0,r1,r2,r4   ; r0 = r1*r2+r4
  547. Summary:   Integer multiplication with accumulator. The destination and the
  548.            left operand of the multiplication must be different, the
  549.            assembler will change the order of the operands to achieve this.
  550. Syntax:    mla<Cond><Sflag> <Dst>,<Lhs>,<Rhs>,Acc
  551.            <Cond>  see Cond.
  552.            <Sflag> is one of:
  553.                s               The NZ flags are updated according to the result,
  554.                                and the carry is undefined.
  555.                        (empty) No flag is updated.
  556.            <Dst>,<Lhs>,<Rhs> and <Acc> are registers, (identifiers defined with 'rn').
  557.  
  558. %b
  559. E.g.:           beq label10
  560. Summary:   This is the branch instruction.
  561. Syntax:    b<Cond>  <Destination>
  562.            b<Cond> #<Expression>
  563.            <Cond>  see Cond.
  564.            <Destination>
  565.              The assembler will calculate the offset to the destination and take
  566.              care of prefetch if no '#' is given.
  567.            <Expression>
  568.              The expression is treated as the byte offset that should be added
  569.              to the pc. Only even multiples of four are allowed.
  570.            Undefined identifiers are allowed in both forms.
  571.  
  572. %bl
  573. E.g.:           bl label10
  574. Summary:   This is the branch with link instruction. The address of the next
  575.            instruction is saved in cpu register 14, and the execution continues
  576.            at the given destiniation.
  577. Syntax:    bl<Cond>  <Destination>
  578.            bl<Cond> #<Expression>
  579.            <Cond>  see Cond.
  580.            <Destination>
  581.              The assembler will calculate the offset to the destination and take
  582.              care of prefetch if no '#' is given.
  583.            <Expression>
  584.              The expression is treated as the byte offset that should be added
  585.              to the pc. Only even multiples of four are allowed.
  586.            Undefined identifiers are allowed in both forms.
  587.  
  588. %swi
  589. E.g.:           swi 256+'a'
  590. Summary:   Software interrupt. The address of the next instruction is saved in
  591.            cpu register svc-14, and the execution continues at 0x00000008 with
  592.            the I flag set and the svc mode selected. This instruction is used
  593.            for system calls.
  594. Syntax:    swi<Cond> <Expression>
  595.            <Cond>  see Cond.
  596.            the expression can be any 24-bit integer.
  597.  
  598. %swp
  599. E.g.:           swpb r0,r1,[r2]
  600. Summary:   Swap is used to implement looks on multi processor computers.
  601. Syntax:    swp<Cond><Bflag> <Dst>,<Src>,[<Addr>]
  602.            <Cond>  see Cond.
  603.            <Bflag>
  604.                b               This is a byte operation. The value is zero extended.
  605.                        (empty) This is a 32-bits operation.
  606.            <Dst>,<Src> and <Addr> are registers, (identifiers defined with 'rn').
  607.            The semantic is: 
  608.              mov                  <temp>,<Src>
  609.              ldr<Cond><Bflag>     <Dst>, [<Addr>]
  610.              str<Cond><Bflag>     <temp>,[<Addr>]
  611.            with a lock signal set on the buss so that other cpus can detect that an
  612.            atomic operation is under progress.
  613. Note:      Not availible on ARM2.
  614.  
  615. %adr:
  616. E.g.:           adr r0,CloseLabel
  617. Summary:   This is a syntesized instruction which is used to put the address of a
  618.            label into a register. The assembler generates either:
  619.              add r0,pc,#Offset
  620.            or
  621.              sub r0,pc,#Offset
  622.            depending on the relative position of the instruction and the label.
  623. Syntax:    add<Cond> <Dst>,<Position>
  624.            <Cond>  see Cond.
  625.            <Position> is a label in the same area as the instruction. The range
  626.            is limited to the positions that can be generated by adding/subtracting
  627.            an 8-bits value rotated by an even number of steps to/from the pc.
  628.  
  629. %ldm:
  630. E.g.:           ldm sp!,{r0-r4,pc}
  631. Summary:   This instruction loads multiple registers. It is normaly used to pop
  632.            from stacks, but is also useful for copying memory.
  633. Syntax:    ldm<Cond><Direction>   <Addr><!flag>,<RegisterList><^flag>
  634.            <Cond>  see Cond.
  635.            <Direction> is one of:
  636.              ib   increment <Addr>, before first load.
  637.              ia   increment <Addr>, after first load.
  638.              db   decrement <Addr>, before first load.
  639.              da   decrement <Addr>, after first load.
  640.              fd   use a  full  descending stack, same as ia.
  641.              ed   use an empty descending stack, same as ib.
  642.              fa   use a  full  ascending  stack, same as da.
  643.              ea   use an empty ascending  stack, same as db.
  644.            <Addr> is a register, (identifiers defined with 'rn').
  645.            <!flag>
  646.                !               <Addr> = <Addr> + 4*number of registers, if increment,
  647.                                       = <Addr> - 4*number of registers, if decrement.
  648.                        (empty) Do not change <Addr>
  649.            <RegisterList> is a comma separated list of registers inside braces or a '#'
  650.                           followed by a 16-bits integer expression.
  651.            <^flag>
  652.                    ^      If pc is loaded then the CZNV will be updated. If the cpu is in
  653.                           a non-user mode then the CZNVIF and the mode bits will be updated.
  654.                           If a non-user mode is selected and the pc is not loaded then the '^'
  655.                           means that it is the user registers that are loaded.
  656.                   (empty) Only the address part of the pc is updated.
  657.  
  658. %stm:
  659. E.g.:           stm sp!,{r0-r4,pc}
  660. Summary:   This instruction stores multiple registers. It is normaly used to push
  661.            on stacks, but is also useful for copying memory.
  662. Syntax:    stm<Cond><Direction>   <Addr><!flag>,<RegisterList><^flag>
  663.            <Cond>  see Cond.
  664.            <Direction> is one of:
  665.              ib   increment <Addr>, before first store.
  666.              ia   increment <Addr>, after first store.
  667.              db   decrement <Addr>, before first store.
  668.              da   decrement <Addr>, after first store.
  669.              fd   use a  full  descending stack, same as db.
  670.              ed   use an empty descending stack, same as da.
  671.              fa   use a  full  ascending  stack, same as ib.
  672.              ea   use an empty ascending  stack, same as ia.
  673.            <Addr> is a register, (identifiers defined with 'rn').
  674.            <!flag>
  675.                !               <Addr> = <Addr> + 4*number of registers, if increment,
  676.                                       = <Addr> - 4*number of registers, if decrement.
  677.                        (empty) Do not change <Addr>
  678.            <RegisterList> is a comma separated list of registers inside braces or a '#'
  679.                           followed by a 16-bits integer expression.
  680.            <^flag>
  681.                    ^      No meaning in user mode, but in non-user mode means that it is
  682.                           the user registers that are stored.
  683.                   (empty) Use the current modes register.
  684.  
  685. %ldr
  686. E.g.:           ldr r0,[r1,r2,lsl #2]   ; Loads the r2'th word from the table at r1 into r0.
  687. Summary:   The load instruction has many possibilities so the following
  688.            description might be a bit complicated.
  689. Syntax:    ldr<Cond><Bflag><Tflag>  <Dst>,<Address><!flag>
  690.            <Cond>  see Cond.
  691.            <Bflag>
  692.                b               This is a byte operation. The value is zero extended.
  693.                        (empty) This is a 32-bits operation, the value read is rotated so
  694.                                that the byte pointed at ends up in the low byte of <Dst>.
  695.            <Tflag>
  696.                t               Make a user mode bus cycle even if in a non-user mode.
  697.                                This flag is only allowed if the address is a post
  698.                                inc/decrement.
  699.                        (empty) Use the bus cycle for the current mode.
  700.            <Dst> is a register, (identifiers defined with 'rn').
  701.            <Address>
  702.              The <Tflag> is allowed in 1 to 5 but not in the others.
  703.              The <!flag> is allowed in 6 to 9 but not in the others.
  704.              10 and 11 is syntetic sugare for pc relative addressing. 
  705.               1 [ <Addr> ]      
  706.                                     indirect register. 
  707.               2 [ <Addr> ],#<Offset>
  708.                                     indirect register with immediate post inc/decrement. 
  709.               3 [ <Addr> ],<+/-> <RegOffset>
  710.               4 [ <Addr> ],<+/-> <RegOffset>, rrx
  711.               5 [ <Addr> ],<+/-> <RegOffset>,<ShiftOp> #<Expression>
  712.                                     indirect register with register post inc/decrement. 
  713.               6 [ <Addr>,#<Offset> ]
  714.                                     indirect register with immediate pre inc/decrement. 
  715.               7 [ <Addr>,<+/-> <RegOffset> ]
  716.               8 [ <Addr>,<+/-> <RegOffset>, rrx ]
  717.               9 [ <Addr>,<+/-> <regOffset>, <ShiftOp> #<Expression> ]
  718.                                     indirect register with register pre inc/decrement.
  719.              10 <Expr>
  720.                                     Translated into [pc,#<Offset>] where <Expr> = pc+<Offset>
  721.                                     compensated for prefetching.
  722.              11 =<Expr>
  723.                                     Translated into a [pc,#<Offset>] pointing at a word in a
  724.                                     literal area  (see ltorg) containing <Expr>. The assembler
  725.                                     tries to share constants if possible.
  726.            <Addr> and <RegOffset> are registers, (identifiers defined with 'rn').
  727.            <+/-> a plus or minus sign, or nothing which means plus.
  728.            <Offset>                 is an expression which value fits in a 12-bit constant
  729.                                     with a sign bit ,-4095 to +4095 inclusive.
  730.            rrx             see rrx.
  731.            <ShiftOp>       see ShiftOp.
  732.            <!flag>
  733.                !               <Addr> = <Addr> <+/-> Offset
  734.                                This flag is only allowed if the address is a pre
  735.                                inc/decrement. The <Addr> register is always updated
  736.                                if the <Address> is a post inc/decrement.
  737.                        (empty) Do not update the <Addr> register unless the <Address>
  738.                                is a post inc/decrement.
  739.  
  740. %str
  741. E.g.:           str r0,[r1,r2,lsl #2]   ; Store r0 at the r2'th word in the table at r1.
  742. Summary:   The store instruction has many possibilities so the following
  743.            description might be a bit complicated.
  744. Syntax:    str<Cond><Bflag><Tflag>  <Src>,<Address><!flag>
  745.            <Cond>  see Cond.
  746.            <Bflag>
  747.                b               This is a byte operation. The top 24-bits in <Src> are 
  748.                                ignored.
  749.                        (empty) This is a 32-bits operation, the two lowes bits of the
  750.                                address are ignored.
  751.            <Tflag>
  752.                t               Make a user mode bus cycle even if in a non-user mode.
  753.                                This flag is only allowed if the address is a post
  754.                                inc/decrement.
  755.                        (empty) Use the bus cycle for the current mode.
  756.            <Src> is a register, (identifiers defined with 'rn').
  757.            <Address>
  758.              The <Tflag> is allowed in 1 to 5 but not in the others.
  759.              The <!flag> is allowed in 6 to 9 but not in the others.
  760.              10 is syntetic sugare for pc relative addressing. 
  761.               1 [ <Addr> ]      
  762.                                     indirect register. 
  763.               2 [ <Addr> ],#<Offset>
  764.                                     indirect register with immediate post inc/decrement. 
  765.               3 [ <Addr> ],<+/-> <RegOffset>
  766.               4 [ <Addr> ],<+/-> <RegOffset>, rrx
  767.               5 [ <Addr> ],<+/-> <RegOffset>,<ShiftOp> #<Expression>
  768.                                     indirect register with register post inc/decrement. 
  769.               6 [ <Addr>,#<Offset> ]
  770.                                     indirect register with immediate pre inc/decrement. 
  771.               7 [ <Addr>,<+/-> <RegOffset> ]
  772.               8 [ <Addr>,<+/-> <RegOffset>, rrx ]
  773.               9 [ <Addr>,<+/-> <regOffset>, <ShiftOp> #<Expression> ]
  774.                                     indirect register with register pre inc/decrement.
  775.              10 <Expr>
  776.                                     Translated into [pc,#<Offset>] where <Expr> = pc+<Offset>
  777.                                     compensated for prefetching.
  778.            <Addr> and <RegOffset> are a registers, (identifiers defined with 'rn').
  779.            <+/-> a plus or minus sign, or nothing which means plus.
  780.            <Offset>                 is an expression which value fits in a 12-bit constant
  781.                                     with a sign bit ,-4095 to +4095 inclusive.
  782.            rrx         see rrx.
  783.            <ShiftOp>   see ShiftOp.
  784.            <!flag>
  785.                !               <Addr> = <Addr> <+/-> Offset
  786.                                This flag is only allowed if the address is a pre
  787.                                inc/decrement. The <Addr> register is always updated
  788.                                if the <Address> is a post inc/decrement.
  789.                        (empty) Do not update the <Addr> register unless the <Address>
  790.                                is a post inc/decrement.
  791.  
  792. %Float3Op
  793. Usage:     Don't
  794. Summary:   This is only a short description of some fpu instructions.
  795. Syntax:    <Float3Op><Cond><Prec><Round> <Dst>,<Lhs>,<Rhs>
  796.            where
  797.            <Float3Op> is one of:
  798.                adf     <Dst> = <Lhs>  +  <Rhs>
  799.                suf     <Dst> = <Lhs>  -  <Rhs>
  800.                rsf     <Dst> = <Rhs>  -  <Lhs>
  801.                muf     <Dst> = <Lhs>  *  <Rhs>
  802.                dvf     <Dst> = <Lhs>  /  <Rhs>
  803.                rdf     <Dst> = <Rhs>  /  <Lhs>
  804.                pow     <Dst> = <Lhs> **  <Rhs>
  805.                rpw     <Dst> = <Rhs> **  <Lhs>
  806.                rmf     <Dst> = <Lhs> mod <Rhs>
  807.                fml     <Dst> = <Lhs>  *  <Rhs>       fast multiplication
  808.                fdv     <Dst> = <Lhs>  /  <Rhs>       fast division
  809.                frd     <Dst> = <Rhs>  /  <Lhs>       fast reverse division
  810.                pol     <Dst> = arctan(<Lhs> / <Rhs>)
  811.            <Cond>  see Cond.
  812.            <Prec> is one of:
  813.                s               Single   precision (32-bit float).
  814.                d               Double   precision (64-bit float).
  815.                e               Extended precision (96-bit float).
  816.            <Round> is one of:
  817.                p               Round to plus infinity.
  818.                m               Round to minus infinity.
  819.                z               Round to zero.
  820.                       (empty)  Round to nearest.
  821.            <Dst> and <Lhs> are fpu registers, (identifiers defined with 'fn').
  822.            <Rhs> is one of:
  823.                #<FloatExpression>   Must evaluate to one of 0.0 1.0 2.0 3.0 4.0 5.0 10.0 or 0.5
  824.                <FpuRegister>        Identifier defined with 'fn'.
  825.  
  826. %Float2Op
  827. Usage:     Don't
  828. Summary:   This is only a short description of some fpu instructions.
  829. Syntax:    <Float2Op><Cond><Prec><Round> <Dst>,<Rhs>
  830.            where
  831.            <Float2Op> is one of:
  832.                mvf     <Dst> =     <Rhs>
  833.                mnf     <Dst> =    - <Rhs>
  834.                abs     <Dst> = abs( <Rhs>)
  835.                rnd     <Dst> = rnd( <Rhs>)     <Rhs> is rounded to an integer.
  836.                sqt     <Dst> = sqr( <Rhs>)     Square root
  837.                log     <Dst> = log( <Rhs>)     Log base 10.
  838.                lgn     <Dst> = lgn( <Rhs>)     Log base e.
  839.                exp     <Dst> = e ** <Rhs>
  840.                sin     <Dst> = sin( <Rhs>)
  841.                cos     <Dst> = cos( <Rhs>)
  842.                tan     <Dst> = tan( <Rhs>)
  843.                asn     <Dst> = asn( <Rhs>)
  844.                acs     <Dst> = acs( <Rhs>)
  845.                atn     <Dst> = atn( <Rhs>)
  846.            <Cond>  see Cond.
  847.            <Prec> is one of:
  848.                s               Single   precision (32-bit float).
  849.                d               Double   precision (64-bit float).
  850.                e               Extended precision (96-bit float).
  851.            <Round> is one of:
  852.                p               Round to plus infinity.
  853.                m               Round to minus infinity.
  854.                z               Round to zero.
  855.                       (empty)  Round to nearest.
  856.            <Dst> is a fpu register, (identifiers defined with 'fn').
  857.            <Rhs> is one of:
  858.                #<FloatExpression>   Must evaluate to one of 0.0 1.0 2.0 3.0 4.0 5.0 10.0 or 0.5
  859.                <FpuRegister>        Identifier defined with 'fn'.
  860.  
  861. %adf
  862. E.g.:           adfs f0,f1,f2
  863. Summary:   Floating point addition.
  864. See:       Float3Op
  865.  
  866. %suf
  867. E.g.:           sufs f0,f1,f2
  868. Summary:   Floating point subtraction.
  869. See:       Float3Op
  870.  
  871. %rsf
  872. E.g.:           rsfs f0,f1,#10.0
  873. Summary:   Reverse floating point subtraction.
  874. See:       Float3Op
  875.  
  876. %muf
  877. E.g.:           mufs f0,f1,f2
  878. Summary:   Floating point multiplication.
  879. See:       Float3Op
  880.  
  881. %dvf
  882. E.g.:           dvfs f0,f1,f2
  883. Summary:   Floating point division.
  884. See:       Float3Op
  885.  
  886. %rdf
  887. E.g.:           rdfs f0,f1,#1.0
  888. Summary:   Reverse floating point division.
  889. See:       Float3Op
  890.  
  891. %pow
  892. E.g.:           pows f0,f1,f2
  893. Summary:   Floating point power operation.
  894. See:       Float3Op
  895.  
  896. %rpw
  897. E.g.:           rpws f0,f1,#10.0
  898. Summary:   Raise a float point constant to the power of a floating point
  899.            register.
  900. See:       Float3Op
  901.  
  902. %rmf
  903. E.g.:           rmfs f0,f1,f2
  904. Summary:   Floating point reminder.
  905. See:       Float3Op
  906.  
  907. %fml
  908. E.g.:           fmls f0,f1,f2
  909. Summary:   Fast floating point multiplication.
  910. See:       Float3Op
  911.  
  912. %fdv
  913. E.g.:           fdvs f0,f1,f2
  914. Summary:   Fast floating point division.
  915. See:       Float3Op
  916.  
  917. %frd
  918. E.g.:           frds f0,f1,#1.0
  919. Summary:   Fast reverse floating point division.
  920. See:       Float3Op
  921.  
  922. %pol
  923. E.g.:           pols f0,f1,f2
  924. Summary:   Float cartesian coordinate to angle.
  925. See:       Float3Op
  926.  
  927. %mvf
  928. E.g.:           mvfs f0,#1.0
  929. Summary:   Floating point move.
  930. See:       Float2Op
  931.  
  932. %mnf
  933. E.g.:           mnfs f0,#1.0
  934. Summary:   Floating point negated move, i.e., the second operand is negated.
  935. See:       Float2Op
  936.  
  937. %abs
  938. E.g.:           abss f0,#1.0
  939. Summary:   Floating point absolute value.
  940. See:       Float2Op
  941.  
  942. %rnd
  943. E.g.:           rnds f0,#1.0
  944. Summary:   Round floating value to integer, result in a floating point
  945.            register. Use fix if the integer should be in a cpu register.
  946. See:       Float2Op fix
  947.  
  948. %sqt
  949. E.g.:           sqts f0,#1.0
  950. Summary:   Floating point square root.
  951. See:       Float2Op
  952.  
  953. %log
  954. E.g.:           logs f0,#1.0
  955. Summary:   Floating point log base 10.
  956. See:       Float2Op
  957.  
  958. %lgn
  959. E.g.:           lgns f0,#1.0
  960. Summary:   Floating point log base e.
  961. See:       Float2Op
  962.  
  963. %exp
  964. E.g.:           exps f0,#1.0
  965. Summary:   E raised to the power of a floating point register, or floating
  966.            point constant.
  967. See:       Float2Op
  968.  
  969. %sin
  970. E.g.:           sins f0,#1.0
  971. Summary:   Floating point sine.
  972. See:       Float2Op
  973.  
  974. %cos
  975. E.g.:           coss f0,#1.0
  976. Summary:   Floating point cosine.
  977. See:       Float2Op
  978.  
  979. %tan
  980. E.g.:           tans f0,#1.0
  981. Summary:   Floating point tangent.
  982. See:       Float2Op
  983.  
  984. %asn
  985. E.g.:           asns f0,#1.0
  986. Summary:   Inverse floating point sine.
  987. See:       Float2Op
  988.  
  989. %acs
  990. E.g.:           acss f0,#1.0
  991. Summary:   Inverse floating point cosine.
  992. See:       Float2Op
  993.  
  994. %atn
  995. E.g.:           atns f0,#1.0
  996. Summary:   Inverse floating point tangent.
  997. See:       Float2Op
  998.  
  999. %FloatCmp
  1000. Usage:     Don't
  1001. Summary:   This is only a short description of some fpu instructions.
  1002. Note:      I'm not sure that this is correct! This is how the assembler
  1003.            treats the instructions, but it is possible that a precision
  1004.            is needed. 
  1005. Syntax:    <FloatCmp><Cond><Prec><Round> <Lhs>,<Rhs>
  1006.            where
  1007.            <FloatCmp> is one of:
  1008.                cmf     <Lhs> - <Rhs>
  1009.                cmfe    <Lhs> - <Rhs>  Generates an exception if unorded.
  1010.                cnf     <Lhs> + <Rhs>
  1011.                cnfe    <Lhs> + <Rhs>  Generates an exception if unorded.
  1012.            <Cond>  see Cond.
  1013.            <Lhs> is a fpu register, (identifiers defined with 'fn').
  1014.            <Rhs> is one of:
  1015.                #<FloatExpression>   Must evaluate to one of 0.0 1.0 2.0 3.0 4.0 5.0 10.0 or 0.5
  1016.                <FpuRegister>        Identifier defined with 'fn'.
  1017.  
  1018. %cmf
  1019. E.g.:           cmf f0,#1.0
  1020. Summary:   Floating point compare.
  1021. See:       FloatCmp cmfe
  1022.  
  1023. %cmfe
  1024. E.g.:           cmfe f0,#1.0
  1025. Summary:   Floating point compare. Cmfe raises an exception if the operands are
  1026.            unorded.
  1027. See:       FloatCmp cmf
  1028.  
  1029. %cnf
  1030. E.g.:           cnf f0,#1.0
  1031. Summary:   Floating point negated compare, i.e., the second operand is negated.
  1032. See:       FloatCmp cnfe
  1033.  
  1034. %cnfe
  1035. E.g.:           cnfe f0,#1.0
  1036. Summary:   Floating point negated compare, i.e., the second operand is
  1037.            negated. Cnfe raises an exception if the operands are unorded.
  1038. See:       FloatCmp cnf
  1039.  
  1040. %fix
  1041. E.g.:           fixsz r0,f0
  1042. Summary:   Fix rounds a floating points value to an integer and stores
  1043.            the result in a cpu register. Use rnd if the result should be
  1044.            stored in a floating point number.
  1045. Syntax:    fix<Cond><Prec><Round> <Dst>,<Rhs>
  1046.            <Cond>  see Cond.
  1047.            <Prec> is one of:
  1048.                s               Single   precision (32-bit float).
  1049.                d               Double   precision (64-bit float).
  1050.                e               Extended precision (96-bit float).
  1051.            <Round> is one of:
  1052.                p               Round to plus infinity.
  1053.                m               Round to minus infinity.
  1054.                z               Round to zero.
  1055.                       (empty)  Round to nearest.
  1056.            <Dst> is a cpu register, (identifiers defined with 'rn').
  1057.            <Rhs> is one of:
  1058.                #<FloatExpression>   Must evaluate to one of 0.0 1.0 2.0 3.0
  1059.                                     4.0 5.0 10.0 or 0.5
  1060.                <FpuRegister>        Identifier defined with 'fn'.
  1061.  
  1062. %flt
  1063. E.g.:           fltsz f0,r0
  1064. Summary:   Flt converts an integer in a cpu register to a float and stores
  1065.            the result in a fpu register.
  1066. Syntax:    flt<Cond><Prec><Round> <Dst>,<Rhs>
  1067.            <Cond>  see Cond.
  1068.            <Prec> is one of:
  1069.                s               Single   precision (32-bit float).
  1070.                d               Double   precision (64-bit float).
  1071.                e               Extended precision (96-bit float).
  1072.            <Round> is one of:
  1073.                p               Round to plus infinity.
  1074.                m               Round to minus infinity.
  1075.                z               Round to zero.
  1076.                       (empty)  Round to nearest.
  1077.            <Dst> is a fpu register, (identifiers defined with 'fn').
  1078.            <Rhs> is a cpu register, (identifiers defined with 'rn').
  1079.  
  1080. %rfs
  1081. E.g.:           rfs r0
  1082. Summary:   Rfs copies the fpu's status register into a cpu register. The
  1083.            status register contains the following flags:
  1084.              bit  0:  IVO invalid operation.
  1085.              bit  1:  DVZ divide by zero.
  1086.              bit  2:  OFL overflow.
  1087.              bit  3:  UFL underflow.
  1088.              bit  4:  INX inexact
  1089.              bit  5 to bit 15 Unused, read as zero.
  1090.              bit 16:  IVO mask, set means interrupt enabled.
  1091.              bit 17:  DVZ mask, set means interrupt enabled.
  1092.              bit 18:  OFL mask, set means interrupt enabled.
  1093.              bit 19:  UFL mask, set means interrupt enabled.
  1094.              bit 20 to bit 23 Unused, read as zero.
  1095.              bit 24 to bit 31 System id, where bit 31 set means floating point
  1096.                               hardware, read only. 
  1097. Syntax:    rfs<Cond> <Dst>
  1098.            <Cond>  see Cond.
  1099.            <Dst> is a cpu register, (identifiers defined with 'rn').
  1100.  
  1101. %wfs
  1102. E.g.:           wfs r0
  1103. Summary:   Wfs updates the fpu's status register with the value of a cpu
  1104.            register. The status register contains the following flags:
  1105.              bit  0:  IVO invalid operation.
  1106.              bit  1:  DVZ divide by zero.
  1107.              bit  2:  OFL overflow.
  1108.              bit  3:  UFL underflow.
  1109.              bit  4:  INX inexact
  1110.              bit  5 to bit 15 Unused, read as zero.
  1111.              bit 16:  IVO mask, set means interrupt enabled.
  1112.              bit 17:  DVZ mask, set means interrupt enabled.
  1113.              bit 18:  OFL mask, set means interrupt enabled.
  1114.              bit 19:  UFL mask, set means interrupt enabled.
  1115.              bit 20 to bit 23 Unused, read as zero.
  1116.              bit 24 to bit 31 System id, where bit 31 set means floating point
  1117.                               hardware, read only. 
  1118. Syntax:    wfs<Cond> <Src>
  1119.            <Cond>  see Cond.
  1120.            <Src> is a cpu register, (identifiers defined with 'rn').
  1121.  
  1122. %rfc
  1123. E.g.:           rfc r0
  1124. Summary:   Rfc is a privileged instruction that reads the fpu's control register. An
  1125.            attempt to use it in user mode will cause a trap. I have no information about
  1126.            what the control register contains.
  1127. Syntax:    rfc<Cond> <Dst>
  1128.            <Cond>  see Cond.
  1129.            <Dst> is a cpu register, (identifiers defined with 'rn').
  1130.  
  1131.  
  1132. %wfc
  1133. E.g.:           wfc r0
  1134. Summary:   Wfc is a privileged instruction that updates the fpu's control register. An
  1135.            attempt to use it in user mode will cause a trap. I have no information about
  1136.            what the control register contains.
  1137. Syntax:    rfc<Cond> <Dst>
  1138.            <Cond>  see Cond.
  1139.            <Dst> is a cpu register, (identifiers defined with 'rn').
  1140.  
  1141. %ldf
  1142. E.g.:          ldfs f0,[r0,#16]
  1143. Summary:   Ldf loads floating point values.
  1144. Syntax:    ldf<Cond><Prec> <Dst>,<Address><!flag>
  1145.            <Cond>  see Cond.
  1146.            <Prec> is one of:
  1147.                s               Single   precision (32-bit float).
  1148.                d               Double   precision (64-bit float).
  1149.                e               Extended precision (96-bit float).
  1150.                p               Packed decimal     (96-bit bcd-float).
  1151.            <Dst> is a fpu register, (identifiers defined with 'fn').
  1152.            <Address>
  1153.              The <!flag> is allowed in the last last variants but not in the others.
  1154.              [ <Addr> ]      
  1155.                                     indirect register. 
  1156.              [ <Addr> ],#<Offset>
  1157.                                     indirect register with immediate post inc/decrement. 
  1158.              [ <Addr>,#<Offset> ]
  1159.                                     indirect register with immediate pre inc/decrement. 
  1160.            <Addr> is a registers, (identifiers defined with 'rn').
  1161.            <Offset> is an expression which value fits 10-bit constant with a
  1162.                     sign bit where the two lowes bits set to zero ,-1020 to
  1163.                     +1020 inclusive but only multiples of four.
  1164.            <!flag>
  1165.                !               <Addr> = <Addr> + Offset, if increment,
  1166.                                       = <Addr> - Offset, if decrement.
  1167.                                This flag is only allowed if the address is a pre
  1168.                                inc/decrement. The <Addr> register is always updated
  1169.                                if the <Address> is a post inc/decrement.
  1170.                        (empty) Do not update the <Addr> register unless the <Address>
  1171.                                is a post inc/decrement.
  1172.  
  1173. %stf
  1174. E.g.:           stfs f0,[r0,#16]
  1175. Summary:   Stf stores floating point values. The rounding mode is always round
  1176.            to nearest, use a mvf before if another rounding mode is needed.
  1177. Syntax:    stf<Cond><Prec> <Src>,<Address><!flag>
  1178.            <Cond>  see Cond.
  1179.            <Prec> is one of:
  1180.                s               Single   precision (32-bit float).
  1181.                d               Double   precision (64-bit float).
  1182.                e               Extended precision (96-bit float).
  1183.                p               Packed decimal     (96-bit bcd-float).
  1184.            <Src> is a fpu register, (identifiers defined with 'fn').
  1185.            <Address>
  1186.              The <!flag> is allowed in the last last variants but not in the others.
  1187.              [ <Addr> ]      
  1188.                                     indirect register. 
  1189.              [ <Addr> ],#<Offset>
  1190.                                     indirect register with immediate post inc/decrement. 
  1191.              [ <Addr>,#<Offset> ]
  1192.                                     indirect register with immediate pre inc/decrement. 
  1193.            <Addr> is a registers, (identifiers defined with 'rn').
  1194.            <Offset> is an expression which value fits 10-bit constant with a
  1195.                     sign bit where the two lowes bits set to zero ,-1020 to
  1196.                     +1020 inclusive but only multiples of four.
  1197.            <!flag>
  1198.                !               <Addr> = <Addr> + Offset, if increment,
  1199.                                       = <Addr> - Offset, if decrement.
  1200.                                This flag is only allowed if the address is a pre
  1201.                                inc/decrement. The <Addr> register is always updated
  1202.                                if the <Address> is a post inc/decrement.
  1203.                        (empty) Do not update the <Addr> register unless the <Address>
  1204.                                is a post inc/decrement.
  1205.  
  1206. %ldc
  1207. E.g.:           ldc 10,c0,[r0,#16]
  1208. Summary:   Ldc loads a value to a coprocessor register. The fpu is coprocessor 1 so
  1209.            use ldf instead of ldc 1.
  1210. Syntax:    ldc<Cond><Lflag> <Cop><Dst>,<Address><!flag>
  1211.            <Cond>  see Cond.     
  1212.            <Cop> is the number of the coprocessor:
  1213.                 1 is the fpu.
  1214.               2-14   don't know if they are assign to anything. 
  1215.                15 is cache control on an ARM3.
  1216.            <Lflag> is one of:  (Note it is the coprocessor that decides what this flag means.)
  1217.                l          This is a long transfer.
  1218.                   (empty) This is a short transfer.
  1219.            <Dst> is a coprocessor register, (identifiers defined with 'cn').
  1220.            <Address>
  1221.              The <!flag> is allowed in the last variant but not in the others.
  1222.              [ <Addr> ]      
  1223.                                     indirect register. 
  1224.              [ <Addr> ],#<Offset>
  1225.                                     indirect register with immediate post inc/decrement. 
  1226.              [ <Addr>,#<Offset> ]
  1227.                                     indirect register with immediate pre inc/decrement. 
  1228.            <Addr> is a register, (identifiers defined with 'rn').
  1229.            <Offset> is an expression which value fits 10-bit constant with a
  1230.                     sign bit where the two lowes bits set to zero ,-1020 to
  1231.                     +1020 inclusive but only multiples of four.
  1232.            <!flag>
  1233.                !               <Addr> = <Addr> + Offset, if increment,
  1234.                                       = <Addr> - Offset, if decrement.
  1235.                                This flag is only allowed if the address is a pre
  1236.                                inc/decrement. The <Addr> register is always updated
  1237.                                if the <Address> is a post inc/decrement.
  1238.                        (empty) Do not update the <Addr> register unless the <Address>
  1239.                                is a post inc/decrement.
  1240.  
  1241. %stc
  1242. E.g.:           stc 10,c0,[r0,#16]
  1243. Summary:   Stc stores a value from a coprocessor register. The fpu is coprocessor 1 so
  1244.            use stf instead of stc 1.
  1245. Syntax:    stc<Cond><Lflag> <Cop><Src>,<Address><!flag>
  1246.            <Cond>  see Cond.
  1247.            <Lflag> is one of:  (Note it is the coprocessor that decides what this flag means.)
  1248.                l          This is a long transfer.
  1249.                   (empty) This is a short transfer.
  1250.            <Cop> is the number of the coprocessor:
  1251.                 1 is fpu.
  1252.               2-14   don't know if they are assign to anything. 
  1253.                15 is cache control on an ARM3.
  1254.            <Src> is a coprocessor register, (identifiers defined with 'cn').
  1255.            <Address>
  1256.              The <!flag> is allowed in the last variant but not in the others.
  1257.              [ <Addr> ]      
  1258.                                     indirect register. 
  1259.              [ <Addr> ],#<Offset>
  1260.                                     indirect register with immediate post inc/decrement. 
  1261.              [ <Addr>,#<Offset> ]
  1262.                                     indirect register with immediate pre inc/decrement. 
  1263.            <Addr> is a register, (identifiers defined with 'rn').
  1264.            <Offset> is an expression which value fits 10-bit constant with a
  1265.                     sign bit where the two lowes bits set to zero ,-1020 to
  1266.                     +1020 inclusive but only multiples of four.
  1267.            <!flag>
  1268.                !               <Addr> = <Addr> + Offset
  1269.                                This flag is only allowed if the address is a pre
  1270.                                inc/decrement. The <Addr> register is always updated
  1271.                                if the <Address> is a post inc/decrement.
  1272.                        (empty) Do not update the <Addr> register unless the <Address>
  1273.                                is a post inc/decrement.
  1274.  
  1275. %cdp
  1276. E.g.:           cdp  2,3,c0,c1,c2
  1277. Summary    Cdp is the coprocessor data instruction. Do not use it for coprocessor 1
  1278.            as the fpu has its own mnemonics.
  1279. Syntax:    cdp<Cond> <Cop>,<Operator>,<Dst>,<Rhs>,<Lhs> or
  1280.            cdp<Cond> <Cop>,<Operator>,<Dst>,<Rhs>,<Lhs>,<Info>
  1281.            <Cond>  see Cond.
  1282.            <Cop> is the number of the coprocessor:
  1283.                 1     is the fpu.
  1284.               2-14   don't know if they are assign to anything. 
  1285.                15     is cache control on an ARM3.
  1286.            <Opcode> is the number of this opcode, 0 to 15 inclusive.
  1287.            <Dst>,<Rhs> and <Lhs> are coprocessor register, (identifiers defined with 'cn').
  1288.            <Info> is the optional additional information field, 0 to 7 inclusive.
  1289.                   It is set to zero if it is omitted.
  1290.  
  1291. %mrc
  1292. E.g.:           mrc  2,3,r0,c1,c2
  1293. Summary    Mrc moves a value from the cpu to the coprocessor. Do not use it
  1294.            for coprocessor 1 as the fpu has its own mnemonics.
  1295. Syntax:    mrc<Cond> <Cop>,<Operator>,<Dst>,<Rhs>,<Lhs> or
  1296.            mrc<Cond> <Cop>,<Operator>,<Dst>,<Rhs>,<Lhs>,<Info>
  1297.            <Cond>  see Cond.
  1298.            <Cop> is the number of the coprocessor:
  1299.                 1     is the fpu.
  1300.               2-14   don't know if they are assign to anything. 
  1301.                15     is cache control on an ARM3 see CachOp.
  1302.            <Opcode> is the number of this opcode, 0 to 7 inclusive.
  1303.            <Dst> is a cpu register, (identifiers defined with 'rn').
  1304.            <Rhs> and <Lhs> are coprocessor register, (identifiers defined with 'cn').
  1305.            <Info> is the optional additional information field, 0 to 7 inclusive.
  1306.                   It is set to zero if it is omitted.
  1307.  
  1308. %mcr
  1309. E.g.:           mcr  2,3,r0,c1,c2
  1310. Summary    Mcr moves a value from the coprocessor to the cpu. Do not use it
  1311.            for coprocessor 1 as the fpu has its own mnemonics.
  1312. Syntax:    mrc<Cond> <Cop>,<Operator>,<Dst>,<Rhs>,<Lhs> or
  1313.            mrc<Cond> <Cop>,<Operator>,<Dst>,<Rhs>,<Lhs>,<Info>
  1314.            <Cond>  see Cond.
  1315.            <Cop> is the number of the coprocessor:
  1316.                 1     is the fpu.
  1317.               2-14   don't know if they are assign to anything. 
  1318.                15     is cache control on an ARM3 see CachOp.
  1319.            <Opcode> is the number of this opcode, 0 to 7 inclusive.
  1320.            <Dst> is a cpu register, (identifiers defined with 'rn').
  1321.            <Rhs> and <Lhs> are coprocessor register, (identifiers defined with 'cn').
  1322.            <Info> is the optional additional information field, 0 to 7 inclusive.
  1323.                   It is set to zero if it is omitted.
  1324.  
  1325. %CachOp
  1326. Usage:     Don't
  1327. Summary:   This is only a short description of how to control the cache on
  1328.            an ARM3. The information is taken from one article by Andrew Mell
  1329.            (Message-ID: <9108160241.AA17682@mole.gnu.ai.mit.edu>) and one by
  1330.            Michael Hardy (Message-ID: <9189@acorn.co.uk>).
  1331.            I have assumed that c0 and c1 are defined as coprocessor registers
  1332.            0 and 1.
  1333. Note:      According to my knowledge the maximum coprocessor register is 15 not 31 as
  1334.            stated in Mell's article but I might be wrong.
  1335.            I also wonder if there are any mnemonic specified for this operations.
  1336.  
  1337.                mrc<Cond> 15,0,arm-register,control-register,c0
  1338.                                                         writes to the cache controller
  1339.                mcr<Cond> 15,0,arm-register,control-register,c0
  1340.                                                         reads from the cache controller
  1341.  
  1342.                The control registers are:
  1343.  
  1344.                register 0: 32 bit processor identity field
  1345.                            bit 31-24 : Designer (41h = Acorn)
  1346.                            bit 23-16 : Manufacturer (56h = vlsi)
  1347.                            bit 15-8  : Part type (03h = arm3)
  1348.                            bit 7-0   : Revision (0 = revision 0)
  1349.  
  1350.                register 1: cache flush
  1351.                            writing any value to this register flushes the cache
  1352.                            so an ultrafast cache flush is "mrc 15,0,r0,c1,c0".
  1353.  
  1354.                register 2: cache control (3 bit register)
  1355.                            bit 0: high = cache on , low = cache off
  1356.                            bit 1: high = shared supervisor/user address space
  1357.                                   low  = separate supervisor/user address space
  1358.                            bit 2: high = select monitor mode
  1359.                              for program tracing with a logic analyser
  1360.                              leave it low
  1361.                            bit 3-31 : reserved
  1362.  
  1363.                register 3: cacheable areas register (32 bits)
  1364.                   If bit n is set then the 2MBytes starting at n*2MBytes are
  1365.                   cacheable.
  1366.                   The default value stored is &FC007FFF, so ROM, the RAM
  1367.                   disc and logical non-screen RAM are  cacheable, but I/O
  1368.                   space, physical memory and logical screen  memory are not.
  1369.  
  1370.                register 4: updateable areas register (32 bits)
  1371.                   If bit n is set then the 2MBytes starting at n*2MBytes are
  1372.                   updateable.
  1373.                   The default value stored is &00007FFF, so logical
  1374.                   non-screen RAM is updateable,  but ROM/CAM/DAG, I/O space,
  1375.                   physical memory and logical screen memory are  not.
  1376.  
  1377.  
  1378.                register 5: disruptive areas register (32 bits)
  1379.                   If bit n is set then the 2MBytes starting at n*2MBytes are
  1380.                   disruptive.
  1381.                   The default value stored is &F0000000, so the CAM map is
  1382.                   disruptive, but  ROM/DAG, I/O space, physical memory and
  1383.                   logical memory are not. This causes  automatic flushing
  1384.                   whenever MEMC's page mapping is altered, which allows 
  1385.                   programs written for the ARM2 (including RISC OS itself)
  1386.                   to run unaltered, but at  the expense of unnecessary
  1387.                   flushing on page swaps.
  1388.  
  1389.                register 6-31: reserved
  1390.  
  1391.