C functions that you can use to load and access your simulated memory can be found in memory.h and memory. The drive.cc program also illustrates the use of simulated memory. You may wish to write your own testcases also. The input to your simulator is a file containing DLX instructions in the binary format described in the text. Read this file from standard input.
Output Execute the four test programs using the SlowDLX and FastDLX simulators.
Total number of instructions executed. Total number of cycles taken to execute the program. Stall cycles due to data hazards. Stall cycles due to conditional branches.