Any use case where we should be creating a new transaction(using factory create) for every iteration in a sequence?

Hi,

Can someone provide me an example where we should be creating a new transaction(using factory create) for every iteration in a sequence?

I know that using the same object helps in terms of performance and since we will be randomizing the transaction for every iteration of a sequence I don’t see the need to create a new transaction for every iteration.

Thanks

In reply to sj1992:

As long as one transaction completes before you need to start another one, then you can get away with just creating a single transaction/seq_item and reusing it on each pass through your loop. Just be aware that if you need to preserve the contents of the transaction in a monitor or scoreboard, then you must follow the MCOW rule (Guideline 10.1).

In reply to tfitz:

Hi Tfitz,

Thanks for the info. As far as I know, the driver drives the I/F pins and calls item_done() which indicates the transaction is complete and the sequence then iterates through the loop and creates new seq item. In this case, the next transaction/seq_item is created only after the previous transaction/seq_item completes. Is there any example that you can provide in which a new transaction starts before the completion of the previous transaction?

Thanks.