-
Notifications
You must be signed in to change notification settings - Fork 415
Global Nets Routing constraints #2446
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 58 commits
dda93e6
e9ceea4
0b546ac
1b71564
204e93c
b4ba730
7ba41d8
3095426
f4e3c64
3c1fd46
d463cdd
dc268cb
1c71627
ca5ba48
1200f7a
fad6d66
af2c801
e79d3c5
71910f3
b3689e4
7e5ff68
460b2a7
b4e7e33
1611242
8f9399d
bbe9076
b969445
cd38989
9736316
570947a
71c05cf
99c2a53
f9789b2
f2200f1
d700aa4
55e3445
37fcafc
9541a86
ce7dbc3
06360f6
d85311d
342784f
fd0af8e
c2e6a55
c336f09
9c862ec
b9c8775
8bbd7e9
9364e9f
f217f82
c8c8865
f1e513c
70b911f
1882daa
fe5b660
835f4d0
60cc65b
925834f
d3c17e5
9d9f14a
ff06e15
904d190
a1d213e
a4a4a42
1e7c90d
b70e728
1afe1c5
9de1631
5c65093
f976e9c
32983bc
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
from sphinxcontrib.domaintools import custom_domain | ||
from sphinx.util.docfields import * | ||
|
||
|
||
def setup(app): | ||
app.add_domain( | ||
custom_domain( | ||
"VPRConstraintsDomain", | ||
name="vpr_constraints", | ||
label="Place and Route Constraints", | ||
elements=dict( | ||
tag=dict( | ||
objname="Attribute", | ||
indextemplate="pair: %s; Tag Attribute", | ||
fields=[ | ||
GroupedField( | ||
"required_parameter", label="Required Attributes", names=["req_param"] | ||
), | ||
GroupedField( | ||
"optional_parameter", label="Optional Attributes", names=["opt_param"] | ||
), | ||
Field("required", label="Tag Required", names=["required"]), | ||
], | ||
), | ||
), | ||
) | ||
) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
Global Routing Constraints | ||
========================== | ||
.. _global_routing_constraints: | ||
|
||
VPR allows users to designate specific nets in the input netlist as global and define the routing model for the global nets by utilizing a VPR constraints XML file. These routing constraints for global nets are specified inside the VPR constraints file in XML format, as described in the following section. | ||
|
||
A Global Routing Constraints File Example | ||
------------------------------------------ | ||
|
||
.. code-block:: xml | ||
:caption: An example of a global routing constraints file in XML format. | ||
:linenos: | ||
|
||
<vpr_constraints tool_name="vpr"> | ||
<global_route_constraints> | ||
<set_global_signal name="clock*" route_model="dedicated_network" network_name="clock_network"/> | ||
</global_route_constraints> | ||
</vpr_constraints> | ||
|
||
|
||
Global Routing Constraints File Format | ||
--------------------------------------- | ||
.. _global_routing_constraints_file_format: | ||
|
||
.. vpr_constraints:tag:: <global_route_constraints>content</global_route_constraints> | ||
|
||
Content inside this tag contains a group of ``<set_global_signal>`` tags that specify the global nets and their assigned routing methods. | ||
|
||
.. vpr_constraints:tag:: <set_global_signal name="string" route_model="{ideal|route|dedicated_network}" network_name="string"/> | ||
|
||
:req_param name: The name of the net to be assigned as global. Regular expressions are also accepted. | ||
:req_param route_model: The route model for the specified net. | ||
|
||
* ``ideal``: The net is not routed. There would be no delay for the global net. | ||
|
||
* ``route``: The net is routed similarly to other nets using generic routing resources. | ||
|
||
* ``dedicated_network``: The net will be routed through a dedicated clock network. | ||
|
||
:req_param network_name: The name of the clock network through which the net is routed. This parameter is required when ``route_model="dedicated_network"``. | ||
|
||
|
||
Dedicated Clock Networks | ||
-------------------------- | ||
|
||
Users can define a clock architecture in two ways. First, through the architecture description outlined in section :ref:`Clocks <clock_architecture>`. By using the ``<clocknetworks>`` tag, users can establish a single clock architecture with the fixed default name "clock_network". When routing a net through the dedicated network described with this tag, the network name must be set to ``"clock_network"``. | ||
|
||
Alternatively, users can define a custom clock network architecture by inputting a custom resource routing graph. In this approach, users can specify various clock routing networks, such as a global clock network and multiple regional clock networks. There are three main considerations for defining a clock network through a custom RR graph definition, as described in the following sections. | ||
|
||
Virtual Sinks Definition for Clock Networks | ||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
For VPR to route global nets within defined clock networks, there needs to be a virtual sink node defined in the RR graph per each clock network. This virtual sink, which is of the type ``"SINK"``, must have incoming edges from all drive points of the clock network. The two-stage router used for global net routing will initially route to the virtual sink (which serves as the entry point of the clock network) in the first stage and then from the entry point to the actual sink of the net in the second stage. | ||
|
||
To indicate that a node represents a clock network virtual sink, users can utilize the ``"clk_res_type"`` attribute on a node setting it to ``"VIRTUAL_SINK"``. | ||
|
||
Distinguishing Between Clock Networks | ||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
Given the support for multiple clock networks, VPR needs a way to distinguish between different virtual sinks belonging to various clock networks. This is achieved through the optional ``"name"`` attribute for the rr_node, accepting a string used as the clock network name. Therefore, when the ``"clk_res_type"`` is set to ``"VIRTUAL_SINK"``, the attribute ``"name"`` becomes a requried parameter to enable VPR to determine which clock netwrok the virtual sink belongs to. | ||
kimiatkh marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
When specifying the network_name in a global routing constraints file for routing a global net through a desired clock network, as described in the :ref:`above <global_routing_constraints_file_format>` section, the name defined as an attribute in the virtual sink of the clock network should be used to reference that clock network. | ||
|
||
Segment Definition for Clock Networks | ||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
The node types ``"CHANX"`` and ``"CHANY"`` can construct the clock routing architecture, similar to a generic routing network. However, to identify nodes that are part of a clock network, one can define unique segments for clock networks. To indicate that a segment defined is a clock network resource, users can use the optional attribute ``res_type="GCLK"``. Therefore, nodes with a segment ID of this defined segment are considered to be part of a clock network. | ||
|
||
While VPR currently does not leverage this distinction of clock network resources, it is recommended to use the ``res_type="GCLK"`` attribute, as this preparation ensures compatibility for future support. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It would be good to add an example of clock network routing here. You'd give little snippets of each file that together would make sense. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have added an example at the end of the Dedicated Clock Networks section. It contains snapshots of an RR graph related to the clock network along with some explanation. Could you please take a look and let me know if you have any comments? |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
VPR Constraints | ||
========================= | ||
.. _vpr_constraints: | ||
|
||
VPR allows users to run the flow with placement constraints that enable primitives to be locked down to a specific region on the chip and global routing constraints that facilitate the routing of global nets through clock networks. | ||
|
||
Users can specify these constraints through a constraints file in XML format, as shown in the format below. | ||
|
||
.. code-block:: xml | ||
:caption: The overall format of a VPR constraints file | ||
:linenos: | ||
|
||
<vpr_constraints tool_name="vpr"> | ||
<partition_list> | ||
<!-- Placement constraints are specified inside this tag --> | ||
</partition_list> | ||
<global_route_constraints> | ||
<!-- Global routing constraints are specified inside this tag --> | ||
</global_route_constraints> | ||
</vpr_constraints> | ||
|
||
.. note:: Use the VPR option :option:`vpr --read_vpr_constraints` to specify the VPR constraints file that is to be loaded. | ||
|
||
The top-level tag is the ``<vpr_constraints>`` tag. This tag can contain ``<partition_list>`` and ``<global_route_constraints>`` tags. The ``<partition_list>`` tag contains information related to placement constraints, while ``<global_route_constraints>`` contains information about global routing constraints. The details for each of these constraints are given in the respective sections :ref:`Placement Constraints <placement_constraints>` and :ref:`Global Route Constraints <global_routing_constraints>`. | ||
|
||
.. toctree:: | ||
:maxdepth: 2 | ||
|
||
placement_constraints | ||
global_routing_constraints | ||
|
||
|
Uh oh!
There was an error while loading. Please reload this page.