tudor.timi Posted March 13, 2015 Report Share Posted March 13, 2015 I'm trying to declare a memory like this: class some_mem extends uvm_mem; function new(string name = "some_mem"); super.new(name, 2 ** 24, 8, "RO"); endfunction endfunction Later on, I'm trying to add this memory to an address map that was created like this: default_map = create_map("some_map", 0, 4, UVM_NO_ENDIAN); By using the default value for the byte_addressing argument I want each address to represent a one byte location. The problem I'm seeing is that the uvm_reg_map_info associated with this memory shows an end address of 32'03ff_ffff and a stride of 4, instead of 32'00ff_ffff and a stride of 1. I've narrowed it down to the function uvm_reg_map::get_physical_address(...), at line 1378 of uvm_reg_map.svh: int multiplier = m_byte_addressing ? bus_width : 1; I guess this should be the other way around: int multiplier = m_byte_addressing ? 1: bus_width; Even better would be to use: int multiplier = get_addr_unit_bytes(); David Black 1 Quote Link to comment Share on other sites More sharing options...
uwes Posted March 26, 2015 Report Share Posted March 26, 2015 http://eda.org/svdb/view.php?id=5258 Quote Link to comment Share on other sites More sharing options...
tudor.timi Posted March 27, 2015 Author Report Share Posted March 27, 2015 After looking at a bit more at the code, I think the branch for wide transfers (n_bytes > bus_width) is also broken. See my fork of the repo: https://github.com/tudortimi/freecellera-uvm/blob/bug_blitz__mantis_0005258/distrib/src/reg/uvm_reg_map.svh Quote Link to comment Share on other sites More sharing options...
sanjeevs Posted November 24, 2015 Report Share Posted November 24, 2015 We had the same problem. Our map was 512b wide. The memory was 16K x 8B. The address that got generated was multiple of 64B. Our fix is to create a map just for the memory with 8B width. Then added this to the original map as a submap. -sanjeev 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.