alcatrazescapee / elec-374 Goto Github PK
View Code? Open in Web Editor NEWELEC 374 CPU Design Project
ELEC 374 CPU Design Project
Need to implement the following registers (which are all the same general register)
R0
to R15
, PC
, IR
, Y
, Z
, MAR
, HI
, and LO
(although snake_case
name them ofc)Bus:
cpu
top level module?)This is all the simulation / verification requirements the project / phase 1 description states. I would assume we have more (also automated ones, because those are cool), but we need to complete at least:
and R5, R2, R4
or R5, R2, R4
add R5, R2, R4
sub R5, R2, R4
mul R2, R4
div R2, R4
shr R5, R2, R4
shl R5, R2, R4
ror R5, R2, R4
rol R5, R2, R4
neg R5, R2
not R5, R2
And final report:
The phase 1 report in hard/soft copy (one per group) should include:
Fairly straightforward, Mux + Register, as per on the spec
Need to implement the following instructions:
add
, sub
mul
div
div
and mul
(maybe a CSA as well?)and
, or
, not
: None of these need a module of their own, they are one-liners.neg
(Negate)
shr
>>>
operator).shl
ror
rol
Issues:
Solution: Makefile! (and some other buisness)
.mif
for proper initialization.=
, !=
, <
and >
flagsin
/ out
instructions, and connect to datapath.Already Done:
mfhi
, mflo
, Memory instructions, ALU Immediate instructions.Still To-Do:
brzr
, brnz
, brpl
, brmi`)jal
jr
in
/ out
- Anything we need to do control wise w/ enable / wait signals for async IO?nop
halt
- It exists but it does not do anything. Both halt, reset signals need to be implemented in hardwareSimulations of the following instructions (might need to modify the ones that potentially write to r0
:
ld r1, 85
ld r0, 35(r1)
ldi r1, 85
ldi r0, 35(r1)
st 90, r1
st 90(r1), r1
addi r2, r1, -5
andi r2, r1, 26
ori r2, r1, 26
brzr r2, 35
brnx r2, 35
brpl r2, 35
brmi r2, 35
jr r1
jal r1
mfhi r2
mflo r2
out r1
in r1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.