Can i convert UVM_ERRORs to UVM_INFO or UVM_WARNING based on id?

Hi,

I want to convert all UVM_ERROR s to UVM_INFO or UVM_WARNING s depending on some id.Can i do this.
Please help me in this.
Thanks in advance…

Sai subhash

From the html Reference Guide (which I highly recommend):

set_report_severity_override

function void set_report_severity_override( uvm_severity cur_severity, 
uvm_severity new_severity )

set_report_severity_id_override

function void set_report_severity_id_override( uvm_severity cur_severity,
string id,
uvm_severity new_severity )

These methods provide the ability to upgrade or downgrade a message in terms of severity given severity and id. An upgrade or downgrade for a specific id takes precedence over an upgrade or downgrade associated with a severity.

In reply to tfitz:

Thank you for your reply.

You can make use of the uvm_callback ‘uvm_report_catcher’ and fine tune the logic as per your requirement.

The methods get_severity() and get_id() will be of more useful.

In reply to Sivapriya:

No need for callbacks in this case, plus callbacks are very expensive.

How do you say that callbacks are expensive? Can you please briefly explain?

In reply to Sivapriya:

They are expensive in terms of run-time performance. The more callbacks you add to the list, the longer it takes at each callback point to scan through the list of callbacks to check if there is an appropriate callback for that point.

In reply to dave_59:

Ok. Got it. Thank you :)

In reply to Sivapriya:

My actual issue is UVM_ERROR’s are reported by the VIP,which have to be ignored.But what our regression script doing is ,it is grepping the word “ERROR” and ending the simulation.So that we want to make UVM_ERROR’s with specified ID as warnings.

Can i make them as warnings?
If possible in which block/file/class i have to call those functions?

Please help me in this regard.

Thanks,
Subhash

In reply to subhash@ineda:

That’s what set_report_severity_id_override() is for.

function void set_report_severity_id_override( uvm_severity cur_severity,
                                               string id,
                                               uvm_severity new_severity )

It’s probably easiest to just set this in your test. It really doesn’t matter which component you call it in because the component will just delegate to the report handler and, unless you choose to create your own (which we don’t recommend), all components will use the same report handler.
Good luck.