Home | History | Annotate | Download | only in arm-vfp
      1     /*
      2      * Generic 32-bit floating point "/2addr" binary operation.  Provide
      3      * an "instr" line that specifies an instruction that performs
      4      * "s2 = s0 op s1".
      5      *
      6      * For: add-float/2addr, sub-float/2addr, mul-float/2addr, div-float/2addr
      7      */
      8     /* binop/2addr vA, vB */
      9     mov     r3, rINST, lsr #12          @ r3<- B
     10     mov     r9, rINST, lsr #8           @ r9<- A+
     11     VREG_INDEX_TO_ADDR(r3, r3)          @ r3<- &vB
     12     and     r9, r9, #15                 @ r9<- A
     13     flds    s1, [r3]                    @ s1<- vB
     14     VREG_INDEX_TO_ADDR(r9, r9)          @ r9<- &vA
     15     FETCH_ADVANCE_INST(1)               @ advance rPC, load rINST
     16     flds    s0, [r9]                    @ s0<- vA
     17 
     18     $instr                              @ s2<- op
     19     GET_INST_OPCODE(ip)                 @ extract opcode from rINST
     20     fsts    s2, [r9]                    @ vAA<- s2
     21     GOTO_OPCODE(ip)                     @ jump to next instruction
     22