Leaf level sequencer's stop_sequences() is terminating virtual sequence which is running on virtual sequencer

In reply to kerulmodi:

Hi Kerul,

Following code is implemented inside leaf level sequencer’s run phase.

task run_phase (uvm_phase phase);
    forever
    begin
      wait (my_vif.reset == 0);// wait for reset to be asserted.
      stop_sequences();
      wait (my_vif.reset == 1);// wait for reset to be de-asserted
    end
  endtask : run_phase

Above logic can be easily taken care from test or virtual sequence.

Now coming to your question.

As per UVM reference manual,
stop_sequences method is exactly doing the thing for what it is meant for -

stop_sequences ::
Tells the sequencer to kill all sequences and child sequences currently operating on the
sequencer, and remove all requests, locks and responses that are currently queued.