Cirrus Logic CS485 Manual de usuario Pagina 15

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 67
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 14
CS485G Spring 2015 15
(c) Load Effective Address of src and put it in dest.
(d) Purpose: translate p = &x[i]
(e) Purpose: compute arithmetic expressions like x+k
*
y where k is
1, 2, 4, or 8.
i. Example: x
*
12
ii. leal (%eax,%eax,2), %eax # x = x+2x
sall $2, %eax # x = x << 2
19 Arithmetic operations
1. Two-operand instructions
instruction meaning
addl dest = dest + src
subl dest = dest src
imull dest = dest × src
sall dest = dest << src
sarl dest = dest >> src (arithmetic)
shrl dest = dest >> src (logical)
xorl dest = dest src (bitwise)
andl dest = dest src (bitwise)
orl dest = dest src (bitwise)
2. Lecture 10, 2/6/2015
3. Be careful of parameter order for asymmetric operations.
4. There is no distinction between signed and unsigned integers.
5. One-operand instructions
instruction meaning
incl dest = dest + 1
decl dest = dest 1
negl dest = dest
notl dest = ¬ dest (bitwise)
6. Example
Vista de pagina 14
1 2 ... 10 11 12 13 14 15 16 17 18 19 20 ... 66 67

Comentarios a estos manuales

Sin comentarios