Where does get_and_drive come from?

315 views Asked by At

I found almost every driver that extends from uvm_driver has task get_and_drive like below. I checked the uvm source code and uvm_cookbook, but I didn't find get_and_drive. It seems it is not a uvm rule; it is more likely a convention. Who first used the task named get_and_drive(), and why do almost all people use the name get_and_drive in their driver?

task run_phase(uvm_phase phase);
     get_and_drive();
endtask : run_phase

task get_and_drive();
     forever begin
          seq_item_port.get_next_item(req);
          send_to_dut(req);
          seq_item_port.item_done();
     end
endtask : get_and_drive
1

There are 1 answers

0
Tudor Timi On BEST ANSWER

If you look in the example/integrated/ubus directory, in the ubus_master_driver you'll see a method that's called get_and_drive(). If you go back to OVM, you'll see that in XBUS example also defined the same method in the xbus_master_driver.

Since most people learn by example, I guess the convention just stuck. I think other methodology sites (like Verification Academy) also promote the same convention.