Example for Homework 4
Source files
Assembly phase
Annotated source files (expanding pseudoinstructions, adding offsets):
Symbol tables:
Relocation information:
Link phase
Possibly-helpful programs
- addToAddress.scala:
Program to add offsets to base address (to calculate absolute addresses
during link phase -- I got tired of doing the arithmetic myself!).
- Example Scala code to do base-16 arithmetic and show result:
"%x".format(0x00400024+0x2c)