Question: Design a RISC ALU (arithmetic and logic unit) which performs all of the core computations dictated by the assembly language. You can also consult section
Design a RISC ALU (arithmetic and logic unit) which performs all of the core computations dictated by the assembly language. You can also consult section A.5 in your textbook.
We will be using Logisim, a free hardware design and circuit simulation tool. Logisim comes with libraries containing basic gates, memory chips, multiplexers and decoders, and other simple components.
However, for this assignment you may only use the following Logisim elements:
- Anything in the Wiring except for the resistor, constant, power, ground and transistor elements.
- Anything in the Base folder (wires, text, etc.)
- Anything in the Gates folder except for the even parity, odd parity, and controlled buffer elements
- Anything in the Plexers folder
All of the following should be subcircuits in a single Logisim circuit file.
What to Submit
- A single Logisim project file containing your ALU and all needed subcomponents. Please ensure that your circuit has no external dependencies!
- The inputs/outputs are named "A" - First input, "B" - second input, "Op" - Operation code, "Sa" -Shift Amount, "C" - Result, and "V" - Overflow. Inputs should have at least 4 bits.
- A design document with details the implementation of your circuit.
Circuit ALU
| Op | name | C | V |
|---|---|---|---|
| 000 | or | C = A | B | V = 0 |
| 001 | nor | C = ~(A | B) | V = 0 |
| 010 | and | C = A & B | V = 0 |
| 011 | xor | C = A ^ B | V = 0 |
| 100 | add | C = A + B | V = overflow |
| 101 | subtract | C = A - B | V = overflow |
| 110 | shift left logical | C = B << Sa | V = 0 |
| 111 | shift right logical | C = B >> Sa | V = 0 |
if you cannot submit the file please submit screenshots of what you did to get to how you did it
textbook is Computer Organization and Design RISC-V Edition
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
