mirror of
https://github.com/openhwgroup/cvw
synced 2025-02-11 06:05:49 +00:00
Renamed signals in RAS.
This commit is contained in:
parent
b4854d8e94
commit
e7b91d5934
@ -42,7 +42,7 @@ module RASPredictor #(parameter int StackSize = 16 )(
|
||||
logic CounterEn;
|
||||
localparam Depth = $clog2(StackSize);
|
||||
|
||||
logic [Depth-1:0] PtrD, PtrQ, PtrP1, PtrM1;
|
||||
logic [Depth-1:0] NextPtr, CurrPtr, PtrP1, PtrM1;
|
||||
logic [StackSize-1:0] [`XLEN-1:0] memory;
|
||||
integer index;
|
||||
|
||||
@ -70,12 +70,12 @@ module RASPredictor #(parameter int StackSize = 16 )(
|
||||
assign CounterEn = PopF | PushE | RepairD;
|
||||
|
||||
assign DecrementPtr = (PopF | DecRepairD) & ~IncrRepairD;
|
||||
mux2 #(Depth) PtrMux(PtrP1, PtrM1, DecrementPtr, PtrD);
|
||||
mux2 #(Depth) PtrMux(PtrP1, PtrM1, DecrementPtr, NextPtr);
|
||||
|
||||
assign PtrM1 = PtrQ - 1'b1;
|
||||
assign PtrP1 = PtrQ + 1'b1;
|
||||
assign PtrM1 = CurrPtr - 1'b1;
|
||||
assign PtrP1 = CurrPtr + 1'b1;
|
||||
|
||||
flopenr #(Depth) PTR(clk, reset, CounterEn, PtrD, PtrQ);
|
||||
flopenr #(Depth) PTR(clk, reset, CounterEn, NextPtr, CurrPtr);
|
||||
|
||||
// RAS must be reset.
|
||||
always_ff @ (posedge clk) begin
|
||||
@ -87,7 +87,7 @@ module RASPredictor #(parameter int StackSize = 16 )(
|
||||
end
|
||||
end
|
||||
|
||||
assign RASPCF = memory[PtrQ];
|
||||
assign RASPCF = memory[CurrPtr];
|
||||
|
||||
|
||||
endmodule
|
||||
|
Loading…
Reference in New Issue
Block a user