fvm.toolchains.questa module
Warning
Callables that are not documented in the Public API are not intented to be directly used and thus may change between minor versions.
Questa toolchain for FVM
- fvm.toolchains.questa.compile_systemverilog(path, framework, lib, f, psl_compile)[source]
Compile SystemVerilog sources for a given library
- fvm.toolchains.questa.compile_verilog(path, framework, lib, f, psl_compile)[source]
Compile Verilog sources for a given library
- fvm.toolchains.questa.compile_vhdl(path, framework, lib, f, psl_compile)[source]
Compile VHDL sources for a given library
- fvm.toolchains.questa.create_f_file(filename, sources)[source]
Create a .f file with the list of sources
- Parameters:
filename (str) – the name of the .f file to create
sources (list of str) – the list of sources to include in the .f file
- fvm.toolchains.questa.define_steps(framework, steps)[source]
Define the steps available in the Questa toolchain
This function is called by the framework to register the steps available in this toolchain. The steps are registered in the order they are defined here, so this also defines the order of execution
Each step is defined by a setup function and a run function. The setup function generates the script to run the tool, while the run function actually runs the tool and parses the results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
steps (fvm.steps.Steps) – the Steps object where the steps will be registered
- fvm.toolchains.questa.formal_initialize_reset(framework, reset, active_high=True, cycles=1)[source]
Initialize reset for formal steps.
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
reset (str) – the name of the reset signal
active_high (bool) – True if the reset is active high, False if it is active low. Defaults to True.
cycles (int) – number of cycles to keep the reset active at the start of the formal analysis
- fvm.toolchains.questa.gen_clock_config(framework, filename, path)[source]
Generate clock configuration in the given script
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
filename (str) – the name of the script to append the configuration to
path (str) – the path where the script is located
- fvm.toolchains.questa.gen_clock_domain_config(framework, filename, path)[source]
Generate clock domain configuration in the given script
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
filename (str) – the name of the script to append the configuration to
path (str) – the path where the script is located
- fvm.toolchains.questa.gen_reset_config(framework, filename, path)[source]
Generate reset configuration in the given script
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
filename (str) – the name of the script to append the configuration to
path (str) – the path where the script is located
- fvm.toolchains.questa.gen_reset_domain_config(framework, filename, path)[source]
Generate reset domain configuration in the given script
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
filename (str) – the name of the script to append the configuration to
path (str) – the path where the script is located
- fvm.toolchains.questa.gencompilescript(framework, filename, path, psl_compile=False)[source]
Generate script to compile design sources
This is used as header for the other scripts, since we need to have a compiled netlist in order to do anything
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
filename (str) – the name of the script to create
path (str) – the path where to create the script
- fvm.toolchains.questa.generics_to_args(generics)[source]
Converts a dict with generic:value pairs to the argument we have to pass to the tools
- Parameters:
generics (dict[str, str]) – A dictionary with generic names as keys and their values as values
- Returns:
A string with the generics formatted as tool arguments
- Return type:
str
- fvm.toolchains.questa.get_linecheck_clocks()[source]
Common patterns for linecheck in the Questa clocks step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_common()[source]
Common patterns for linecheck in all Questa steps
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_friendliness()[source]
Common patterns for linecheck in the Questa friendliness step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_lint()[source]
Common patterns for linecheck in the Questa lint step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_prove()[source]
Common patterns for linecheck in the Questa prove step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_prove_formalcover()[source]
Common patterns for linecheck in the Questa prove.formalcover step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_prove_simcover()[source]
Common patterns for linecheck in the Questa prove.simcover step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_reachability()[source]
Common patterns for linecheck in the Questa reachability step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_resets()[source]
Common patterns for linecheck in the Questa resets step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_rulecheck()[source]
Common patterns for linecheck in the Questa rulecheck step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.get_linecheck_xverify()[source]
Common patterns for linecheck in the Questa xverify step
- Returns:
A dictionary containing linecheck patterns
- Return type:
dict[str, list[str]]
- fvm.toolchains.questa.parse_reachability_summary(path, goal=90.0)[source]
Helper function to deduplicate code in reachability parsing
- Parameters:
path (str) – the path of the reports
goal (int or float) – coverage goal
- Returns:
result dict of the parsing
- Return type:
dict
- fvm.toolchains.questa.run_clocks(framework, path)[source]
Run the clocks step and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_friendliness(framework, path)[source]
Run AutoCheck to generate a friendliness report and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the friendliness directory
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_lint(framework, path)[source]
Run Lint and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the lint directory
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_prove(framework, path)[source]
Run the prove step and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_prove_formalcover(framework, path)[source]
Run the prove.formalcover step and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_prove_simcover(framework, path)[source]
Run the prove.simcover step and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_qverify_step(framework, design, step)[source]
Run a specific step with the Questa formal toolchain.
A single function can be reused for multiple steps since the tools share the same interface through the qverify command line tool/wrapper
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
design (str) – the name of the design to analyze
step (str) – the name of the step to run
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err)
- Return type:
tuple[str, str, int, int]
- fvm.toolchains.questa.run_reachability(framework, path)[source]
Run the reachability step and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_resets(framework, path)[source]
Run the resets step and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_rulecheck(framework, path)[source]
Run the rulecheck step and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.run_xverify(framework, path)[source]
Run the xverify step and parse results
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- Returns:
A tuple (cmd_stdout, cmd_stderr, stdout_err, stderr_err, status)
- Return type:
tuple[str, str, int, int, str]
- fvm.toolchains.questa.set_coverage_goal(step, goal)[source]
Set the coverage goal for a specific step
- Parameters:
step (str) – the step to set the coverage goal for
goal (int or float) – Coverage goal value, must be between 0 and 100
- fvm.toolchains.questa.set_timeout(framework, step, timeout)[source]
Set the timeout for a specific step
The timeout should be provided as a string combining a number and a unit:
sfor seconds (e.g., “1s”)mfor minutes (e.g., “10m”)hfor hours (e.g., “1h”)dfor days (e.g., “2d”)
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
step (str) – the step to set the timeout for. One of “rulecheck”, “xverify”, “reachability”, “prove”
timeout (str) – Timeout value as a string with a number and unit.
- fvm.toolchains.questa.setup_clocks(framework, path)[source]
Generate script to run Clock Domain Crossing
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_friendliness(framework, path)[source]
Generate script to compile AutoCheck, which also generates a report we analyze to determine the design’s formal-friendliness
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_lint(framework, path)[source]
Generate script to run Lint
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_prove(framework, path)[source]
Generate script to run PropCheck
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_prove_formalcover(framework, path)[source]
Generate script to run formal coverage after prove
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_prove_simcover(framework, path)[source]
Modify the replay.vsim.do files to dump UCDB files and waveforms
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_reachability(framework, path)[source]
Generate a script to run CoverCheck
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_resets(framework, path)[source]
Generate script to run Reset Domain Crossing
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_rulecheck(framework, path)[source]
Generate script to run AutoCheck
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script
- fvm.toolchains.questa.setup_xverify(framework, path)[source]
Generate script to run X-Check
- Parameters:
framework (fvm.framework.FvmFramework) – the FvmFramework object
path (str) – the path where to create the script