I am trying to understand how would the following assertion behave give the below scenario:
req signal asserts on the 1st posedge of clock and stays high for 2 clock cycles and the gnt signal asserts for only 5th posedge of clock and then desserts on the 6th clock cycle. For the next 32 cycles gnt does not asserts. Will the following assertion fail?
In reply to fenil_shah:
I strongly suggest that you read my papers below as they address the concept of attempt and threads.
Your “assert (@(posedge clock) req ##[4:32] gnt )” is incorrect; You meant a concurrent assertion, like assert property (@(posedge clock) req ##[4:32] gnt ); For this, you can say:
At every clocking event you have an attempt, if req==0 the assertion fails
If for every successful attempt (req==1) gnt==1 4 to 32 cycles later, then the assertion passes, else it fails.
Every attempt is separate and independent from other attempts, and each attempt has a life of its own. You can think of it as blowing soap bubbles; at every clocking event you emanate a new bubble, and that bubble has a life of its own.
You need to understand the concept of vacuity, and threads; my papers explain those concepts.
As per your paper the above assertion fails, right?
According the scenario I stated,
There were will be 2 threads spawned when the req stays high for 2 cycles. And the 1st thread will end when the gnt is first asserted on the 5th clock edge. And the thread 2 will cause the failure as the gnt never asserts.
In reply to ben@SystemVerilog.us:
This is exactly what I was suspecting. The expectation is to get gnt signal each time the req signal is high. Can you suggest me what updates will required to catch the issue in the following scenario: