This is the MIPS32r2 VArchC functional model.
This model supports quite a few MIPS32r2 instructions, enough to compile Mibench programs and run them correctly. However, this implementation does not feature all instructions from the ISA specification, but only those appearing in benchmarks. If you run into an implemented instruction, you can easily expand this model.
It is possible that your program uses an unimplemented syscall, since this is not a system simulator, but a process simulator. If this syscall is crucial to your program, you may need to expand ArchC to implement it.
- ArchC models are provided under the ArchC license. See Copying file for details on this license.
You need VArchC to build and use this model. Refer to the VArchC repository for more information. Use acsim to create the simulator and build it using GNU Make.
acsim mips.ac -abi
make
We recommend using the ELLCC compiler to compile applications for MIPS32r2. Download ELLCC v0.1.34 and extract it to a directory. The bin subdirectory contains all the ELLCC executables. To compile a "hello.c" application for MIPS, use:
ecc -target mips32r2-linux -o hello.mips hello.c
We provide source code for test applications to be used with our CPU models, including this MIPS model. Refer to our Testbench repository for more information.