X-propagation in RTL simulation
Haapakumpu, Tuukka (2022)
Haapakumpu, Tuukka
2022
Sähkötekniikan DI-ohjelma - Master's Programme in Electrical Engineering
Informaatioteknologian ja viestinnän tiedekunta - Faculty of Information Technology and Communication Sciences
This publication is copyrighted. You may download, display and print it for Your own personal use. Commercial use is prohibited.
Hyväksymispäivämäärä
2022-12-02
Julkaisun pysyvä osoite on
https://urn.fi/URN:NBN:fi:tuni-202211228541
https://urn.fi/URN:NBN:fi:tuni-202211228541
Tiivistelmä
RTL simulations are a major part of hardware development and verification. RTL simulation is the most commonly used method of verifying the correct operation of hardware designs. Verification is often run parallel to the hardware design and verification is a major part of SoC projects even before any physical releases.
RTL simulators depict and read logical values usually with ’1’ and ’0’. In some situations the simulators cannot always tell what value is going into a component, then it will assign it an ’X’. Problems arise from the fact that there is no state ’X’ for a signal in physical devices. If the simulator just assigns a ’1’ or a ’0’ to an X-value there is a significant chance of it being wrong which will cause errors later down the line.
X-propagation in a RTL simulator is a way of making the X-value run through the design to see where it ends up. This is done while configuring the simulator to make the ’X’ end up in the least amount of places while trying to cover all places where there might be ambiguity. Simulations can be run in an X-pessimistic or X-optimistic way, where a pessimistic simulation will produce more X-values.
In this thesis simulator A and its X-propagation plugins were tested. The aim was to assess the simulators ability to catch X-related errors and find any issues or restrictions that would hinder its use. The testing was done by running basic tests to see the finer details of the X-propagation plugin of each simulator and a larger test done on a design provided by the company. The basic tests were six different basic design simulations: an if-else statement, a case statement, a random number generator, a state machine, a RAM circuit and a shift register. The environment used in the simulations was provided by the company which restricted the choice of simulators.
The basic tests were run with and without X-propagation modules enabled on simulator A. The basic simulations went mostly as expected with a few surprises. Overall the simulator performed mostly as expected and without issues.
The larger simulations were run using simulator A. The X-value tracing function of simulator A was used to find sources of X-values and the testcases were run first without any X-propagation enabled and then with the X-propagation plugin enabled in relevant modes. Unfortunately there was no big difference in simulation results between modes.
In the simulator analysis some differences were found between simulation and the user guide. A notable bug was found in simulator A which the simulation vendor was informed about. While testing it was found that the simulator could be used in X-propagation simulations especially with larger designs.
RTL simulators depict and read logical values usually with ’1’ and ’0’. In some situations the simulators cannot always tell what value is going into a component, then it will assign it an ’X’. Problems arise from the fact that there is no state ’X’ for a signal in physical devices. If the simulator just assigns a ’1’ or a ’0’ to an X-value there is a significant chance of it being wrong which will cause errors later down the line.
X-propagation in a RTL simulator is a way of making the X-value run through the design to see where it ends up. This is done while configuring the simulator to make the ’X’ end up in the least amount of places while trying to cover all places where there might be ambiguity. Simulations can be run in an X-pessimistic or X-optimistic way, where a pessimistic simulation will produce more X-values.
In this thesis simulator A and its X-propagation plugins were tested. The aim was to assess the simulators ability to catch X-related errors and find any issues or restrictions that would hinder its use. The testing was done by running basic tests to see the finer details of the X-propagation plugin of each simulator and a larger test done on a design provided by the company. The basic tests were six different basic design simulations: an if-else statement, a case statement, a random number generator, a state machine, a RAM circuit and a shift register. The environment used in the simulations was provided by the company which restricted the choice of simulators.
The basic tests were run with and without X-propagation modules enabled on simulator A. The basic simulations went mostly as expected with a few surprises. Overall the simulator performed mostly as expected and without issues.
The larger simulations were run using simulator A. The X-value tracing function of simulator A was used to find sources of X-values and the testcases were run first without any X-propagation enabled and then with the X-propagation plugin enabled in relevant modes. Unfortunately there was no big difference in simulation results between modes.
In the simulator analysis some differences were found between simulation and the user guide. A notable bug was found in simulator A which the simulation vendor was informed about. While testing it was found that the simulator could be used in X-propagation simulations especially with larger designs.