Page 358 - ARM 64 Bit Assembly Language
P. 358

348 Chapter 10

                  10.5.2.2 Operations

                   Name     Effect                               Description
                   vorr     Vd[] ← Vd[] ∨ (uimm8   shif t)       Logical OR
                   vbic     Vd[] ← Vd[] ∧ (uimm8   shif t)       Bit Clear


                  10.5.2.3 Examples

                1     bic  v0.2s, #0xFF       // clear least significant bytes
                2                             // of v0.s[0] and v0.s[1]
                3     orr  v3.8h, #0x80,lsl #8 // set sign bit of every halfword
                4                             // in v3




                  10.6 Basic arithmetic instructions


                  Advanced SIMD provides many instructions for addition, subtraction, and multiplication, but
                  does not provide an integer divide instruction. When division cannot be avoided, it is per-
                  formed by multiplying the reciprocal, as was described in Chapter 7 and Chapter 8.When
                  dividing by a constant, the reciprocal can be calculated in advance. For dividing by variables,
                  Advanced SIMD provides instructions for quickly calculating the reciprocals of the elements
                  in a vector. In most cases, this is faster than using a divide instruction. For floating point num-
                  bers, the FP/NEON divide instructions can be used.



                  10.6.1 Vector add and subtract

                  The add and fadd instructions add corresponding elements in two vectors and store the re-
                  sults in the corresponding elements of the destination register. The sub and fsub instructions
                  subtract elements in one vector from corresponding elements in another vector and store the
                  results in the corresponding elements of the destination register. Other versions of the add and
                  subtract instructions allow mismatched operand and destination sizes, and the saturating ver-
                  sions prevent overflow by limiting the range of the results. The following instructions perform
                  vector addition and subtraction:

                  add       Vector integer add,
                  fadd      Vector floating point add,
                  qadd      Vector saturating add,
                  addl      Vector add long,
   353   354   355   356   357   358   359   360   361   362   363