Project Type
HDL Final Project
HDL Final Project
A modular application-specific processor designed to move an entire 4 × 4 matrix in one bus transaction and execute matrix and integer operations through a shared 256-bit datapath.

Project Type
HDL Final Project
Datapath
256-Bit Shared Bus
Matrix Format
4 × 4, 16-Bit Elements
Verification
Vivado / XSim
Overview
This project implements a soft processor in SystemVerilog with separate instruction memory, main memory, matrix ALU, integer ALU, execution engine, and simulation modules. Every component communicates through one address-decoded, 256-bit tri-state bus.
The wide datapath is the defining architectural choice: all sixteen elements of a 4 × 4 matrix fit in a single word. The execution engine controls which module owns the bus, sequences each transfer, and routes completed results back to memory or its internal registers.
Architecture
The upper address nibble selects a processor module, while lower address bits select a local memory location or register. A selected source drives the bus; all other modules remain in a high-impedance state until the controller authorizes them to transmit.
Fetches and decodes 32-bit instructions, coordinates bus transfers, selects the correct ALU, and advances a multi-cycle control state machine.
Treats each 256-bit operand as a complete 4 × 4 matrix of sixteen 16-bit elements and performs arithmetic and transformation operations.
Provides addition, subtraction, multiplication, and division using the same shared 256-bit source and result registers.
Separate instruction and main memories store the program, matrices, integer values, intermediate values, and completed results.
Instruction Cycle
Each 32-bit instruction identifies an opcode, destination, and two operand sources. The controller fetches and decodes the instruction, moves each operand to the selected ALU, starts the operation, waits for its result, and writes that result to its destination before fetching the next instruction.
Matrix opcodes are routed to the matrix ALU, while opcodes beginning with hexadecimal 1 select the integer ALU. Opcode 0xFF cleanly stops processor execution and allows the test environment to check results.

Compute Capabilities
The integer ALU supports addition, subtraction, multiplication, and division. Its operands and result use the same 256-bit transfer path, allowing both compute units to share the memory and control system.
Verification
The included program exercises matrix addition, scaling, subtraction, transpose and multiplication, as well as all four integer operations and transfers through internal registers.
Design Highlights
Explore the Project