diff options
| author | Richard Qin <richard.qin.x@gmail.com> | 2026-03-18 01:15:41 +0800 |
|---|---|---|
| committer | Richard Qin <richard.qin.x@gmail.com> | 2026-03-18 01:15:41 +0800 |
| commit | c5ff16613608c91037274aee4d04d4f962eb1f57 (patch) | |
| tree | 61c0bef5b807090d4fc619ae1f744b034ff4b866 /rv64cpu/tb/unit/tb_ex_mem_reg.cc | |
| parent | bd1d53990e8e7b94a2126682a3146de01a0c76ad (diff) | |
| parent | 35b7794d314295bd68b155c25950011a2f1cfcbc (diff) | |
| download | rcc-project-c5ff16613608c91037274aee4d04d4f962eb1f57.tar.gz rcc-project-c5ff16613608c91037274aee4d04d4f962eb1f57.tar.xz | |
Merge pull request #2 from Richard-Qin-001/audit-report-fixes-18055656287044378367
Finalized Richard CPU RTL Audit Report
Diffstat (limited to 'rv64cpu/tb/unit/tb_ex_mem_reg.cc')
| -rw-r--r-- | rv64cpu/tb/unit/tb_ex_mem_reg.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/rv64cpu/tb/unit/tb_ex_mem_reg.cc b/rv64cpu/tb/unit/tb_ex_mem_reg.cc index db1fe8b..75e5502 100644 --- a/rv64cpu/tb/unit/tb_ex_mem_reg.cc +++ b/rv64cpu/tb/unit/tb_ex_mem_reg.cc @@ -53,7 +53,7 @@ int main(int argc, char** argv) { // 1. Init / Reset dut->stall_en = 0; dut->flush_en = 0; - + // Set some random dangerous EX inputs dut->ex_pc = 0x80001000; dut->ex_rs1_rdata = 0x11111111; @@ -119,7 +119,7 @@ int main(int argc, char** argv) { dut->ex_rd_addr = 20; dut->ex_reg_write_en = 0; dut->ex_is_load = 0; - + tick(dut); check(dut->mem_pc == 0x80002000, "Stall_Maintains_PC"); @@ -147,19 +147,19 @@ int main(int argc, char** argv) { dut->ex_branch_taken = 1; dut->ex_reg_write_en = 1; dut->ex_is_store = 1; - + tick(dut); check(dut->mem_pc == 0x80003000, "Flush_Maintains_PC"); check(dut->mem_branch_taken == 0, "Flush_Clears_BranchTaken"); - check(dut->mem_reg_write_en == 0, "Flush_Clears_RegWrite"); - check(dut->mem_is_store == 0, "Flush_Clears_StoreEn"); + check(dut->mem_reg_write_en == 0, "Flush_Clears_RegWrite"); + check(dut->mem_is_store == 0, "Flush_Clears_StoreEn"); // 5. Flush Overrides Stall dut->flush_en = 0; dut->ex_pc = 0x80005000; dut->ex_reg_write_en = 1; - tick(dut); + tick(dut); check(dut->mem_pc == 0x80005000, "Pre_FlushStall_Setup"); dut->flush_en = 1; |
