In reply to sreekar kokkonda:
Hi, I have a leaf-level block at a non-zero offset. The design has a very odd indirect-addressing method, so the normal RAL indirect_data_reg isn’t usable. So I created an instance of the indirect-addressable registers as a block at a super-high address, and am treating them like they are directly-accessible.
When a read/write comes in for the indirect-address register, the data field (which is the address for the indirect-address) is captured, and I use get_reg_by_offset() to get a pointer to the indirect-access register, using the indirect_map.
get_reg_by_offset() always returns null.
But when I get all registers from the indirect_map and print them out, however, I see that they exist and have correct offsets.
subblock.build() does the following:
- creates registers
- creates map
- does map.add_reg(…) for each register
- lock_model()
topblock.build() does the following:
U_subblock = subblock_type::type_id::create(“U_subblock”);
U_subblock.configure(this);
U_subblock.build();
lock_model();
Then at the environment:
reg_model = topblock_type::type_id::create(“reg_model”);
reg_model.build();
reg_model.reset();
reg_model.lock_model();
Any suggestions would be most appreciated.