Skip to content

Commit b8e95fc

Browse files
Merge branch 'master' into add_or_tools
2 parents c1b7aa8 + a8034e2 commit b8e95fc

File tree

77 files changed

+2725
-1692
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+2725
-1692
lines changed

.github/workflows/containers.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
steps:
1717

1818
- name: 🧰 Repository Checkout
19-
uses: actions/checkout@v3
19+
uses: actions/checkout@v4
2020
with:
2121
submodules: 'true'
2222

.github/workflows/labeler.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ jobs:
66
triage:
77
runs-on: ubuntu-latest
88
steps:
9-
- uses: actions/checkout@v3
9+
- uses: actions/checkout@v4
1010
- uses: actions/labeler@master
1111
with:
1212
repo-token: "${{ secrets.GITHUB_TOKEN }}"

.github/workflows/test.yml

Lines changed: 31 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ jobs:
5151

5252
steps:
5353

54+
# TODO: This runnner is running on a self-hosted CPU. In order to upgrade
55+
# to v4, need to upgrade the machine to support node20.
5456
- uses: actions/checkout@v3
5557
with:
5658
submodules: 'true'
@@ -71,9 +73,12 @@ jobs:
7173
VTR_CMAKE_PARAMS: ${{ matrix.cmake }}
7274
NUM_CORES: ${{ matrix.cores }}
7375

74-
- uses: actions/upload-artifact@v3
75-
if: ${{ always() }}
76+
- name: Upload test results
77+
# TODO: This runnner is running on a self-hosted CPU. In order to upgrade
78+
# to v4, need to upgrade the machine to support node20.
79+
uses: actions/upload-artifact@v3
7680
with:
81+
name: ${{matrix.test}}_test_results
7782
path: |
7883
**/results*.gz
7984
**/plot_*.svg
@@ -92,10 +97,10 @@ jobs:
9297
- { build_type: 'debug', verbose: '1' }
9398
steps:
9499

95-
- uses: actions/setup-python@v4
100+
- uses: actions/setup-python@v5
96101
with:
97102
python-version: 3.10.10
98-
- uses: actions/checkout@v3
103+
- uses: actions/checkout@v4
99104
with:
100105
submodules: 'true'
101106
- run: ./.github/scripts/install_dependencies.sh
@@ -122,10 +127,10 @@ jobs:
122127
name: 'F: ${{ matrix.name }}'
123128
steps:
124129

125-
- uses: actions/setup-python@v4
130+
- uses: actions/setup-python@v5
126131
with:
127132
python-version: 3.10.10
128-
- uses: actions/checkout@v3
133+
- uses: actions/checkout@v4
129134
- run: ./.github/scripts/install_dependencies.sh
130135

131136
- name: Test
@@ -137,10 +142,10 @@ jobs:
137142
runs-on: ubuntu-22.04
138143
steps:
139144

140-
- uses: actions/setup-python@v4
145+
- uses: actions/setup-python@v5
141146
with:
142147
python-version: 3.10.10
143-
- uses: actions/checkout@v3
148+
- uses: actions/checkout@v4
144149
with:
145150
submodules: 'true'
146151
- run: ./.github/scripts/install_dependencies.sh
@@ -156,10 +161,10 @@ jobs:
156161
runs-on: ubuntu-22.04
157162
steps:
158163

159-
- uses: actions/setup-python@v4
164+
- uses: actions/setup-python@v5
160165
with:
161166
python-version: 3.10.10
162-
- uses: actions/checkout@v3
167+
- uses: actions/checkout@v4
163168
with:
164169
submodules: 'true'
165170
- run: ./.github/scripts/install_dependencies.sh
@@ -236,10 +241,10 @@ jobs:
236241
name: 'R: ${{ matrix.name }}'
237242
steps:
238243

