ankurraj Posted March 10, 2022 Report Share Posted March 10, 2022 I want to use the get_reg_by_name() API to get the registers instantiated inside a register file class extended from uvm_reg_file. This register file class is instantiated inside a uvm_reg_block class type. I am getting compilation error when trying to do as follows: <reg block>.<reg file>.get_reg_by_name("<reg name>") Please let me know how can I use the get_reg_by_name() function in this case? Quote Link to comment Share on other sites More sharing options...
Rohith D Posted April 12, 2022 Report Share Posted April 12, 2022 UVM reg file is a grouping of similar registers. Internally the registers would have been configured into the parent reg map. Meaning the target register should be accessible through the parent reg map of reg file. You could: <reg_block>.get_registers(regs); Loop through regs to find the target register. 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.