此外,uvm_config_db提供的主要函数还有exists(...)函数,用于检查某个数据对象是否在库;wait_modified(...)函数,用于耗时等待某个数据对象的更新。所有定义在uvm_config_db中的方法都是静态方法,即可以直接通过类名来调用。 当我们要将某个变量、接口句柄或者其他数据对象存储到该数据库的时候,实际上config_db会将...
可以使用如下的方式为一个sequence传递参数:uvm_config_db#(int)::set(this, "env.i_agt.sqr.*", "count", 9); sequence中以如下的方式调用config_db::get函数:uvm_config_db#(int)::get(null, get_full_name(), "count", count 在sequence中设置参数 wait_modified的使用 scoreboard都是在build_phase...
staticfunctionbit get ( uvm_component cntxt,stringinst_name,stringfield_name,inoutT value);//Get virtual interface handle under name "apb_vif" into local virtual interface handle at m_env leveluvm_config_db #(virtual apb_if) :: get (this,"*","apb_vif", apb_if);//Get int variable ...
uvm_config_db不仅可以共享资源,也可以像uvm_event那样,用于事件的同步,可以通过wait_modified实现。 drv0_seq在get之前,case0_vseq中必须先set,否则wait_modified会一直阻塞。因为wait_modified中调用@waiter.trigger,trigger是event类型;在set的最后,->w.trigger会触发该event。平台中所有的等待事件都放在了 m_wait...
接下来,我们将讨论get函数。其工作原理相对简单,主要是在m_rsc数组中查找并返回对应的值。此外,exists和wait_modified函数负责处理m_rsc数组中键值对的存在性和状态判断,用于进一步的逻辑操作。为了更直观地理解uvm_config_db的set和get过程,我们参考了cluelogic中的图示。通过这些图示,我们能够清晰地...
blocked on26//<uvm_resource_base::wait_modified>. If the value to be written is27//the same as the value already present in the resource then the28//write is not done. That also means that the accessor record is not29//updated and the modified bit is not set.3031functionvoid write(...
48、用.章节介绍了 uvm_config_db 的 wait_modified task ,参数只有3 个,和 get 前三个一样。responsesequence sequencer driver 的参数有两个: req 类型和 rsp 类型,默认情况下 rsp 和 req 一样的类型。当 sequence 需要 driver 返回 response 的时候,就需要用到 rsp 了。sequence 中在 uvm_do macro 之...
uvm_config_db#(bit)::set(uvm_root::get(), "uvm_test_top.v_sqr.*", "first_start", 0); (3)一个sequence是在task phase中运行的,当其设置一个参数的时候,起事件往往是不固定的。针对这种不固定的设置参数的方式,UVM提供了wait_modified任务。当它检测当第三个参数的值被更新过后,它就返回,否则一...
// Internal lookup of config settings so they can be reused // The context has a pool that is keyed by the inst/field name.static uvm_pool#(string,uvm_resource#(T)) m_rsc[uvm_component];// Internal waiter list for wait_modified static local uvm_queue#(m_uvm_waiter) m_waiters[...
6.6在sequence中使用config_db *6.6.1在sequence中获取参数 *6.6.2在sequence中设置参数 *6.6.3wait_modified的使用 6.7response的使用 *6.7.1put_response与get_response 6.7.2response的数量问题 *6.7.3response handler与另类的response *6.7.4rsp与req类型不同 6.8sequence library 6.8.1随机选择sequence 6.8.2...