Hi,
In several places around rtl I insert this in initial block:
if (! ovm_pkg::ovm_root::get().get_config_object("name", obj, 0)) begin
obj = new("name");
ovm_pkg::ovm_root::get().set_config_object(ovm_pkg::ovm_root::get().get_full_name(), "name", obj, 0);
end
....
using obj
....
In the first initial that happened it get into the if and do set_config_object.
I the second initial it jump over the if and get the obj by get_config_object that inside the if condition.
For some reason the third initial get into the if (get_config_object return 0) and do again set_config_object.
Do you have any idea why it could happened? Can it be that I have 2 ovm_root?
Thanks.