Jump to content

Passing sequence_items from v-sequence to sub-sequence?


Recommended Posts

Is there a way for a virtual sequence to pass a sequence_item (that it has already created) to a sub-sequence, say for instance to an agent sequence, without using a TLM?

 

I really would like to avoid adding a TLM to the agents sequencer if I can avoid it.

The sub-sequence would be invoked from the v-sequence by calling start().

The sequence_item is a potentially largish data structure so using the `uvm_do_on_with macro is a bit unwieldy.

 

I think I see a sneeky way to do it by using the parents mid_do() method, but haven't tried it yet and wondering if there's a more direct way I'm not seeing.

 

Thanks in advance. ;)

Link to comment
Share on other sites

Just use `uvm_create instead of `uvm_do. Create will create the sequence for you. Then you can assign the data structure--or anything else--to the sequence you've created. You can further randomize the sequence or perform any other manipulations you wish before calling `uvm_send on it.

 

For example:

my_seq_c my_seq;
`uvm_create(my_seq)
my_seq.data = my_big_ol_data_array;
`uvm_rand_send(my_seq)
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...