feat: implement privileged mode support

This commit is contained in:
abnerhexu
2026-06-29 07:00:55 +00:00
parent a32db39c80
commit b6afa61e66
89 changed files with 49571 additions and 43647 deletions

View File

@@ -0,0 +1,38 @@
// Generated by CIRCT firtool-1.139.0
// Users can define 'STOP_COND' to add an extra gate to stop conditions.
`ifndef STOP_COND_
`ifdef STOP_COND
`define STOP_COND_ (`STOP_COND)
`else // STOP_COND
`define STOP_COND_ 1
`endif // STOP_COND
`endif // not def STOP_COND_
// Users can define 'ASSERT_VERBOSE_COND' to add an extra gate to assert error printing.
`ifndef ASSERT_VERBOSE_COND_
`ifdef ASSERT_VERBOSE_COND
`define ASSERT_VERBOSE_COND_ (`ASSERT_VERBOSE_COND)
`else // ASSERT_VERBOSE_COND
`define ASSERT_VERBOSE_COND_ 1
`endif // ASSERT_VERBOSE_COND
`endif // not def ASSERT_VERBOSE_COND_
module DCache_Verification_Assert();
`ifndef SYNTHESIS
always @(posedge DCache.clock) begin
if (~DCache.reset & DCache.io_reqValid
& (|((DCache._storeEndSet_T_6
? 3'h0
: DCache._storeEndSet_T_4
? 3'h4
: DCache._storeEndSet_T_2 ? 3'h2 : {2'h0, DCache._storeEndSet_T})
- 3'h1 & DCache.io_req_addr[2:0]))) begin
if (`ASSERT_VERBOSE_COND_)
$error("Assertion failed: DCache received misaligned request; LSU must trap before DCache\n");
if (`STOP_COND_)
$fatal;
end
end // always @(posedge)
`endif // not def SYNTHESIS
endmodule

View File

@@ -2,4 +2,5 @@
`ifndef layers_Core_Verification_Assert
`define layers_Core_Verification_Assert
`include "layers-Core-Verification.sv"
`include "layers-OoOBackend-Verification-Assert.sv"
`endif // not def layers_Core_Verification_Assert

View File

@@ -0,0 +1,6 @@
// Generated by CIRCT firtool-1.139.0
`ifndef layers_DCache_Verification_Assert
`define layers_DCache_Verification_Assert
`include "layers-DCache-Verification.sv"
bind DCache DCache_Verification_Assert verification_assert ();
`endif // not def layers_DCache_Verification_Assert

View File

@@ -0,0 +1,6 @@
// Generated by CIRCT firtool-1.139.0
`ifndef layers_LSU_Verification_Assert
`define layers_LSU_Verification_Assert
`include "layers-LSU-Verification.sv"
`include "layers-DCache-Verification-Assert.sv"
`endif // not def layers_LSU_Verification_Assert

View File

@@ -0,0 +1,6 @@
// Generated by CIRCT firtool-1.139.0
`ifndef layers_OoOBackend_Verification_Assert
`define layers_OoOBackend_Verification_Assert
`include "layers-OoOBackend-Verification.sv"
`include "layers-LSU-Verification-Assert.sv"
`endif // not def layers_OoOBackend_Verification_Assert

View File

@@ -1,4 +1,5 @@
// Generated by CIRCT firtool-1.139.0
`ifndef layers_Core_Verification
`define layers_Core_Verification
`include "layers-OoOBackend-Verification.sv"
`endif // not def layers_Core_Verification

View File

@@ -0,0 +1,4 @@
// Generated by CIRCT firtool-1.139.0
`ifndef layers_DCache_Verification
`define layers_DCache_Verification
`endif // not def layers_DCache_Verification

View File

@@ -0,0 +1,5 @@
// Generated by CIRCT firtool-1.139.0
`ifndef layers_LSU_Verification
`define layers_LSU_Verification
`include "layers-DCache-Verification.sv"
`endif // not def layers_LSU_Verification

View File

@@ -1,6 +1,5 @@
// Generated by CIRCT firtool-1.139.0
`ifndef layers_OoOBackend_Verification
`define layers_OoOBackend_Verification
`include "layers-RenameStage-Verification.sv"
bind OoOBackend OoOBackend_Verification verification ();
`include "layers-LSU-Verification.sv"
`endif // not def layers_OoOBackend_Verification