Follow these stpes to change the read order of an XDC file or unmanaged Tcl script in a constraints set:
- In the Sources window, select the XDC file or Tcl script you want to move.
- Drop the file to the specific position in the constraints set.
For the example in Figure 1, the equivalent Tcl command is:
reorder_files -fileset constrs_1 -before [get_files wave_gen_timing.xdc] \
[get_files wave_gen_pins.xdc]
In non-project mode, the sequence of read_xdc
or source commands determines the order of constraint
file loading. If you use an IP core with constraints, the tool automatically handles two
groups of constraints:
- Constraints that do not depend on clocks are grouped in an XDC file
with
PROCESSING_ORDERset toEARLY - Constraints that depend on clocks are grouped in an XDC file with
PROCESSING_ORDERset toLATE
By default, XDC files created outside of an IP belong to the PROCESSING_ORDER NORMAL group. They load after EARLY XDC
files and before LATE XDC files. For each PROCESSING_ORDER group, IP XDC files load in the same sequence that the IP
cores appear in the IP Sources window.
When the design opens, the log file shows the IP XDC file load order. For example:
Parsing XDC File [C:/project_wave_gen_hdl.srcs/sources_1/ip/clk_core/clk_core.xdc] for cell 'clk_gen_i0/clk_core_i0/inst'
Finished Parsing XDC File [C:/project_wave_gen_hdl.srcs/sources_1/ip/clk_core/clk_core.xdc] for cell 'clk_gen_i0/clk_core_i0/inst'
Parsing XDC File [C:/project_wave_gen_hdl.srcs/sources_1/ip/char_fifo/char_fifo/char_fifo.xdc] for cell 'char_fifo_i0/U0'
Finished Parsing XDC File [C:/project_wave_gen_hdl.srcs/sources_1/ip/char_fifo/char_fifo/char_fifo.xdc] for cell 'char_fifo_i0/U0'
Parsing XDC File [C:/project_wave_gen_hdl.srcs/constrs_1/imports/verilog/wave_gen_timing.xdc] Finished Parsing XDC File [C:/project_wave_gen_hdl.srcs/constrs_1/imports/verilog/wave_gen_timing.xdc] Parsing XDC File [C:/project_wave_gen_hdl.srcs/sources_1/ip/char_fifo/char_fifo/char_fifo_clocks.xdc
] for cell 'char_fifo_i0/U0'
Finished Parsing XDC File [C:/project_wave_gen_hdl.srcs/sources_1/ip/char_fifo/char_fifo/char_fifo_clocks.xdc
] for cell 'char_fifo_i0/U0' Completed Processing XDC Constraints
You cannot directly change the read order of IP XDC files in the same PROCESSING_ORDER group. Follow these steps to modify the
order:
- Disable the corresponding IP XDC files by setting
IS_ENABLEDto false. - Copy their content.
- Paste the content into one of the XDC files in the constraints set.
- Update the copied IP XDC commands with the full hierarchical netlist object path names where needed. The tool writes IP XDC constraints scoped to the IP instance.
- Review the
get_portsqueries. The tool processes these queries in a special way for scoped constraints.
For more information on XDC scoping, refer to Constraints Scoping.