Download the ZIPed MPLAB X project
unzip it into your
Open up your favorite text editor and get ready to write some answers.
Find the calls to the C functions
longjmp in this program.
longjmp are two of the most
puzzling and despised function calls in computer science.
Look up some information about
and write an explanation about what they do in this program.
You may want to talk to your fellow classmates about
longjmp, but write up your own answer!
Be sure to mention something about how the
oopsCause is being used.
Task 2 (no writing)
Build the program and then
Because the program ends in with an infinite
while (1) loop, it will never stop.
You need to Pause it.
Once the program has stopped,
open up the variables window
of MPLABX and display the values
You can ignore
Either copy these into your document or do a screen capture and pasted it into your document.
Look at pages 99–102 of the
MIPS32® M4K™ Processor Core
Software User’s Manual which describes the CP0 Cause registers.
Use this information to descode the four values of
oopsCause you found in the previous task.
Explain how the
crashAndBurn program managed to
generate each of these values.
Submitting the assignment
Save your file in PDF. That’s the one format supported by Moodle’s commenter feature. Then upload it to the homework 7 moodle page.