Formatting.

This commit is contained in:
Ross Thompson 2023-01-18 18:05:11 -06:00
parent 2622f5dfb8
commit 40c0e67930
2 changed files with 20 additions and 16 deletions

View File

@ -1,10 +1,13 @@
/////////////////////////////////////////// ///////////////////////////////////////////
// atomic.sv // atomic.sv
// //
// Written: Ross Thompson ross1728@gmail.com January 31, 2022 // Written: Ross Thompson ross1728@gmail.com
// Modified: // Created: 31 January 2022
// Modified: 18 January 2023
// //
// Purpose: atomic data path. // Purpose: Wrapper for amoalu and lrsc
//
// Documentation: RISC-V System on Chip Design Chapter 14 (Figure ***)
// //
// A component of the CORE-V-WALLY configurable RISC-V project. // A component of the CORE-V-WALLY configurable RISC-V project.
// //
@ -28,18 +31,19 @@
module atomic ( module atomic (
input logic clk, input logic clk,
input logic reset, StallW, input logic reset,
input logic [`XLEN-1:0] ReadDataM, input logic StallW,
input logic [`XLEN-1:0] IHWriteDataM, input logic [`XLEN-1:0] ReadDataM, // LSU ReadData XLEN because FPU does not issue atomic memory operation from FPU registers
input logic [`PA_BITS-1:0] PAdrM, input logic [`XLEN-1:0] IHWriteDataM, // LSU WriteData XLEN because FPU does not issue atomic memory operation from FPU registers
input logic [6:0] LSUFunct7M, input logic [`PA_BITS-1:0] PAdrM, // Physical memory address
input logic [2:0] LSUFunct3M, input logic [6:0] LSUFunct7M, // AMO alu operation gated by HPTW
input logic [1:0] LSUAtomicM, input logic [2:0] LSUFunct3M, // IEU or HPTW memory operation size
input logic [1:0] PreLSURWM, input logic [1:0] LSUAtomicM, // 10: AMO operation, select AMOResult as the writedata output, 01: LR/SC operation
input logic IgnoreRequest, input logic [1:0] PreLSURWM, // IEU or HPTW Read/Write signal
output logic [`XLEN-1:0] IMAWriteDataM, input logic IgnoreRequest, // On FlushM or TLB miss ignore memory operation
output logic SquashSCW, output logic [`XLEN-1:0] IMAWriteDataM, // IEU, HPTW, or AMO write data
output logic [1:0] LSURWM output logic SquashSCW, // Store conditional failed disable write to GPR
output logic [1:0] LSURWM // IEU or HPTW Read/Write signal gated by LR/SC
); );
logic [`XLEN-1:0] AMOResult; logic [`XLEN-1:0] AMOResult;

View File

@ -131,7 +131,7 @@ module lsu (
logic LSULoadAccessFaultM; // Load acces fault logic LSULoadAccessFaultM; // Load acces fault
logic LSUStoreAmoAccessFaultM; // Store access fault logic LSUStoreAmoAccessFaultM; // Store access fault
logic IgnoreRequestTLB; // On either ITLB or DTLB miss, ignore miss so HPTW can handle logic IgnoreRequestTLB; // On either ITLB or DTLB miss, ignore miss so HPTW can handle
logic IgnoreRequest; // On FlushM, ignore TLB miss logic IgnoreRequest; // On FlushM or TLB miss ignore memory operation
logic SelDTIM; // Select DTIM rather than bus or D$ logic SelDTIM; // Select DTIM rather than bus or D$