From 4fe334c57ea5549bbbfa1b82142ba97012e304f5 Mon Sep 17 00:00:00 2001 From: Alejandro Soto Date: Sun, 25 Sep 2022 15:04:41 -0600 Subject: Fetch NOP on prefetch flush --- rtl/core/fetch/prefetch.sv | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'rtl') diff --git a/rtl/core/fetch/prefetch.sv b/rtl/core/fetch/prefetch.sv index 3d0eb88..255bd4d 100644 --- a/rtl/core/fetch/prefetch.sv +++ b/rtl/core/fetch/prefetch.sv @@ -20,7 +20,7 @@ module core_prefetch logic[31:0] prefetch[SIZE]; logic[ORDER - 1:0] valid; - assign insn = prefetch[0]; + assign insn = ~flush ? prefetch[0] : `NOP; assign next_pc = ~stall & |valid ? insn_pc + 1 : insn_pc; always_comb -- cgit v1.2.3