This will be a closed book exam.
You may use a calculator, but you need to show the steps in solving the
problems, not just write down the answer.
The calculator can be used only for add, subtract, multiply, and divide,
plus to check your answers.
Any other operations must be shown.
You are responsible for understanding all of assignments and material
from the textbook.
The exam will cover Chapter 3 through Section 3.7
Much of the exam will involve writing short pieces of assembly language code.
Make sure you understand Assignment 3 and Recitation 9.
- Know about the 8 IA32 32-bit registers and what they are used for.
- Know which are caller-save and which are callee-save.
- Know how the 8 and 16-bit registers are related to the 32-bit registers.
- Understand all of the addressing modes.
- Understand how b, w, and l are used in instructions such as mov and add.
- Be able to trace a short program.
- Be able to describe in words what an instruction or group of instructions does.
- Be familiar with the following instructions:
inc, dec, neg, not, add, sub, mul, imul, div, idiv, xor, or, and,
sal, shl, sar, shr, mov, leal, push, pop, call, ret, leave, cltd
- Know that in the body of most functions, the first parameter is at
8(%ebp), the second is at 12(%ebp), etc.
- Understand the four condition codes and how they are related to various
tests.
- Be able to tell how the condition codes will be set by a
given instruction.
- Understand how ifs and loops are implemented in assembly language.
- Understand how jumps are encoded and how this is related to what appears
in assembly listings.
- Understand the stack frame structure used for calling procedures
and saving data.
- Be able to trace a short program segment and show how the stack and
registers change as the code is executed.
Back to CS 3843 Homepage