A MIPS Pipeline Simulator built with Python and Streamlit that allows users to upload MIPS assembly files and simulate the execution of a pipeline. The simulator provides a cycle-by-cycle view of the register values, showing how the MIPS assembly instructions execute in stages.
- File Upload: Upload a MIPS assembly (.asm) file for simulation.
- MIPS Assembly to Machine Code: Converts MIPS assembly instructions to binary machine code.
- Cycle-by-Cycle Execution: Simulates each pipeline stage and shows register values for each cycle.
- Interactive Register Viewer: View register states in the Streamlit sidebar by selecting specific cycles.
pipeline
: ContainsMIPSPipeline
class to handle cycle-by-cycle execution.parser
: Contains theMIPSParser
class to parse the machine code.utils
: Holds theMIPSAssembler
for parsing and converting MIPS assembly to machine code.components
: IncludesALU
,Registers
andMemory
that is components for handling MIPS instructions.app.py
: The Streamlit app that serves as the user interface and controller for the simulation.
Install dependencies with:
pip install -r requirements.txt
To use streamlit
streamlit run app.py