When I start simulation, I can see signals and ports in the objects window for what I have selected in the Sim window. Besides this, I can see processes for the same thing in the processes window. However, generics are nowhere to be seen. How do I see, what generics were passed to an entity when it was instantiated during simulation besides looking at the code?
Asked
Active
Viewed 2,400 times
1
-
I believe generics are compile time variables, therefore you don't see them. – lucas92 Feb 12 '16 at 00:17
-
That means, there is no way to see them at all????? – quantum231 Feb 12 '16 at 00:31
-
I'm a bit rusty on my VHDL, can't you convert them to an integer or signal you can see? Why would you want to see it if its constant? – Voltage Spike Feb 12 '16 at 00:40
2 Answers
4
Generics and constant values can be seen in the objects window of QuestaSim/ModelSim.
You could also drag them into the waveform, but they wont change ...

Paebbels
- 3,897
- 2
- 18
- 43
-
I right-clicked on the object in SIM and then clicked on add wave. It did not add the generics. Then I looked at the non-port items in the objects window and the generics were not there. After reading what you posted, I did the simulation again, if I click on the object in Sim window and then search in the objects, I was able to find the generic as a port thing i.e diamond with arrow. – quantum231 Feb 14 '16 at 16:25
0
Generics are not always available for inspection at simulation time. During the optimization stage (prior to compilation) the generics (and other objects) may be removed from the simulation database to make the simulation faster. In order to make sure that the generics are preserved you can explicitly add "+acc" to the vopt command (see the vopt command options in the Questasim Command User Manual).
Once the generics have been preserved during the compilation (and optimization) stage, they will be available for viewing in the Objects window during simulation.

Sorin
- 1