[dv,test] Fix race condition to catch ecall

We already have a clocking block inside dut_if. This commit uses it
to avoid a race condition that happens when `instr_valid_i` goes high
while `ecall_insn_i` goes low.

Signed-off-by: Canberk Topal <ctopal@lowrisc.org>
This commit is contained in:
Canberk Topal 2022-07-22 14:39:14 +01:00 committed by Canberk Topal
parent d84cd116c2
commit a6c182e7be

View file

@ -185,7 +185,7 @@ class core_ibex_base_test extends uvm_test;
virtual task wait_for_test_done();
fork
begin
wait (dut_vif.ecall === 1'b1);
wait (dut_vif.dut_cb.ecall === 1'b1);
vseq.stop();
`uvm_info(`gfn, "ECALL instruction is detected, test done", UVM_LOW)
fork