-
Notifications
You must be signed in to change notification settings - Fork 0
mindless728/MicroCPU
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Authors: Benjamin Mayes, Colin Barr To generate the preprocessed micro-memory run the following command: cpp -P mMemory.obj > mMemory.o This is required because we were not allowed to submit the Makefile. Aside from this, things are fairly standard. To run a file (for example, example.obj), one simply runs ./CPU example.obj If you find the output to be too verbose, running the program with the flag -b (for brief/brevity mode) will cut out the microinstruction and only show actual instructions. Example: ./CPU -b example.obj Our tests are as follows: TestALU.obj: Tests ALU instructions. inc.obj: Tests pushing to the stack. Loops until the jump is overwritten by ff000000 being pushed to the stack in the location of the jump. IllegalOpcode.obj: A generic illegal opcode. Fibonacci.obj Obtains the nth fibbonacci number in register 3. (sequence starts with the 1st fibonacci number being the second 1, 2nd being 2, etc.) > tests looping > tests conditional jumps > tests move To change n modify the first word of memory. Binary_Search.obj A binary search. If it finds the element it will perform a MOV R2, R2 at the end of execution to notify the user. AM_Test.obj Tests all of the address modes via jumping to the next instruction Mul_Test.obj multiplies 2048*512 using a for loop (over 2048) of addition of 512 Push_Pop_Test.obj tests settign up stack pointer (R15), pushing a register, clearing it, and poping it to confirm it works
About
Computer Architecture Project
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published