Creating a DRC Check - 2022.1 English

Vivado Design Suite User Guide: Using Tcl Scripting (UG894)

Document ID
UG894
Release Date
2022-06-08
Version
2022.1 English

Once the Tcl checker procedure is defined, you must now define the DRC as part of the DRC reporting system within the Vivado Design Suite.

First, you must register the new design rule using the create_drc_check command. This command requires you to provide a unique name for the user-defined rule check. This name that must match the name given to the violation created by the Tcl checker procedure. You will need to specify this unique name when adding the check to DRC rule decks or when running report_drc. In the dataWidthCheck Tcl checker procedure above, the create_drc_violation command uses the name RAMW-1. In addition, the create_drc_check command requires you to provide the procedure name of the Tcl checker procedure to be run when the rule is checked. In this case above, the Tcl checker procedure dataWidthCheck is provided as the -rule_body argument and must be loaded into the Vivado Design Suite prior to running the report_drc command.

create_drc_check -name {RAMW-1} -hiername {RAMB Checks} \
  -desc {Block RAM Data Width Check} -rule_body dataWidthCheck -severity Advisory

You can optionally group the DRC into a special category, provide a description of the rule for reporting purposes, and assign a severity.

You can define a message to add to the DRC report when violations are encountered. By default, the message created by the create_drc_violation command in the Tcl checker procedure is passed upward to the DRC object. In this case, any message defined by create_drc_violation is simply passed through to the DRC report.

The DRC object features the is_enabled property that can be set to TRUE or FALSE using the set_property command. When a new rule check is created, the is_enabled property is set to TRUE as a default. Set the is_enabled property to FALSE to disable the DRC from being used when report_drc is run.