Skip to content

Commit fe5b660

Browse files
committed
Create a new documentation page for VPR constraints with references to global routing constraints and placement constraints
1 parent 1882daa commit fe5b660

File tree

2 files changed

+55
-24
lines changed

2 files changed

+55
-24
lines changed

doc/src/vpr/placement_constraints.rst

Lines changed: 23 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,40 @@
11

2-
VPR Placement Constraints
3-
=========================
4-
.. _vpr_constraints_file:
2+
Placement Constraints
3+
======================
4+
.. _placement_constraints:
5+
56
VPR supports running flows with placement constraints. Placement constraints are set on primitives to lock them down to specified regions on the FPGA chip. For example, a user may use placement constraints to lock down pins to specific locations on the chip. Also, groups of primitives may be locked down to regions on the chip in CAD flows that use floorplanning or modular design, or to hand-place a timing critical piece.
67

78
The placement constraints should be specified by the user using an XML constraints file format, as described in the section below. When VPR is run with placement constraints, both the packing and placement flows are performed in such a way that the constraints are respected. The packing stage does not pack any primitives together that have conflicting floorplan constraints. The placement stage considers the floorplan constraints when choosing a location for each clustered block during initial placement, and does not move any block outside of its constraint boundaries during place moves.
89

9-
A Constraints File Example
10-
--------------------------
10+
A Placement Constraints File Example
11+
------------------------------------
1112

1213
.. code-block:: xml
1314
:caption: An example of a placement constraints file in XML format.
1415
:linenos:
1516
1617
<vpr_constraints tool_name="vpr">
17-
<partition_list>
18-
<partition name="Part0">
19-
<add_atom name_pattern="li354"/>
20-
<add_atom name_pattern="alu*"/> <!-- Regular expressions can be used to provide name patterns of the primitives to be added -->
21-
<add_atom name_pattern="n877"/>
22-
<add_region x_low="3" y_low="1" x_high="7" y_high="2"/> <!-- Two rectangular regions are specified, together describing an L-shaped region -->
23-
<add_region x_low="7" y_low="3" x_high="7" y_high="6"/>
24-
</partition>
25-
<partition name="Part1">
26-
<add_region x_low="3" y_low="3" x_high="7" y_high="7" subtile="0"/> <!-- One specific location is specified -->
27-
<add_atom name_pattern="n4917"/>
28-
<add_atom name_pattern="n6010"/>
29-
</partition>
30-
</partition_list>
18+
<partition_list>
19+
<partition name="Part0">
20+
<add_atom name_pattern="li354"/>
21+
<add_atom name_pattern="alu*"/> <!-- Regular expressions can be used to provide name patterns of the primitives to be added -->
22+
<add_atom name_pattern="n877"/>
23+
<add_region x_low="3" y_low="1" x_high="7" y_high="2"/> <!-- Two rectangular regions are specified, together describing an L-shaped region -->
24+
<add_region x_low="7" y_low="3" x_high="7" y_high="6"/>
25+
</partition>
26+
<partition name="Part1">
27+
<add_region x_low="3" y_low="3" x_high="7" y_high="7" subtile="0"/> <!-- One specific location is specified -->
28+
<add_atom name_pattern="n4917"/>
29+
<add_atom name_pattern="n6010"/>
30+
</partition>
31+
</partition_list>
3132
</vpr_constraints>
3233
3334
.. _end:
3435

35-
Constraints File Format
36-
-----------------------
36+
Placement Constraints File Format
37+
---------------------------------
3738

3839
VPR has a specific XML format which must be used when creating a placement constraints file. The purpose of this constraints file is to specify
3940

@@ -42,9 +43,7 @@ VPR has a specific XML format which must be used when creating a placement const
4243

4344
The file is passed as an input to VPR when running with placement constraints. When the file is read in, its information is used during the packing and placement stages of VPR. The hierarchy of the file is set up as follows.
4445

45-
.. note:: Use the VPR option :vpr:option:`--read_vpr_constraints` to specify the VPR placement constraints file that is to be loaded.
46-
47-
The top level tag is the ``<vpr_constraints>`` tag. This tag contains one ``<partition_list>`` tag. The ``<partition_list>`` tag can be made up of an unbounded number of ``<partition>`` tags. The ``<partition>`` tags contains all of the detailed information of the placement constraints, and is described in detail below.
46+
The top level tag is the ``<vpr_constraints>`` tag. This tag can contain one ``<partition_list>`` tag. The ``<partition_list>`` tag can be made up of an unbounded number of ``<partition>`` tags. The ``<partition>`` tags contains all of the detailed information of the placement constraints, and is described in detail below.
4847

4948
Partitions, Atoms, and Regions
5049
------------------------------

doc/src/vpr/vpr_constraints.rst

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
VPR Constraints
2+
=========================
3+
.. _vpr_constraints:
4+
5+
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.
6+
7+
Users can specify these constraints through a constraints file in XML format, as shown in the format below.
8+
9+
.. code-block:: xml
10+
:caption: The overall format of a VPR constraints file
11+
:linenos:
12+
13+
<vpr_constraints tool_name="vpr">
14+
<partition_list>
15+
<!-- Placement constraints are specified inside this tag -->
16+
</partition_list>
17+
<global_route_constraints>
18+
<!-- Global routing constraints are specified inside this tag -->
19+
</global_route_constraints>
20+
</vpr_constraints>
21+
22+
.. note:: Use the VPR option :option:`vpr --read_vpr_constraints` to specify the VPR constraints file that is to be loaded.
23+
24+
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>`.
25+
26+
.. toctree::
27+
:maxdepth: 2
28+
29+
placement_constraints
30+
global_routing_constraints
31+
32+

0 commit comments

Comments
 (0)