Computer Organization
Exam 1
- Assembly language vs. high-level languages
- Assembly language vs. machine language
- MIPS instructions
add
addi
sub
lw
sw
sll
beq
bne
slt
j
jal
jr
- How to translate simple C code into MIPS assembly language
- Simple expressions
- Accessing array elements
- If and if-else statements
- While loops
- Immediate operands
- Zero (
$zero) register
- Conditional vs. unconditional branches
- Use of the set on less than (
slt) instruction
- Functions, parameter passing, return values
- Jump and link (
jal) and the $ra register
- How functions use the stack
- MIPS instructions formats (R-type, I-type, J-type)
- How to translate MIPS assembly language code into machine language (not binary)
- Role of compiler, assembler and linker in program translation