Hello,
I am trying to run a regression test that runs 7 tests using a seed from 0-6. A couple of the tests generate OVM_ERROR, which in turn seems to generate OVM_FATAL, which then proceeds to kick me out of the test before it is finished. I get the following message:
** Report counts by severity
OVM_INFO : 1
OVM_WARNING : 0
OVM_ERROR : 6
OVM_FATAL : 1
** Report counts by id
[Connection Error ] 6
[ovm ] 1
[ovm_stimulus ] 1
** Note: $finish : …/…/…/ovm/src//base/ovm_report_object.svh(145)
Time: 0 ns Iteration: 14 Instance: /ovm_pkg::ovm_report_object::die
I didn’t have this “problem” with AVM, but it’s my understanding with OVM that pre_run() checks the error count, and if it is > 0 the simulation (or elaboration) terminates. Nifty, but unwanted in this instance. There must be a way to turn this default behavior off. How would I do it? I’m using ovm_report_error in a function that tests for mismatches. Do I change the default behavior in this function, and if so, how?
Kind Regards,
Diane
You need to turn of the error counting with
set_report_severity_action(OVM_ERROR,(OVM_DISPLAY|OVM_LOG));
The default action for ovm_report_error is (OVM_DISPLAY|OVM_LOG|OVM_COUNT).
Dave Rich
Hi Dave,
I tried that, and for some reason it didn’t work… maybe I’m not doing it correctly? Here’s were I tried to override the setting:
assert (!test_mismatch) else begin
$sformat(s,“Test failed due to mismatches (%0d) of (%0d) matches at time %0t”,test_mismatch, test_match, $time);
$error(s);
set_report_severity_action(OVM_ERROR,(OVM_DISPLAY|OVM_LOG));
ovm_report_error(m_name,s,__FILE__,LINE);
end
I know we’re on the right track… any other suggestions?
Regards,
Diane
I think it was Dave_59 that helped me out earlier with this same issue. You are using the ovm_report_* methods in a module. I tried a couple things but ended up using a
class module_report_handler extends ovm_component;
`ovm_component_utils(module_report_handler)
function new (string name="module_report_handler", ovm_component parent=null);
super.new(name, parent);
endfunction
endclass
Then in the module, instantiate the report_handler.
module_report_handler rh=new("rh");
Then when you want to use the a the ovm_report, it’s just
rh.ovm_report_* ...
For me this fixed the issue you are having.
Steve
I have this problem the other way round.
[1]
set_report_severity_action_hier (OVM_FATAL, OVM_DISPLAY | OVM_EXIT);
[2]
if (get_report_verbosity_level() == 0) begin
ovm_report_fatal("env","verbositiy is OVM_NONE!");
end
[3]
log.ovm_report_fatal("env","printing something!");
If I set the verbosity to OVM_NONE, it terminates the test when Part [2] is reached. This is what it should do. But it should also end the test at Part[3], when I change ovm_report_fatal to ovm_report_info at Part[2]. But then it just prints:
OVM_FATAL @ 15000: env [env] printing something!
Can anybody please tell me why this happens?
What’s the reason for OVM not stopping when ovm_report_fatal is called, please?
Action is set to:
set_report_severity_action_hier (OVM_FATAL, OVM_DISPLAY | OVM_EXIT);
I would really appreciate an answer 
Hi Diane,
there are 2 ways to prevent from halting the simulation because of error messages.
- As Dave suggested, disable the counting of error messages.
- Increase the limit of error count. For this you can use report_object’s
set_report_max_quit_count() function. The simulation will not end until it encounters the
number of errors to be equal to as given max_quit_count. By increasing this count, it
enables you to report more errors without disabling the simulation.
Hi Blueschm,
Changing the verbosity to OVM_NONE does not mean it will call OVM_FATAL. Severity and verbosity are all together 2 different concepts. In stage2, you convert the severity from fatal to info. Hence simulation does not stop and it goes till stage3.
But then it should stop when it reaches state 3. But it does not. It just prints the message in ovm_report_fatal and continues simulation.
I run this with ovm_verbosity = OVM_NONE.
First time the code looks like this:
[1]
set_report_severity_action_hier (OVM_FATAL, OVM_DISPLAY | OVM_EXIT);
[2]
if (get_report_verbosity_level() == 0) begin ovm_report_**fatal**("env","verbositiy is OVM_NONE!");end
[3]
log.ovm_report_fatal("env","printing something!");
It stops when state 2 is reached.
Second time it looks like this: (ovm_verbosity still set to OVM_NONE)
[1]
set_report_severity_action_hier (OVM_FATAL, OVM_DISPLAY | OVM_EXIT);
[2]
if (get_report_verbosity_level() == 0) begin ovm_report_**info**("env","verbositiy is OVM_NONE!");end
[3]
log.ovm_report_fatal("env","printing something!");
I know that the message in state 2 is not shown in this example. But I expected the simulation to stop in state 3. It does not stop.
Is it possible that the simulator is not able to work with this? I use VCS.
hey bluemschn,
That’s interesting…!!
OK. From what i see is that your stage3’s printing message is coming from another component “log”. In that “log” class, are you de-associating OVM_EXIT action with OVM_FATAL severity?
If not, I would like to see the code of “log” class.
Ashish
Maybe the log class was the reason.
I have another example that is not using this class and things work fine there.
Seems like there was something wrong with this class. Thank you for the hint.