The RISC-VI Processor is an unofficial successor to the popular RISC-V processor. Based on the Von Neumann Architecture, it is being designed and built using System Verilog. Synthesizing and testing is done in Xilinx Vivado.
This document is the development log and guide to the processor. Updated daily with progress.
| Deadline | Objective |
|---|---|
| TBD | Finish RISC-IV Datapath + Simulation |
| September 5 | Finish OS Binary Code |
| September 30 | Finish Assembly Language + Compiler |
| Date | Task | Assigned | Status |
|---|---|---|---|
| May 20, 2025 | Set up doc | Tanmay | Complete |
| May 21, 2025 | Began ISA Draft. Drafted register file. Began ALU (no pipelining). Added CPU core module. | Tanmay | Complete |
| May 22, 2025 | Researched memory caching. Implemented 4-byte addressable, 4096 address space memory. | Tanmay | Complete |
| May 29, 2025 | Wrote more of the ISA. | Tanmay | Complete |
| Jul 28, 2025 | Finish Un-privileged ISA | Tanmay | In progress |
| Jul 30, 2025 | Finish Privileged ISA: trap vectors, interrupts. Define pipeline stages (IF, ID, EX, MEM, WB). | Tanmay | Not started |
| Aug 2, 2025 | Finish instruction FSM/microcodes in control unit. Determine control signals and instruction decoder logic. | Tanmay | Not started |
| Aug 11, 2025 | Create pipeline register modules (IF/ID, ID/EX, EX/MEM, MEM/WB). Add hazard detection skeleton. Integrate ALU, memory, reg file. | Tanmay | Not started |
| Aug 15, 2025 | Add branch/jump resolution logic. Implement basic branch predictor. Handle mispredictions. Test branch-heavy programs. | Tanmay | Not started |
| Aug 31, 2025 | Hook up trap handler. Build CSR logic. Handle ECALL, EBREAK, TRAP-like instructions. | Tanmay | Not started |
| Sep 7, 2025 | Finalize processor top module. Write testbench and memory preload script. Simulate instruction traces. Run a basic program end-to-end. | Tanmay | Not started |
- The RISC-VI Processor is based on the Von Neumann Architecture.
- Written in System Verilog, tested using Xilinx Vivado.
- Code Repository (GitHub)
- 32-bit architecture
- Instructions are 32 bits long
- Opcode:
[6:0]
-
Performs selected operation on two operand registers.
-
Stores result in destination register.
-
funct3 [9:7]:000: ADD001: SUB010: OR011: AND100: MUL101: DIV110: XOR111: NOR
-
[16:11]:funct6 -
[21:17]: Destination Register -
[26:22]: Operand Register 2 -
[31:27]: Operand Register 1
-
Operates on one register + immediate.
-
Stores result in destination register.
-
funct3 [9:7]same as above, ending with:111: Unused
-
[21:10]: 12-bit Immediate -
[26:22]: Destination Register -
[31:27]: Operand Register
-
Shift operation using register or immediate.
-
funct3 [9:7]:000: SLL001: SRL010: SRA011: SLLI100: SRLI101: SRAI
- Conditional break using NZP flags
[9:7]: Operand condition[31:10]: 25-bit signed immediate offset
- Compare two registers, conditional jump
[9:7]: Operand condition[21:10]: 12-bit offset[26:22]: Operand Register 2[31:27]: Operand Register 1
- Unconditional jump, stores PC in dest reg
[26:7]: 20-bit immediate[31:27]: Destination Register
- Jump to reg + imm, store PC in reg
[21:7]: 15-bit immediate[26:22]: Destination Register[31:27]: Operand Register
- Return from subroutine
[31:27]: Operand Register (holds return addr)
-
funct3 [9:7]:000: LD — PC + offset → dest001: LDR — reg + offset → dest010: LB — lower 8 bits, sign-extended011: LBU — lower 8 bits, zero-extended100: LH — lower 16 bits, sign-extended101: LHU — lower 16 bits, zero-extended
-
funct3 [9:7]:000: ST — PC + offset ← reg value001: STR — reg2 + offset ← reg1 value010: SB — Store lower 8 bits011: SH — Store lower 16 bits
HALT: Vector x0PUT: OutputINT,EXP: Interrupts, exceptions
Handles instruction control logic.
- 32 registers, 4 bytes each.
x0is always0.
Inputs:
clk,rst,rwsource1,source2,dest(5-bit addresses)write_data(32-bit)
Outputs:
read_data1,read_data2(32-bit)
- Functions: ADD, SUB, AND, OR, SLL, SRL, SRA
Inputs:
clk,func(3-bit),operand_1,operand_2
Output:
result(32-bit)
- Size: 32 bits
Inputs:
clk,ld,address_inOutput:address_out
- Byte addressable, 16384-bit address space
Inputs:
clk,address(12-bit truncated) Output:data
Inputs: clk, data_in
Output: data_out
- 32-bit shared bus
- All inputs use tri-state buffers
Inputs: MDR, etc. Outputs: TBD
NOTinstruction usesfunct3 = 111with zero register- Same opcode can map to multiple mnemonics