D2 Simple Debugging Tool, SDB

The PA lab from Nanjing University's Computer Systems Fundamentals course is the first, and currently the only, simulator-based teaching lab in China. It will guide you through developing NEMU, a fully functional but simplified simulator, and then using NEMU to build a complete computer system. This goal is very similar to "One Student One Chip". You have already implemented minirvEMU and run some simple programs on it; the core working principle of NEMU is the same as that of minirvEMU, except that NEMU supports richer functionality.

We introduce PA into "One Student One Chip" mainly for the following reasons:

  • PA covers most of the training for system-level ability: from hardware simulators, ISA, and runtime environments to homemade operating systems, library functions, and applications. It helps you gain a deep understanding of every detail of how programs run on a computer.
    • If you choose to build system software directly on an RTL processor, you first need to make sure your processor is correct. If your pipeline has a problem interacting with the bus in some corner case, your homemade OS and complex applications, such as Chinese PAL, will not run. In contrast, implementing a simulator correctly is much easier than implementing RTL correctly.
  • In industrial workflows, simulators are an important component of processor testing and verification. By introducing PA, we hope you can also experience the processor development workflow used in industry during "One Student One Chip". At the same time, we hope you can understand every detail inside the simulator, customize it yourself when necessary, and avoid treating it as an external tool unrelated to you.

*Computer Systems Fundamentals* Theory Course Resources

While completing PA, if you need to make up some theory-course knowledge, you may refer to Professor Chunfeng Yuan's courses on China University MOOC: Part 1open in new window, Part 2open in new window, Part 3open in new window.

Read the FAQ in the PA Handout

Before starting PA, we strongly recommend that you read the FAQ in the PA handout to learn more about PA.

Complete PA1

Complete the relevant content according to the PA handout, using the default riscv32 ISA, including:

Friendly Reminder

This is the end of PA1...

yyz