一般不会有这种情况,如果要实现,则需要在monitor中得到driver的实例,然后调用task/function。
in monitor:
xxx_driver drv_handle;
$cast(drv_handle, uvm_top.find("*.drv"));
drv_handle.task();
uvm_top 为 uvm_root的唯一实例,参考:https://verificationacademy.com/verification-methodology-reference/uvm/docs_1.2/html/files/base/uvm_root-svh.html
https://blog.csdn.net/Holden_Liu/article/details/99183577
uvm_top.print_topology(); 打印出环境的例化结构。
uvm_top中也可以设置timeout时间,通过在base test中使用set_timeout(): uvm_top.set_timeout(500ns,1);方法的第一个参数是时间,第二个参数0表示不可以override,1表示可以被override。可以在继承tc中的build_phase中重新override掉。
uvm_top.find():通过实例名搜索返回句柄。