• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Functional Verification
  3. [Doubt when initializing memory in netlist file]

Stats

  • Locked Locked
  • Replies 1
  • Subscribers 65
  • Views 8691
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

[Doubt when initializing memory in netlist file]

felipe ferreira
felipe ferreira over 2 years ago

Hello, I have a problem with my verification process in which I couldn't find a solution to get around my problem.
I apologize, but I'm relatively new to this process.

In the study project I'm working on, I use a verilog testbench to perform my simulations with the xcelium simulator, for that, I make some hierarchical accesses of the instances contained in my submodules used in my testbench, for example:

In my "my_top_level", there is a kind of RAM, defined as:

 reg[31:0] RAM [0:100];

so i populate my ram with data via testbench doing:

module testbench;

 my_top_level my_top();
 reg [31:0] RAM_x [0:100];
 $readmemh("test.hex", RAM_x);
 for (i = 0; i < `L_RAM; i = i + 1)
   testbench.my_top.RAM[i] = RAM_x[i];

....

Worked well for my purpose. Also, I do this type of access to initialize some values to be able to run my simulation normally.

Example: testbench.my_top.processor.cycles = 0;

but when generating the netlist file there is something like:
  wire [31:0] \RAM[1] ;
  wire [31:0] \RAM[4] ;
  wire [31:0] \RAM[0] ;

Currently, I want to go ahead with a port-level simulation.
Because previously, I was making use of the non-synthesized "readmeh" instruction to be able to initialize my memory with my test instructions.

And I have no idea how to handle this kind of situation with the memory now unpacked. Would anyone have a direction on how to go about this? I'm very grateful!

  • Cancel
Parents
  • StephenH
    StephenH over 2 years ago

    Typically one would not synthesise the model of a RAM or ROM, so this situation would not occur. It's more usual for synthesis to instantiate a behavioural model of a hard RAM or ROM IP, thus you would continue to have a simple 2-D memory in the behavioural simulation model.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • StephenH
    StephenH over 2 years ago

    Typically one would not synthesise the model of a RAM or ROM, so this situation would not occur. It's more usual for synthesis to instantiate a behavioural model of a hard RAM or ROM IP, thus you would continue to have a simple 2-D memory in the behavioural simulation model.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information