Lab 7 -- Putting It All Together
Due WEDNESDAY May 17 before 5:00 PM
This will be the final lab that uses the hardware machine. For this
lab, we will put everything together and test our machine on a very simple
program. Here is what you should do:
- Write the function factorial in the assembly language of our
machine.
- Extend your machine with methods to: load the code for factorial
in memory, and then execute it on any input.
- Find out the biggest argument that you can give to factorial
without getting into trouble (either getting the wrong answer, or
running out of memory, or getting some other error).
- Find out how long it takes to run factorial on that biggest
argument.
- Repeat the last step using Java and C. In other words, write the
factorial function in both Java and C, run each version, and time it.
You should turn in:
- your code for factorial in all three languages (assembly, C, and Java),
- the classes that you modified,
- the results of your timing experiments.
Visited
times since March 23, 1999 (or the last crash).