代写 graph statistic COMP 280

COMP 280
Programming Assignment 6
Cache Memory Simulator
In this assignment you will be building a simulator for three types of cache memories:
• Direct
• 2-Way Set Associative
• Fully Associative
In all three cases the size of the cache is 256 bytes and the size of a cache block is 16 bytes. The structure of the simulator is shown in the following diagram:

The components that are shown in blue are provided for you. The tan colored components are the components that you implement. A header file is provided for each of the tan components that specify the functions that you need to implement. The blue components and the header files for the tan components will be discussed in class.
For this exercise you can work in teams of 2 or 3. Be sure to identify all the team members in your submission.
Your submission must be emailed to tburger@sandiego.edu by the deadline. Only one submission per team. The submission is to include the 3 .c files for the cache simulators, the output of the simulator when it is run on the two transpose tests, and your observations about the results of the transpose tests.
There are additional tests that may help with your debugging. I suggest you start with test1, test1a, test2, and test3, in that order. Once you have these tests running properly you can try the transpose tests.

Threshold Requirements
• All 3 simulations work properly
• All 3 simulations generate hit/miss statistics
• Output from the two transpose tests
• Paragraph or two with observations about the difference between the two tests.
• Source code is formatted in a reasonable fashion
• Consistent Indentation (gvim command “gg=G”)
• Do not change the supplied files.
• Use the deferred write policy instead of write-through for writes
• When replacing an entry in the 2-Way or Fully Associative Cache, always select the least recently used entry to replace.