McPall Posted October 17, 2012 Report Share Posted October 17, 2012 Is there a way to get all opposing phase objections ? (So if a test doesn't end I could invoke this function from ucli to get the opposing objections) I have tried running with +UVM_PHASE_TRACE but it's not exactly what I'm looking for. Quote Link to comment Share on other sites More sharing options...
uwes Posted October 18, 2012 Report Share Posted October 18, 2012 hi, yes you can do that. you need to iterate over all domains, all phase-nodes, then get the objection object of that phase node and then finally you can invoke <objection>.display_objections() to print the info. if you use a recent IUS you can use the tcl command "uvm_objection" to do that. /uwe Quote Link to comment Share on other sites More sharing options...
ifpk454 Posted January 4, 2013 Report Share Posted January 4, 2013 hi, yes you can do that. you need to iterate over all domains, all phase-nodes, then get the objection object of that phase node and then finally you can invoke <objection>.display_objections() to print the info. if you use a recent IUS you can use the tcl command "uvm_objection" to do that. /uwe How do you get a handle to a container of all the domains? Quote Link to comment Share on other sites More sharing options...
ajeetha.cvc Posted January 4, 2013 Report Share Posted January 4, 2013 Hello McPall, Inside your test add the following piece of "debug code": task apb_test_1::dbg_eot(uvm_phase phase); forever begin : fe #100; phase.phase_done.display_objections(); end : fe endtask : dbg_eot And fork off this task from main_phase. In Questa on a sample hang scenario I get: # The total objection count is 1 # --------------------------------------------------------- # Source Total # Count Count Object # --------------------------------------------------------- # 0 1 uvm_top # 0 1 uvm_test_top # 0 1 env_0 # 0 1 agent0 # 1 1 monitor # --------------------------------------------------------- HTH Ajeetha, CVC www.cvcblr.com/blog Quote Link to comment Share on other sites More sharing options...
uwes Posted January 7, 2013 Report Share Posted January 7, 2013 hi, the simple >task apb_test_1::dbg_eot(uvm_phase phase); >forever begin : fe >#100; >phase.phase_done.display_objections(); >end : fe >endtask : dbg_eot doesnt really help since "phase" might not be the active phase anymore. i did use the following solution which gives you all pending objections in all domains/phases (despite of the phase we are in) and the set of phases. /uwe 692 uvm_domain domains[string]; 693 uvm_phase phases[$]; 694 uvm_domain::get_domains(domains); 695 foreach (domains) begin 696 domains.m_get_transitive_children(phases); 697 phases=phases.find(item) with (item.get_phase_type()==UVM_PHASE_NODE && item.get_domain()==domains); 698 phases=cdns_array_utils#(uvm_phase)::unique_(phases); 699 700 foreach(phases[j]) begin 701 uvm_objection o; 702 o = phases[j].get_objection(); 703 if(!(doFilter==1 && o.get_objection_total()==0)) begin 704 $display($sformatf("objections to uvm_objection \"%s\"",o.get_full_name())); 705 o.display_objections(, 1); 706 end 707 end 708 end 709 end Quote Link to comment Share on other sites More sharing options...
Gunther Posted January 7, 2013 Report Share Posted January 7, 2013 Hi, I just came across this. I've never used it but it looks like this might provide the answer: function void get_objectors( ref uvm_object list[$] ) Returns the current list of objecting objects (objects that raised an objection but have not dropped it). You should then be able to run display_objection() on each element in the list. Cheers Gunther Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.