
CS485G Spring 2015 26
25 x86 64 registers
1. Eight upgraded 64-bit registers, now with names starting with r in-
stead of e, such as %rax.
2. Eight new 64-bit registers, called %r8 . . . %r15.
3. To use only the lower bits of a register, append a suffix to the register
name.
suffix bits
b 8
w 16
d 32
4. Conventions
(a) The first 6 parameters are passed, in reverse order, in %rdi,
%rsi, %rdx, %rcx, %r8, and %r9.
(b) The remaining parameters are pushed on the stack in call order.
(c) non-volatile (callee-save) registers: %rbp, %rbx, %r12, %r13,
%r14, and %r15.
(d) Other registers are volatile (caller-save).
26 Data types
1. Integer
(a) Can be stored in general registers or in memory.
(b) Signed and unsigned work the same except for shift operations.
(c) Suffix on instructions indicates how many bits are affected
Intel C assembler bytes
byte char b 1
word short w 2
double word int l 4
quad word long int q 8 (x86 64)
2. Floating point
(a) Can be stored in floating-point registers or in memory.
Intel C assembler bytes
single float s 4
double double l 8 (x86 64)
extended long double t 10/12/16 (x86 64)
Komentarze do niniejszej Instrukcji