Quartus® Prime Pro Edition User Guide: Design Compilation

ID 683236
Date 9/30/2024
Public
Document Table of Contents

1.16.4.1.1. SDC-on RTL Example: Targeting Pins of Top-level Instances

In certain scenarios, it is necessary to constrain pins of top-level instances. SDC-on-RTL constraints allow you to define constraints at module boundaries using either of the following elements:

  • inst_port—these elements are retrieved in collections as a result of applying the get_pins filter. These elements allow you to target the inputs and outputs of modules, similar to addressing pins on registers.
    Figure 130. inst_port Constraint


    {inst_port::Test::U0|clk_in}
  • port—these elements are in the module itself and are primarily used for targeting ports in entity-bound constraints. You can use the get_ports filter for this purpose.
    Figure 131. port Constraint


    {port::Test::U0|clk_in}

For example, to define clocks and reset inputs, you can use the get_pins Tcl command followed by the hierarchical pin name to filter each pin:

get_pins U0|clk_in

This Tcl command returns the input pin clk_in in the instance U0.

Figure 132. Targeting Pins of Top-level Instances
Similarly, you can target other pins of the same instance and apply necessary constraints as shown in the following:
create_clock -name clk_input -period 10 [get_pins U0|clk_in]
create_generated_clock -name clk_output -source [get_pins U0|clk_in] -divide_by 2 [get_pins U0|clk_out]