Computer engineering capstone team project
Team members who are not familiar with the Rust programming language have been focusing on learning Rust by working on exercises and reading documentation. We have also been working on creating a basic structure for the assembler and emulator to work off in the future. This includes determining how our data structures will be managed to allow emulating pipelining. Furthermore, we have been working on the user-interface.
The architecture of the editor was designed and established during the pre-alpha stage. It consists of two key components:
Remaining architectural challenges include:
The emulator is modeled as a finite state machine. Instructions are decoded according to the instruction formats defined in the RV32I Base Integer Instruction Set Version 2.0. Each instruction resolves to an instruction handler that consumes the current state and produces the next state. This design allows the ability to replay states forwards or backwards, facilitating debugging of programs executed on the platform.
The emulator's internal state is modeled after the OpenHW CVE2 2-stage pipelined RISC-V processor. By reviewing the top-level SystemVerilog file, we extracted the CVE2's datapath and pipeline components to enable cycle-level debugging.
The assembler is long yet simple and integrates with the frontend to take in assembly code as input, producing machine code output for the emulator.
The assembler operates on a two-pass system:
.data
and .text
), associating labels with memory addresses.The main function, assemble
, handles the assembly string and coordinates the parsing passes.
A lot of the assembler code is redundant since every supported instruction requires defining components like opcode
, funct3
, and funct7
in structures. Although the codebase is long, it remains straightforward.
npx tailwindcss -i ./input.css -o ./assets/tailwind.css --watch
Run the following command to install the Dioxus CLI:
cargo install dioxus-cli
Run the following command in the root of the project to start the Dioxus dev server:
dx serve --hot-reload