239-
- uses: actions/setup-python@v4
244+
- uses: actions/setup-python@v5
240245
with:
241246
python-version: 3.10.10
242-
- uses: actions/checkout@v3
247+
- uses: actions/checkout@v4
243248
with:
244249
submodules: 'true'
245250
- run: ./.github/scripts/install_dependencies.sh
@@ -255,7 +260,7 @@ jobs:
255260
./run_reg_test.py ${{ matrix.suite }} -show_failures -j2
256261
257262
- name: Upload regression run files
258-
uses: actions/upload-artifact@v3
263+
uses: actions/upload-artifact@v4
259264
with:
260265
name: ${{matrix.name}}_run_files
261266
path: |
@@ -266,7 +271,7 @@ jobs:
266271
vtr_flow/**/*.r
267272
268273
- name: Upload regression results
269-
uses: actions/upload-artifact@v3
274+
uses: actions/upload-artifact@v4
270275
with:
271276
name: ${{matrix.name}}_results
272277
path: |
@@ -291,10 +296,10 @@ jobs:
291296
name: 'S: ${{ matrix.name }}'
292297
steps:
293298

294-
- uses: actions/setup-python@v4
299+
- uses: actions/setup-python@v5
295300
with:
296301
python-version: 3.10.10
297-
- uses: actions/checkout@v3
302+
- uses: actions/checkout@v4
298303
with:
299304
submodules: 'true'
300305

@@ -325,10 +330,10 @@ jobs:
325330
runs-on: ubuntu-22.04
326331
steps:
327332

328-
- uses: actions/setup-python@v4
333+
- uses: actions/setup-python@v5
329334
with:
330335
python-version: 3.10.10
331-
- uses: actions/checkout@v3
336+
- uses: actions/checkout@v4
332337
with:
333338
submodules: 'true'
334339
- run: ./.github/scripts/install_dependencies.sh
@@ -350,10 +355,10 @@ jobs:
350355
runs-on: ubuntu-22.04
351356
steps:
352357

353-
- uses: actions/setup-python@v4
358+
- uses: actions/setup-python@v5
354359
with:
355360
python-version: 3.10.10
356-
- uses: actions/checkout@v3
361+
- uses: actions/checkout@v4
357362
with:
358363
submodules: 'true'
359364
- run: ./.github/scripts/install_dependencies.sh
@@ -376,10 +381,10 @@ jobs:
376381
runs-on: ubuntu-22.04
377382
steps:
378383

379-
- uses: actions/setup-python@v4
384+
- uses: actions/setup-python@v5
380385
with:
381386
python-version: 3.10.10
382-
- uses: actions/checkout@v3
387+
- uses: actions/checkout@v4
383388
with:
384389
submodules: 'true'
385390
- run: ./.github/scripts/install_dependencies.sh
@@ -411,10 +416,10 @@ jobs:
411416
name: 'B: ${{ matrix.name }}'
412417
steps:
413418

414-
- uses: actions/setup-python@v4
419+
- uses: actions/setup-python@v5
415420
with:
416421
python-version: 3.10.10
417-
- uses: actions/checkout@v3
422+
- uses: actions/checkout@v4
418423
with:
419424
submodules: 'true'
420425
- run: ./.github/scripts/install_dependencies.sh
@@ -447,10 +452,10 @@ jobs:
447452
runs-on: ubuntu-22.04
448453
steps:
449454

450-
- uses: actions/setup-python@v4
455+
- uses: actions/setup-python@v5
451456
with:
452457
python-version: 3.10.10
453-
- uses: actions/checkout@v3
458+
- uses: actions/checkout@v4
454459
with:
455460
submodules: 'true'
456461
- run: ./.github/scripts/install_dependencies.sh

README.developers.md

Lines changed: 62 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1330,7 +1330,7 @@ Instead changes should be made in the relevant up-stream repository, and then sy
13301330

13311331
For example to update the `libtatum` subtree:
13321332
```shell
1333-
./dev/external_subtrees.py --update libtatum
1333+
./dev/external_subtrees.py --update libtatum -m "commit message describing why component is being updated"
13341334
```
13351335

13361336
## Adding a new Subtree
@@ -1372,8 +1372,66 @@ To add a new external subtree to VTR do the following:
13721372
This will create two commits to the repository.
13731373
The first will squash all the upstream changes, the second will merge those changes into the current branch.
13741374

1375+
## Pushing VTR Changes Back to Upstream Subtree
13751376

