Is there a way to disable the warnings from the uvm_reg_field.svh due to accessing a field not the whole register?
In reply to ahennawy:
It would help to know which warnings you are referring to. Any message with a unique ID can be disabled very easily. Other warnings might be because of how you configured the register.
In reply to dave_59:
Hi Dave,
the RAL warning was because we were calling the .write() on a uvm_reg_item which is not configured as individually accessible.
The main issue was that there were another environment using the same code and it is working without popping this warning.
I found that there is a compile directive “UVM_REG_NO_INDIVIDUAL_FIELD_ACCESS”. based on this macro the uvm_reg_field class handles the write operations.
When it is defined the accessing of the field is neglected and the uvm automatically masks and writes the whole parent register.
When it is not defined the uvm tries first to write the single field, and if it is not individually accessible it fires the warning then writes the whole register too.
I am not able to find any documentation for such UVM compile directives. so please let me know if there is one :).
please confirm my understanding. also, I want to know how a uvm warning message can be disabled as you mentioned.
Thanks in advance Dave :))
In reply to dave_59:
In reply to ahennawy:
It would help to know which warnings you are referring to. Any message with a unique ID can be disabled very easily. Other warnings might be because of how you configured the register.
Hi Dave,
could you please comment on the previous one? :D
In reply to ahennawy:
You cannot disable warnings/errors coming from a specific UVM library file. I believe you are expecting this.
But the UVM has a very powerful reproting mechanism which can be controlled. You can disable warnings/errors coming from a specific ID, ie. the first argument in the uvm_warning/error.
I’ve run into the same issue and the warning prints like this: UVM_WARNING /shorter_path /sv/src/reg/uvm_reg_field.svh(1724) @ 310330000000: reporter [RegModel] Individual field access not available for field 'm_ral.register.field. Accessing complete register instead.
I abbreviated the UVM file path and generalized the RAL naming scheme.
This happens when you configure the uvm_reg_field as not individually _accessible, but you call write or read on the uvm_reg_field itself.
The UVM_REG_NO_INDIVIDUAL_FIELD_ACCESS directive does filter out the messages, and it does seem to behave the same way (I haven’t looked through the implementation enough). As ahennawy mentioned, I can’t find documentation for this directive. Is this vendor specific behavior?
The alternative would be to add a report catcher, but using get_id() only is the wrong solution because that would catch all the RegModel warnings. Filtering on get_message() should work, but you would have to add a check every time you have a unique message.
Of course another option is to never call write() or read() on a uvm_reg_field if it is not individually accessible, but it is nice functionality to at least perform reads on the uvm_reg_field().
My main question is what is the vendor independent solution?