synth_design is a Tcl command used to run synthesis on a HDL design using Vivado Synthesis.
This Tcl command is used both in project flow mode via the TCL console, and in non-project flow mode.
In project flow mode, launch_runs synth_1 and this internally calls the command synth_design.
The Tcl command set_property can be used to set any synthesis properties.
This answer record describes the various optional synth_design synthesis switch options.
Description of Switches:
-name <design_name>: [Optional]
This switch is used to open the design after synthesis completion.
Example syntax: synth_design -name synth_1 (Synthesized design with name is opened after synthesis)
-part <xilinx_device>: [Optional]
This switch is used to specify the targeted Xilinx device for the design to be synthesized. If the part is not specified, the default part assigned to the project (used while creating a project) will be used.
Example syntax: synth_design -part xc7k70tfbg676-2 (Kintex-7 Xilinx device is targeted for synthesis)
-constrset <constraints_fileset>: [Optional]
It is used for specifying a particular set of xdc constraint files used in synthesis. It is helpful when multiple constraint filesets or constraint files are present. Vivado does not support UCF. This command refers to the already created or existing fileset.
Use create_fileset to create a fileset.
Example syntax: synth_design -part xc7k70tfbg676-2 -constrset constr_1 (Constraint fileset targeted was constr_1)
-top <top_module>: [Optional]
It is used to specify the top module name.
Syntax: synth_design -part xc7k70tfbg676-2 -top module1
Note: If you use the find_top command to define the -top option, make sure you provide only one top if it returns multiple prospects.
-include_dirs <search_directories>: [Optional]
This is used for only Verilog designs. It is used for specifying the directories to search for Verilog `include files.
Syntax: synth_design -part xc7k70tfbg676-2 -top module1 -include_dirs /path/to/directories/
-generic <name> = <value>: [Optional]
This switch is used to specify a VHDL generic value or Verilog parameter value. Here the name indicates the name of the parameter or generic and value indicates the value to be assigned.
If there are two or more generic values to be assigned, use the generic multiple times. Syntax below:
Syntax: synth_design -part xc7k70tfbg676-2 -generic depth=512 -generic width=64
Note: Do not use spaces between the name, = (equal to), value.
Note: When specifying binary values for boolean or std_logic VHDL generic types, you must specify the value using the Verilog bit format, rather than standard VHDL format:
0 = 1`b0
01010000 = 8`b01010000
-verilog_define name=<text>: [Optional]
Used to provide values for the `define and `ifdef statements. To specify two or more statements, use the verilog_define multiple times.
Syntax: synth_design -verilog_define name=value -verilog_define name=value
Note: Do not use spaces between the name, = (equal to), value
-flatten_hierarchy <rebuilt/full/none>: [Optional]
As the name indicates, -flatten_hierarchy determines how synthesis controls hierarchy. The valid values:
Syntax: synth_design -part xc7k70tfbg676-2 -flatten_hierarchy rebuilt
-gated_clock_conversion <off/on/auto>: [Optional]
This switch converts the gated logic to utilize the flop enable pins when available. By default, the value is OFF.
This will utilize available flop enables to convert gating logic in the design. This optimization can eliminate logic and simplify the netlist.
This can also be performed on the synthesized netlist using opt_deisgn command.
This option additionally requires gated_clk attribute to be specified in the HDL. Valid values are off, on, auto.
Syntax: synth_design -part xc7k70tfbg676-2 -gated_clock_conversion off
-directive<Default/RuntimeOptimized/AreaOptimizedLow/AreaOptimizedHigh>: [Optional]
A Synthesis directive. It makes the synthesis tool to achieve specific design objectives. Values are case-sensitive. Valid values are as follows:
-resource_sharing<auto/on/off>: [Optional]
This switch makes the synthesis tool to share arithmetic operators like adders or subtractors between different signals, rather than creating new operators.
This can result in better area utilization when it is turned on. By default, the value is auto.
-control_set_opt_threshold <greater than or equal to 1>:
This switch is used to specify threshold for synchronous control set optimization to lower number of control sets.
The number set to this value specifies how large the fanout of a control set should be before it starts using it as a control set.
For example, if control_set_opt_threshold is set to 10, a synchronous reset that only fans out to 5 registers would be moved to the D inputs logic, rather than using the reset line of a register.
However, if it is set to 4, then the reset line is used. Default: 4
-rtl : [Optional]
Performs the elaboration of the design and opens it.
Syntax: synth_design -part xc7k70tfbg676-2 -rtl
-bufg <value>: [Optional]
Used to specify the maximum number of BUFGs (global clock buffers) to be used during synthesis. This includes instantiated BUFGs in the RTL.
The value should be >= 1. The default value is 12.
Syntax: synth_design -part xc7k70tfbg676-2 -bufg 3
-fanout_limit <value>: [Optional]
This switch limits the maximum net fanout applied during synthesis run.
The value should be >=1. Default value is 10,000.
This switch does not affect control signals (such as set, reset, clock enable). Instead use the MAX_FANOUT attribute in RTL to replicate these signals if needed.
Syntax: synth_design -part xc7k70tfbg676-2 -fanout_limit 2000
-mode <default/out_of_context>: [Optional]
This specifies the mode of the synthesis to be run on the design.
Note: There is no need to specify no_iobuf with this mode (i.e., out_of_context). out_of_context mode is recommended instead of -no_iobuf.
Syntax: synth_design part xc7k70tfbg676-2 -mode out_of_context
-fsm_extraction <off/one_hot/sequential/johnson/gray/auto>: [Optional]
This option is used to identify the state machine and the type of encoding applied while running synthesis. The default value is OFF. The valid values:
Note: Use -fsm_extraction off to disable finite state machine extraction in Vivado Synthesis. This will override the FSM_ENCODING property if specified in RTL.
-no_lc: [Optional]
LUT combining basically merges LUT pairs with common inputs into single dual-output LUT6s in order to improve design area. User can disable it by using -no_lc.
Syntax: synth_design -part xc7k70tfbg676-2 -no_lc
-shreg_min_size <integer>: [Optional]
Used to specify the minimum length for a chain of registers to be mapped onto SRL. The default value is 3
Syntax: synth_design -part xc7k70tfbg676-2 -shreg_min_size 4
-max_bram <arg>: [Optional]
Used to specify the maximum number of block RAM to infer during synthesis. The specified value will not exceed the available block RAM limit of the target device. Default Value: -1.
Note: A value of 0 directs Vivado synthesis to not infer BRAMs in the design, but is not a recommended value.
-max_dsp <arg>:[Optional]
Used to specify the maximum number of DSPs to infer during synthesis. The specified value will not exceed the available DSP limit of the target device. Default Value: -1.
Note: A value of 0 directs Vivado synthesis to not infer DSPs in the design, but is not a recommended value.
-quiet: [Optional]
This switch executes the command quietly, returning no messages from the command. The command also returns TCL_OK regardless of any errors encountered during execution. i.e., Only errors occurring inside the command will be trapped.
-keep_equivalent_registers: [Optional]
Works like the synthesis KEEP attribute to prevent the merging of registers during optimization.
-verbose: [Optional]
This returns all messages (i.e., every message) during synthesis. This will override any message limits if present.
-rtl_skip_ip - [Optional]
When elaborating the RTL design with the -rtl option, this option causes the Vivado Design Suite to skip loading the DCP files for out-of-context modules in the design, and instead load a stub file to treat the OOC modules as a black boxes. This can significantly speed elaboration of the design.
-rtl_skip_constraints - [Optional]
When elaborating the RTL design with the -rtl option, this option causes the Vivado Design Suite to skip loading any design constraints (XDC) into the elaborated design
-cascade_dsp [ auto | tree | force ] - [Optional]
Specifies how to implement adders that add DSP block outputs. Valid values include auto, tree, force. The default setting is auto.
[Optional] -- indicates optional switches.
Answer Number | Answer Title | Version Found | Version Resolved |
---|---|---|---|
55182 | Design Assistant for Vivado Synthesis - Help with synth_design description and supported options | N/A | N/A |
AR# 54958 | |
---|---|
Date | 08/07/2015 |
Status | Active |
Type | Solution Center |
Tools |