1376-
## Subtree Rational
1377+
If there are changes in the VTR repo in a subtree that should be merged back
1378+
into the source repo of the subtree, the changes can be pushed back manually.
1379+
1380+
The instructions above used a Python script to simplify updating subtrees in
1381+
VTR. This is fine for pulling in changes from a remote repo; however, it is not
1382+
good for pushing changes back. This is because these changes need to be pushed
1383+
somewhere, and it is not a good idea to just push it back to the master branch
1384+
directly. Instead, it should be pushed to a temporary branch. Then a PR can be
1385+
made to bring the changes into the target repo.
1386+
1387+
To push changes VTR made to a subtree do the following:
1388+
1389+
1. Create a fork of the target repo. Optionally you can create a branch to be
1390+
the target of the push, or you can just use master.
1391+
1392+
2. Run:
1393+
```shell
1394+
cd $VTR_ROOT
1395+
git subtree push --prefix=<subtree_path> <forked_repo_url> <branch_name>
1396+
```
1397+
The prefix is the internal path to the subtree, as written in
1398+
`dev/subtree_config.xml`.
1399+
1400+
3. Create a PR from your forked repo to the main repo, sharing the amazing
1401+
changes with the world.
1402+
1403+
## Tutorial: Syncing Tatum with VTR
1404+
1405+
This tutorial will show you how to synchronize `libtatum` in VTR and
1406+
[Tatum](https://github.com/verilog-to-routing/tatum); however, similar steps
1407+
can be done to synchronize any subtree in VTR.
1408+
1409+
First, we will pull in (update) any changes in Tatum that are not in VTR yet.
1410+
On a clean branch (based off master), execute the following:
1411+
```shell
1412+
cd $VTR_ROOT
1413+
./dev/external_subtrees.py --update libtatum -m "Pulling in changes from Tatum."
1414+
```
1415+
If the output in the terminal says `Subtree is already at commit <commit_hash>`,
1416+
then there is nothing to pull in. If it says changes were pulled in, a commit
1417+
would have already been made for you. Push these changes to your branch and
1418+
raise a PR on VTR to merge these changes in.
1419+
1420+
After pulling in all the changes from Tatum, without changing branches, we will
1421+
push our VTR changes to Tatum. This is a bit more complicated since, as stated
1422+
in the section on pushing to subtrees, the changes cannot just be pushed to
1423+
master.
1424+
1425+
Create a fork of Tatum and make sure the master branch of that fork is
1426+
synchronized with Tatum's master branch. Then execute the following:
1427+
```shell
1428+
cd $VTR_ROOT
1429+
git subtree push --prefix=libs/EXTERNAL/libtatum <forked_repo_url> master
1430+
```
1431+
After that command finishes, raise a PR from your forked repo onto the Tatum
1432+
repo for the changes to be reviewed and merged in.
1433+
1434+
## Subtree Rationale
13771435
13781436
VTR uses subtrees to allow easy tracking of upstream dependencies.
13791437
@@ -1469,4 +1527,5 @@ The following outlines the procedure to following when making an official VTR re
14691527
* GitHub will automatically create a release based on the tag
14701528
* Add the new change log entry to the [GitHub release description](https://github.com/verilog-to-routing/vtr-verilog-to-routing/releases)
14711529
* Update the [ReadTheDocs configuration](https://readthedocs.org/projects/vtr/versions/) to build and serve documentation for the relevant tag (e.g. `v8.0.0`)
1472-
* Send a release announcement email to the [vtr-announce](mailto:[email protected]) mailing list (make sure to thank all contributors!)
1530+
* Send a release announcement email to the [vtr-announce](mailto:[email protected]) mailing list (make sure to thank all contributors!)
1531+

doc/src/vpr/command_line_usage.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1163,6 +1163,14 @@ VPR uses a negotiated congestion algorithm (based on Pathfinder) to perform rout
11631163

11641164
**Default:** ``1.3``
11651165

1166+
.. option:: --max_pres_fac <float>
1167+
1168+
Sets the maximum present overuse penalty factor that can ever result during routing. Should always be less than 1e25 or so to prevent overflow.
1169+
Smaller values may help prevent circuitous routing in difficult routing problems, but may increase
1170+
the number of routing iterations needed and hence runtime.
1171+
1172+
**Default:** ``1000.0``
1173+
11661174
.. option:: --acc_fac <float>
11671175

11681176
Specifies the accumulated overuse factor (historical congestion cost factor).

libs/EXTERNAL/libtatum/.gitignore

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,3 +52,11 @@ callgrind*
5252
*.rpt
5353
*.dot
5454
*.echo
55+
56+
#Test files
57+
test/mcnc20
58+
test/vtr
59+
test/titan_other
60+
test/titan23
61+
*.tar
62+
*.tar.gz

libs/EXTERNAL/libtatum/.travis.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,16 @@
11
language: cpp
22
dist: trusty #Ubuntu 14.04 by default
3-
sudo: false #Use container based infrastructure
43

54
matrix:
65
include:
76
#Extensive testing for base compiler
8-
- env: TESTS="basic mcnc20" TATUM_EXECUTION_ENGINE=auto MATRIX_EVAL="CC=gcc-5 CXX=g++-5"
7+
- env: TESTS="basic mcnc20 vtr titan_other" TATUM_EXECUTION_ENGINE=auto MATRIX_EVAL="CC=gcc-5 CXX=g++-5"
98
addons: { apt: { packages: ["cmake", "g++-5", "libtbb-dev"], sources: ["ubuntu-toolchain-r-test"] } }
109

11-
- env: TESTS="basic mcnc20" TATUM_EXECUTION_ENGINE=serial MATRIX_EVAL="CC=gcc-5 CXX=g++-5"
10+
- env: TESTS="basic mcnc20 vtr titan_other" TATUM_EXECUTION_ENGINE=serial MATRIX_EVAL="CC=gcc-5 CXX=g++-5"
1211
addons: { apt: { packages: ["cmake", "g++-5", "libtbb-dev"], sources: ["ubuntu-toolchain-r-test"] } }
1312

14-
- env: TESTS="basic mcnc20" TATUM_EXECUTION_ENGINE=tbb MATRIX_EVAL="CC=gcc-5 CXX=g++-5"
13+
- env: TESTS="basic mcnc20 vtr titan_other" TATUM_EXECUTION_ENGINE=tbb MATRIX_EVAL="CC=gcc-5 CXX=g++-5"
1514
addons: { apt: { packages: ["cmake", "g++-5", "libtbb-dev"], sources: ["ubuntu-toolchain-r-test"] } }
1615

1716
#Simple testing for other compilers

libs/EXTERNAL/libtatum/libtatum/tatum/tags/TimingTags.hpp

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#pragma once
2+
#include <cstddef>
23
#include <iterator>
34
#include <memory>
45

@@ -104,15 +105,15 @@ class TimingTags {
104105

105106
//Iterator definition
106107
template<class T>
107-
class Iterator : public std::iterator<std::random_access_iterator_tag, T> {
108+
class Iterator {
108109
friend TimingTags;
109110
public:
110-
using value_type = typename std::iterator<std::random_access_iterator_tag, T>::value_type;
111-
using difference_type = typename std::iterator<std::random_access_iterator_tag, T>::difference_type;
112-
using pointer = typename std::iterator<std::random_access_iterator_tag, T>::pointer;
113-
using reference = typename std::iterator<std::random_access_iterator_tag, T>::reference;
114-
using iterator_category = typename std::iterator<std::random_access_iterator_tag, T>::iterator_category;
115-
public:
111+
using iterator_category = std::random_access_iterator_tag;
112+
using difference_type = std::ptrdiff_t;
113+
using value_type = T;
114+
using pointer = T*;
115+
using reference = T&;
116+
116117
Iterator(): p_(nullptr) {}
117118
Iterator(pointer p): p_(p) {}
118119
Iterator(const Iterator& other): p_(other.p_) {}
@@ -143,7 +144,7 @@ class TimingTags {
143144
friend bool operator>=(Iterator lhs, Iterator rhs) { return lhs.p_ >= rhs.p_; }
144145
friend void swap(Iterator lhs, Iterator rhs) { std::swap(lhs.p_, rhs.p_); }
145146
private:
146-
T* p_ = nullptr;
147+
pointer p_ = nullptr;
147148
};
148149

149150
private:

0 commit comments

Comments
 (0)