mirror of
https://github.com/openhwgroup/cvw
synced 2025-02-11 06:05:49 +00:00
renamed FLoad2 to FStore2
This commit is contained in:
parent
97e7e619d9
commit
62205ebb3b
4
pipelined/src/cache/cache.sv
vendored
4
pipelined/src/cache/cache.sv
vendored
@ -43,7 +43,7 @@ module cache #(parameter LINELEN, NUMLINES, NUMWAYS, LOGWPL, WORDLEN, MUXINTER
|
|||||||
input logic [`PA_BITS-1:0] PAdr, // physical address
|
input logic [`PA_BITS-1:0] PAdr, // physical address
|
||||||
input logic [(`XLEN-1)/8:0] ByteMask,
|
input logic [(`XLEN-1)/8:0] ByteMask,
|
||||||
input logic [WORDLEN-1:0] FinalWriteData,
|
input logic [WORDLEN-1:0] FinalWriteData,
|
||||||
input logic FLoad2,
|
input logic FStore2,
|
||||||
output logic CacheCommitted,
|
output logic CacheCommitted,
|
||||||
output logic CacheStall,
|
output logic CacheStall,
|
||||||
// to performance counters to cpu
|
// to performance counters to cpu
|
||||||
@ -121,7 +121,7 @@ module cache #(parameter LINELEN, NUMLINES, NUMWAYS, LOGWPL, WORDLEN, MUXINTER
|
|||||||
|
|
||||||
// Array of cache ways, along with victim, hit, dirty, and read merging logic
|
// Array of cache ways, along with victim, hit, dirty, and read merging logic
|
||||||
cacheway #(NUMLINES, LINELEN, TAGLEN, OFFSETLEN, SETLEN)
|
cacheway #(NUMLINES, LINELEN, TAGLEN, OFFSETLEN, SETLEN)
|
||||||
CacheWays[NUMWAYS-1:0](.clk, .reset, .RAdr, .PAdr, .CacheWriteData, .ByteMask, .FLoad2,
|
CacheWays[NUMWAYS-1:0](.clk, .reset, .RAdr, .PAdr, .CacheWriteData, .ByteMask, .FStore2,
|
||||||
.SetValidWay, .ClearValidWay, .SetDirtyWay, .ClearDirtyWay, .SelEvict, .VictimWay,
|
.SetValidWay, .ClearValidWay, .SetDirtyWay, .ClearDirtyWay, .SelEvict, .VictimWay,
|
||||||
.FlushWay, .SelFlush, .ReadDataLineWay, .HitWay, .VictimDirtyWay, .VictimTagWay,
|
.FlushWay, .SelFlush, .ReadDataLineWay, .HitWay, .VictimDirtyWay, .VictimTagWay,
|
||||||
.Invalidate(InvalidateCacheM));
|
.Invalidate(InvalidateCacheM));
|
||||||
|
4
pipelined/src/cache/cacheway.sv
vendored
4
pipelined/src/cache/cacheway.sv
vendored
@ -38,7 +38,7 @@ module cacheway #(parameter NUMLINES=512, parameter LINELEN = 256, TAGLEN = 26,
|
|||||||
input logic [$clog2(NUMLINES)-1:0] RAdr,
|
input logic [$clog2(NUMLINES)-1:0] RAdr,
|
||||||
input logic [`PA_BITS-1:0] PAdr,
|
input logic [`PA_BITS-1:0] PAdr,
|
||||||
input logic [LINELEN-1:0] CacheWriteData,
|
input logic [LINELEN-1:0] CacheWriteData,
|
||||||
input logic FLoad2,
|
input logic FStore2,
|
||||||
input logic SetValidWay,
|
input logic SetValidWay,
|
||||||
input logic ClearValidWay,
|
input logic ClearValidWay,
|
||||||
input logic SetDirtyWay,
|
input logic SetDirtyWay,
|
||||||
@ -79,7 +79,7 @@ module cacheway #(parameter NUMLINES=512, parameter LINELEN = 256, TAGLEN = 26,
|
|||||||
logic [2**LOGWPL-1:0] MemPAdrDecodedtmp;
|
logic [2**LOGWPL-1:0] MemPAdrDecodedtmp;
|
||||||
onehotdecoder #(LOGWPL) adrdec(
|
onehotdecoder #(LOGWPL) adrdec(
|
||||||
.bin(PAdr[LOGWPL+LOGXLENBYTES-1:LOGXLENBYTES]), .decoded(MemPAdrDecodedtmp));
|
.bin(PAdr[LOGWPL+LOGXLENBYTES-1:LOGXLENBYTES]), .decoded(MemPAdrDecodedtmp));
|
||||||
assign MemPAdrDecoded = MemPAdrDecodedtmp|{MemPAdrDecodedtmp[2**LOGWPL-2:0]&{2**LOGWPL-1{FLoad2}}, 1'b0};
|
assign MemPAdrDecoded = MemPAdrDecodedtmp|{MemPAdrDecodedtmp[2**LOGWPL-2:0]&{2**LOGWPL-1{FStore2}}, 1'b0};
|
||||||
end else
|
end else
|
||||||
onehotdecoder #(LOGWPL) adrdec(
|
onehotdecoder #(LOGWPL) adrdec(
|
||||||
.bin(PAdr[LOGWPL+LOGXLENBYTES-1:LOGXLENBYTES]), .decoded(MemPAdrDecoded));
|
.bin(PAdr[LOGWPL+LOGXLENBYTES-1:LOGXLENBYTES]), .decoded(MemPAdrDecoded));
|
||||||
|
@ -42,7 +42,7 @@ module fpu (
|
|||||||
input logic [1:0] STATUS_FS, // Is floating-point enabled?
|
input logic [1:0] STATUS_FS, // Is floating-point enabled?
|
||||||
output logic FRegWriteM, // FP register write enable
|
output logic FRegWriteM, // FP register write enable
|
||||||
output logic FpLoadStoreM, // Fp load instruction?
|
output logic FpLoadStoreM, // Fp load instruction?
|
||||||
output logic FLoad2,
|
output logic FStore2,
|
||||||
output logic FStallD, // Stall the decode stage
|
output logic FStallD, // Stall the decode stage
|
||||||
output logic FWriteIntE, // integer register write enables
|
output logic FWriteIntE, // integer register write enables
|
||||||
output logic [`XLEN-1:0] FWriteDataE, // Data to be written to memory
|
output logic [`XLEN-1:0] FWriteDataE, // Data to be written to memory
|
||||||
@ -298,8 +298,8 @@ module fpu (
|
|||||||
assign FWriteDataE = FSrcYE[`XLEN-1:0];
|
assign FWriteDataE = FSrcYE[`XLEN-1:0];
|
||||||
end else begin
|
end else begin
|
||||||
logic [`FLEN-1:0] FWriteDataE;
|
logic [`FLEN-1:0] FWriteDataE;
|
||||||
if(`FMTBITS == 2) assign FLoad2 = FmtM == `FMT;
|
if(`FMTBITS == 2) assign FStore2 = FmtM == `FMT;
|
||||||
else assign FLoad2 = FmtM;
|
else assign FStore2 = FmtM;
|
||||||
|
|
||||||
if (`FPSIZES==1) assign FWriteDataE = FSrcYE;
|
if (`FPSIZES==1) assign FWriteDataE = FSrcYE;
|
||||||
else if (`FPSIZES==2) assign FWriteDataE = FmtE ? FSrcYE : {2{FSrcYE[`LEN1-1:0]}};
|
else if (`FPSIZES==2) assign FWriteDataE = FmtE ? FSrcYE : {2{FSrcYE[`LEN1-1:0]}};
|
||||||
|
@ -226,7 +226,7 @@ module ifu (
|
|||||||
icache(.clk, .reset, .CPUBusy, .IgnoreRequestTLB(ITLBMissF), .TrapM(TrapM), .IgnoreRequestTrapM('0),
|
icache(.clk, .reset, .CPUBusy, .IgnoreRequestTLB(ITLBMissF), .TrapM(TrapM), .IgnoreRequestTrapM('0),
|
||||||
.CacheBusWriteData(ICacheBusWriteData), .CacheBusAck(ICacheBusAck),
|
.CacheBusWriteData(ICacheBusWriteData), .CacheBusAck(ICacheBusAck),
|
||||||
.CacheBusAdr(ICacheBusAdr), .CacheStall(ICacheStallF),
|
.CacheBusAdr(ICacheBusAdr), .CacheStall(ICacheStallF),
|
||||||
.CacheFetchLine(ICacheFetchLine), .FLoad2(),
|
.CacheFetchLine(ICacheFetchLine), .FStore2(),
|
||||||
.CacheWriteLine(), .ReadDataWord(FinalInstrRawF),
|
.CacheWriteLine(), .ReadDataWord(FinalInstrRawF),
|
||||||
.Cacheable(CacheableF),
|
.Cacheable(CacheableF),
|
||||||
.CacheMiss(ICacheMiss), .CacheAccess(ICacheAccess),
|
.CacheMiss(ICacheMiss), .CacheAccess(ICacheAccess),
|
||||||
|
@ -58,7 +58,7 @@ module lsu (
|
|||||||
input logic sfencevmaM,
|
input logic sfencevmaM,
|
||||||
// fpu
|
// fpu
|
||||||
input logic [`FLEN-1:0] FWriteDataM,
|
input logic [`FLEN-1:0] FWriteDataM,
|
||||||
input logic FLoad2,
|
input logic FStore2,
|
||||||
input logic FpLoadStoreM,
|
input logic FpLoadStoreM,
|
||||||
// faults
|
// faults
|
||||||
output logic LoadPageFaultM, StoreAmoPageFaultM,
|
output logic LoadPageFaultM, StoreAmoPageFaultM,
|
||||||
@ -236,14 +236,14 @@ module lsu (
|
|||||||
|
|
||||||
if(CACHE_ENABLED) begin : dcache
|
if(CACHE_ENABLED) begin : dcache
|
||||||
if (`LLEN>`FLEN)
|
if (`LLEN>`FLEN)
|
||||||
mux2 #(`LLEN) datamux({(`LLEN-`XLEN)'(0), IEUWriteDataM}, FWriteDataM, FpLoadStoreM, FinalWriteDataM);
|
mux2 #(`LLEN) datamux({{`LLEN-`XLEN{1'b0}}, IEUWriteDataM}, FWriteDataM, FpLoadStoreM, FinalWriteDataM);
|
||||||
else
|
else
|
||||||
assign FinalWriteDataM[`XLEN-1:0] = IEUWriteDataM;
|
assign FinalWriteDataM = {{`LLEN-`XLEN{1'b0}}, IEUWriteDataM};
|
||||||
cache #(.LINELEN(`DCACHE_LINELENINBITS), .NUMLINES(`DCACHE_WAYSIZEINBYTES*8/LINELEN),
|
cache #(.LINELEN(`DCACHE_LINELENINBITS), .NUMLINES(`DCACHE_WAYSIZEINBYTES*8/LINELEN),
|
||||||
.NUMWAYS(`DCACHE_NUMWAYS), .LOGWPL(LOGWPL), .WORDLEN(`LLEN), .MUXINTERVAL(`XLEN), .DCACHE(1)) dcache(
|
.NUMWAYS(`DCACHE_NUMWAYS), .LOGWPL(LOGWPL), .WORDLEN(`LLEN), .MUXINTERVAL(`XLEN), .DCACHE(1)) dcache(
|
||||||
.clk, .reset, .CPUBusy, .LSUBusWriteCrit, .RW(LSURWM), .Atomic(LSUAtomicM),
|
.clk, .reset, .CPUBusy, .LSUBusWriteCrit, .RW(LSURWM), .Atomic(LSUAtomicM),
|
||||||
.FlushCache(FlushDCacheM), .NextAdr(LSUAdrE), .PAdr(LSUPAdrM),
|
.FlushCache(FlushDCacheM), .NextAdr(LSUAdrE), .PAdr(LSUPAdrM),
|
||||||
.ByteMask(ByteMaskM), .WordCount, .FLoad2,
|
.ByteMask(ByteMaskM), .WordCount, .FStore2,
|
||||||
.FinalWriteData(FinalWriteDataM), .Cacheable(CacheableM),
|
.FinalWriteData(FinalWriteDataM), .Cacheable(CacheableM),
|
||||||
.CacheStall(DCacheStallM), .CacheMiss(DCacheMiss), .CacheAccess(DCacheAccess),
|
.CacheStall(DCacheStallM), .CacheMiss(DCacheMiss), .CacheAccess(DCacheAccess),
|
||||||
.IgnoreRequestTLB, .IgnoreRequestTrapM, .TrapM(1'b0), .CacheCommitted(DCacheCommittedM),
|
.IgnoreRequestTLB, .IgnoreRequestTrapM, .TrapM(1'b0), .CacheCommitted(DCacheCommittedM),
|
||||||
|
@ -93,7 +93,7 @@ module wallypipelinedcore (
|
|||||||
logic FStallD;
|
logic FStallD;
|
||||||
logic FWriteIntE;
|
logic FWriteIntE;
|
||||||
logic [`XLEN-1:0] FWriteDataE;
|
logic [`XLEN-1:0] FWriteDataE;
|
||||||
logic FLoad2;
|
logic FStore2;
|
||||||
logic [`FLEN-1:0] FWriteDataM;
|
logic [`FLEN-1:0] FWriteDataM;
|
||||||
logic [`XLEN-1:0] FIntResM;
|
logic [`XLEN-1:0] FIntResM;
|
||||||
logic [`XLEN-1:0] FCvtIntResW;
|
logic [`XLEN-1:0] FCvtIntResW;
|
||||||
@ -259,7 +259,7 @@ module wallypipelinedcore (
|
|||||||
.CommittedM, .DCacheMiss, .DCacheAccess,
|
.CommittedM, .DCacheMiss, .DCacheAccess,
|
||||||
.SquashSCW,
|
.SquashSCW,
|
||||||
.FpLoadStoreM,
|
.FpLoadStoreM,
|
||||||
.FWriteDataM, .FLoad2,
|
.FWriteDataM, .FStore2,
|
||||||
//.DataMisalignedM(DataMisalignedM),
|
//.DataMisalignedM(DataMisalignedM),
|
||||||
.IEUAdrE, .IEUAdrM, .WriteDataE,
|
.IEUAdrE, .IEUAdrM, .WriteDataE,
|
||||||
.ReadDataW, .FlushDCacheM,
|
.ReadDataW, .FlushDCacheM,
|
||||||
@ -400,7 +400,7 @@ module wallypipelinedcore (
|
|||||||
.STATUS_FS, // is floating-point enabled?
|
.STATUS_FS, // is floating-point enabled?
|
||||||
.FRegWriteM, // FP register write enable
|
.FRegWriteM, // FP register write enable
|
||||||
.FpLoadStoreM,
|
.FpLoadStoreM,
|
||||||
.FLoad2,
|
.FStore2,
|
||||||
.FStallD, // Stall the decode stage
|
.FStallD, // Stall the decode stage
|
||||||
.FWriteIntE, // integer register write enable
|
.FWriteIntE, // integer register write enable
|
||||||
.FWriteDataE, // Data to be written to memory
|
.FWriteDataE, // Data to be written to memory
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
string tvpaths[] = '{
|
string tvpaths[] = '{
|
||||||
"../../addins/imperas-riscv-tests/work/",
|
"../../addins/imperas-riscv-tests/work/",
|
||||||
"../../tests/riscof/work/riscv-arch-test/",
|
"../../tests/riscof/work/riscv-arch-test/",
|
||||||
"../../tests/riscof/work/wally-riscv-arch-test/", //"../../tests/wally-riscv-arch-test/work/", //
|
"../../tests/wally-riscv-arch-test/work/", //"../../tests/riscof/work/wally-riscv-arch-test/", //
|
||||||
"../../tests/imperas-riscv-tests/work/",
|
"../../tests/imperas-riscv-tests/work/",
|
||||||
"../../benchmarks/coremark/work/",
|
"../../benchmarks/coremark/work/",
|
||||||
"../../addins/embench-iot/"
|
"../../addins/embench-iot/"
|
||||||
|
Loading…
Reference in New Issue
Block a user