Implement emulators like PSIM, an emulator for PIPE implementation of the chArm instruction set architecture. -- 2
Budget: $30 – $250 USD
Implement a PIPE simulator. You are going to complete the C code in files through a GitHub repository I will provide .
The goal is to pass all test cases in the GitHub repo.
You are required to implement five functions that emulate five stages for your PIPE- simulator:
• fetch instr(): Fetch stage (including PC update actions).
• decode instr(): Decode stage.
• execute instr(): Execute stage.
• memory instr(): Memory stage.
• wback instr(): Write-back stage.
The fields of the pipeline registers are defined in include/pipe/instr_pipeline.h in several
struct types *_instr_impl_t and pipe_reg_t. The “clocking” of these registers is handled for
you in src/base/proc.c. When implementing the combinational logic for a pipeline stage, you will be
passed in the appropriate structs as your input and output arguments, which are named in and out. There
are also a few global variables that represent the “backwards” wires sent from one stage to a prior stage,
which you will need to update as well.
The goal is to pass all test cases in the GitHub repo.
You are required to implement five functions that emulate five stages for your PIPE- simulator:
• fetch instr(): Fetch stage (including PC update actions).
• decode instr(): Decode stage.
• execute instr(): Execute stage.
• memory instr(): Memory stage.
• wback instr(): Write-back stage.
The fields of the pipeline registers are defined in include/pipe/instr_pipeline.h in several
struct types *_instr_impl_t and pipe_reg_t. The “clocking” of these registers is handled for
you in src/base/proc.c. When implementing the combinational logic for a pipeline stage, you will be
passed in the appropriate structs as your input and output arguments, which are named in and out. There
are also a few global variables that represent the “backwards” wires sent from one stage to a prior stage,
which you will need to update as well.