In reply to ben@SystemVerilog.us:
You sequence declaration does not look correct. You need to explain your requirements.
This is my guess at what you need
sequence response_queue(sig);
int num_ahead;
@(posedge clk) ($rose(sig), num_ahead=data) ##0
(num_ahead > 0 && transaction_advance, num_ahead--)[*1:$] ##1
num_ahead <= 0);
endsequence
(num_ahead == 0) [->1] cause way too many threads.
I strongly urge you to read my papers
- Understanding the SVA Engine,
Verification Horizons - July 2020 | Verification Academy - Reflections on Users’ Experiences with SVA
Reflections on Users’ Experiences with SVA | Verification Horizons - March 2022 | Verification Academy