1. Preprocessor -> compiler -> assembler -> linker
*.c -> *.s -> *.o -> *
2. Program Counter --> %EIP --> Indicate the address in memory that the next instruction to be executed.
3. Register
4. condition code registers
5. floating-point registers
6. Program memory contains:
1) executable machine code for the program
2) information required by OS
3) run-time stack
4) memory allocated by user
7. Disassembler -> inspect the content of machine code
unix> objdump -d code.o
8. Intel & ATT assembly format
1)Intel format omit the size designation
2)Intel format omit % in front of register names
3)Different way describing the locations in memory
4)Instructions with multipule operands list them in reverse order
9. Operand forms:
1) Immediate $0x15
2) Register R[Ea]
3) Abosulte
4) Indirect
5) Base + displacement
6) Indexed
7) Scaled indexed -> Imm + R[Eb] + R[Ei]*S
10. Effective address
11. IA32 impose that a move instruction can't have both operands refer to memory locations.
12. MOV -> MOVB, MOVW, MOVL
13. MOVS ->MOVSBW, MOVSBL, MOVSWL (SIGNED EXTEND)
14. MOVZ ->MOVZBS, MOVZBL, MOVZWL (ZERO EXTEND)
15. PUSHL, POPL
*.c -> *.s -> *.o -> *
2. Program Counter --> %EIP --> Indicate the address in memory that the next instruction to be executed.
3. Register
4. condition code registers
5. floating-point registers
6. Program memory contains:
1) executable machine code for the program
2) information required by OS
3) run-time stack
4) memory allocated by user
7. Disassembler -> inspect the content of machine code
unix> objdump -d code.o
8. Intel & ATT assembly format
1)Intel format omit the size designation
2)Intel format omit % in front of register names
3)Different way describing the locations in memory
4)Instructions with multipule operands list them in reverse order
9. Operand forms:
1) Immediate $0x15
2) Register R[Ea]
3) Abosulte
4) Indirect
5) Base + displacement
6) Indexed
7) Scaled indexed -> Imm + R[Eb] + R[Ei]*S
10. Effective address
11. IA32 impose that a move instruction can't have both operands refer to memory locations.
12. MOV -> MOVB, MOVW, MOVL
13. MOVS ->MOVSBW, MOVSBL, MOVSWL (SIGNED EXTEND)
14. MOVZ ->MOVZBS, MOVZBL, MOVZWL (ZERO EXTEND)
15. PUSHL, POPL