2021/8/23 CS 315 – Fall 2021 – Project04
Project04 – ARM Emulator
Due
1. April 7th at 11:59 PM to the GitHub assignment published in Piazza
2. Sign up for interactive grading using the schedule published in Piazza
Requirements
1. You will write an emulator in C for a subset of the ARMv7 Instruction Set Architecture (ISA). You do not have to emulate the entire instruction set; just enough to emulate these target programs the programs in this assignment.
2. Your emulator will need the logic (decoding and emulating instructions) and state (emu_state) from lab06
3. Your emulator will include an implementation of a 4-way set-associative cache, as is common in commercial processors
4. Your emulator will perform dynamic analysis of emulated instructions: 1. # of data processing instructions
2. # of branch instructions
3. % of branches taken vs. not taken
Syllabus Schedule Assignments
4. # of cache hits, % of total memory instructions
5. # of cache misses, % of total memory instructions 6. # of instructions total
Given
1. In lecture and lab, we will:
1. illustrate how to decode machine code and execute the operations specified
2. illustrate a direct-mapped cache and describe the data structures and algorithms required for a set-associative cache
2. In-class coding will be pushed to Github. You will provide the rest of the code yourself
3. I will provide autograder test cases for the emulation targets Grading Rubric
Automated testing
https://cs315.cs.usfca.edu/projects/project04 1/2
1202 llaF – 513 SC
2021/8/23 CS 315 – Fall 2021 – Project04
Automated testing
60 pts: Automated tests for quadratic, max3, find_max, fib_rec, matches and
Syllabus Schedule Assignments
merge_sort
Interactive grading
10 pts: Demonstrate and describe your dynamic analysis
10 pts: Demonstrate and describe your set-associative cache
10 pts: The grader will choose a question about the design or implementation of your emulation
Coding Style
10 pts: Clean repo, consistent naming and indentation, no dead code, no unnecessarily complex code
Extra Credit
1 pt. Provide an emulation of the ldm/stm extra credit from project03
https://cs315.cs.usfca.edu/projects/project04
2/2
1202 llaF – 513 SC