Using Randomized Analog Parameters to Improve Mixed Signal Verification Coverage
The level of interaction between the analog and digital components on todays mixed signal SoCs is vastly more complex than in the past. The interplay between these domains is so integral to the functionality of the IC that it is no longer adequate to simulate analog and digital subsystems separately in a divide and conquer approach. The two must be simulated together, utilizing an array of advanced mixed signal verification strategies to obtain the coverage required for first pass success.
One such strategy used at Intrinsix is to leverage the randomization techniques used in digital verification methodologies on the analog portion of the SoC. Similar strategies to those that have been effective in extending coverage in the digital domain can work just as well in the analog domain.
An example of this involves varying environmental and parametric conditions (e.g. temperature, voltage tolerance, analog input level) with random and constrained-random values during a simulation. Simulations whose results depend critically on one of these parameters, such as a temperature sensor, will achieve greater coverage if the relevant parameter can be varied in a randomized way.
Some maneuvering is required to implement this randomization. This is because parameters must be specified in the netlist, either explicitly in the parameter specifications section of a model, or in a file referenced by the netlist. This is problematic because the analog netlist is static, and not accessible from the testbench. As a consequence, standard randomization techniques used in digital verification cannot be used to generate randomized analog parameter values.
To illustrate this point, consider a digital behavioral model of a temperature sensor. In some circumstances it may be sufficient to run this model at a constant temperature, but better coverage can be achieved by varying the temperature during simulation with nominal, worst case, and/or randomized values. One method for doing this is to add a pseudo-port to the model that the testbench can drive with randomized values. In this manner, the randomization is controlled entirely by the testbench.
However, this technique is not suitable for analog device models whose port connections must reflect the actual circuit device - a requirement for simulations to correlate well with the physical system. Another technique is required.
The strategy we use is to place the randomized parameter values into a file. The file, referenced by the netlist, consists of a series of constrained random (time, value) pairs, reflecting the variation of temperature values over time. (See illustration 1.) This file is automatically generated by a script (e.g. Perl) prior to running the mixed signal simulation. Essentially, this script becomes part of the simulation build and setup process.
To guarantee reproducible simulation results, the seed used by the random number generator in the script should be the same seed used by the digital simulator, as specified on its command line. By synchronizing the seeds in this way, simulation results will be the same from one run to the next for a given seed. This is essential for obtaining consistent results for, say, a regression testing environment.
One benefit of this approach is that the time/value pairs in the file can be visible to the testbench. This is handy if you want to monitor circuit output values as a function of the randomized parameter value. Referring back to the temperature sensor example, it would be possible to obtain the temperature from the file, and verify that the sensor is in the correct state, given the temperature - all within the testbench.
The testbench doesn’t have direct access to the file, rather, it uses functions provided by the simulation language to obtain the current values of analog parameters of interest (with updates at regular intervals to keep the digital and analog values in sync).
The strategy outlined in the paragraphs above allows randomization techniques typically used in the digital domain to be applied to the analog portions of mixed signal simulations, resulting in better verification coverage, increased confidence in the final design, and a better chance of first pass success.