From ad857a05178926e3047867d4853fa2978e366ed6 Mon Sep 17 00:00:00 2001 From: Tobias Platen Date: Tue, 14 Dec 2021 16:56:28 +0100 Subject: [PATCH] fix test_loadstore1_ifetch_multi() in test_loadstore1.py --- src/soc/experiment/test/test_loadstore1.py | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/soc/experiment/test/test_loadstore1.py b/src/soc/experiment/test/test_loadstore1.py index 2a9dc2b5..f753dcd7 100644 --- a/src/soc/experiment/test/test_loadstore1.py +++ b/src/soc/experiment/test/test_loadstore1.py @@ -210,21 +210,23 @@ def _test_loadstore1_ifetch_multi(dut, mem): for addr in virt_addrs: yield from debug(dut, "virt_addr "+hex(addr)) - timeout = 0 - #TODO: use fetch interface here ################################### - yield i_in.req.eq(1) - yield i_in.nia.eq(addr) + yield i_in.priv_mode.eq(0) + yield i_in.virt_mode.eq(1) + yield i_in.req.eq(0) + yield i_in.stop_mark.eq(0) + + yield icache.a_i_valid.eq(1) + yield icache.a_pc_i.eq(addr) yield valid = yield i_out.valid failed = yield i_out.fetch_failed - while not valid and not failed and timeout < 100: + while not valid and not failed: yield valid = yield i_out.valid failed = yield i_out.fetch_failed - timeout = timeout + 1 - yield i_in.req.eq(0) + yield icache.a_i_valid.eq(0) ################################### print("TEST_MULTI: failed=",failed) # this is reported wrong -- 2.30.2