uvm_config_db#(uvm_object_wrapper)::set(this, "env.v_sqr.main_phase", "default_sequence", virtual_sequence::type_id::get()); 的方法set default_sequence,还可以用与1370行对应的代码的另一种方法(直接set virtual_sequence的实例): virtual_sequence myseq = new("myseq"); uvm_config_db #(...
set_config_int与uvm_config_db#(int) ::set是完全等价的 使用set_config_int来代替uvm_config_db#(int) ::set的代码 functionvoid my_case0::build_phase(uvm_phase phase); … uvm_config_db#(uvm_object_wrapper)::set(this,"env.i_agt.sqr.main_phase","default_sequence", case0_sequence::type...
uvm_config_db#(uvm_object_wrapper)::set(this,"env.i_agt.sqr.main_phase","default_sequence",case0_sequence::type_id::get()); 还可以先实例化要启动的sequence,之后再通过default_sequence启动: functionvoidmy_case0::build_phase(uvm_phasephase);case0_sequencecseq;super.build_phase(phase);cseq=...
2 除了在my_env 的build_phase中设置default_sequence外,还可以在其他地方设置,比如top_tb: 3.config_db通常是成对出现的。设置virtual interface 要get。但sequencer 不需要get,UVM早已安排好。 4.之前启动sequence前后,分别raise 和 drop objection,现在用default_sequence 如何实现呢? 1)在uvm_sequence 这个基类...
UVM中sequence的启动分为显示启动和隐式启动两种方式。 显式启动(直接启动)——调用start()方法启动。 隐式启动 ——使用uvm_config_db机制配置default_sequence启动。 //sequence的显式启动//该方法提起和落下objection,通过phase.raise_objection(this)/phase.drop_objection(this)my_sequence seq = my_se...
uvm_config_db#(int)::set(null,"uvm_test_top.fifo_env.wr_agt.drv","wr_stop_sig",wr_stop_sig) 1. uvm_config_db#(int)::get(this,"","wr_stop_sig",wr_stop_sig); 1. 因为是在top中set,第一个参数为null,会自动替换为uvm_root::get(),即uvm_top。
raise_objection和drop_objection往往伴随sequence的启动; 第二种:default_sequence 采用default_sequence启动,实际上还是调用了start任务, 代码语言:javascript 复制 uvm_config_db#(uvm_object_wrapper)::set(this,"env.fish_agt.sqr.main_phase","default_sequence",case0_sequence::type_id::get());) ...
第二种:default_sequence 采用default_sequence启动,实际上还是调用了start任务, uvm_config_db#(uvm_object_wrapper)::set(this,"env.fish_agt.sqr.main_phase","default_sequence",case0_sequence::type_id::get()); ) 或者先例化,再采用default_sequence启动: ...
uvm_config_db#(uvm_object_wrapper)::set(this,"env.i_agt.sqr.main_phase","default_sequence",case0_sequence::type_id::get()); (3)使用uvm_config_db#(uvm_sequence_base)配置default_sequence functionvoidmy_case0::build_phase(uvm_phase phase);case0_sequence cseq;super.build_phase(phase);...
uvm_config_db#(uvm_object_wrapper)::set(this, "vir_sqr.main_phase", "default_sequence", my_sequence::type_id::get() ); endfunction : build_phase 在env的connect_phase,连接ifu_sqr,lsu_sqr的实例。代码如下所示: function void my_env::connect_phase(uvm_pkg::uvm_phase phase); ...