Skip to content

Commit d5f39ff

Browse files
committed
Merge branch 'master' into fredt_check_blif_model_is_in_arch
2 parents 85754ef + 6a1fe64 commit d5f39ff

File tree

3 files changed

+31
-12
lines changed

3 files changed

+31
-12
lines changed

.github/workflows/test.yml

Lines changed: 23 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -122,27 +122,42 @@ jobs:
122122
fail-fast: false
123123
matrix:
124124
include:
125-
- { name: 'C/C++', script: 'check-format.sh' }
126-
- { name: 'Python', script: 'check-format-py.sh' }
127-
- { name: 'Python Lint', script: 'pylint_check.py' }
125+
- { name: 'C/C++', script: 'check-format.sh' , with_python: 'no', pkgs: 'clang-format-18' }
126+
- { name: 'Python', script: 'check-format-py.sh', with_python: 'yes', pkgs: '' }
127+
- { name: 'Python Lint', script: 'pylint_check.py' , with_python: 'yes', pkgs: '' }
128128
name: 'F: ${{ matrix.name }}'
129129
steps:
130130

131+
- uses: actions/checkout@v4
132+
# NOTE: We do not need sub-modules. We do not check sub-modules for formatting.
133+
131134
# TODO: This should be on the same version of Python as would be found on
132135
# Ubuntu 24.04 (3.12.3); however that version has some linting errors.
136+
# - The version of Pylint in requirements.txt is not compatible with
137+
# python version 3.12.3. Pylint needs to be updated to move to this version.
133138
- uses: actions/setup-python@v5
139+
if: ${{ matrix.with_python == 'yes' }}
134140
with:
135141
python-version: 3.10.10
136142

137-
- uses: actions/checkout@v4
138-
with:
139-
submodules: 'true'
143+
- name: Build Python Virtual Env
144+
run: |
145+
python -m venv .venv
146+
147+
- name: Install Python Requirements
148+
if: ${{ matrix.with_python == 'yes' }}
149+
run: |
150+
source .venv/bin/activate
151+
pip install -r requirements.txt
140152
141153
- name: Install dependencies
142-
run: ./.github/scripts/install_dependencies.sh
154+
if: ${{ matrix.pkgs }}
155+
run: sudo apt install -y ${{ matrix.pkgs }}
143156

144157
- name: Test
145-
run: ./dev/${{ matrix.script }}
158+
run: |
159+
source .venv/bin/activate
160+
./dev/${{ matrix.script }}
146161
147162
148163
VerifyTestSuites:

vpr/src/route/rr_graph_generation/tileable_rr_graph/tileable_rr_graph_node_builder.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -847,7 +847,11 @@ static void load_one_chan_rr_nodes_basic_info(const RRGraphView& rr_graph,
847847
size_t seg_id = chan_details.get_track_segment_id(itrack);
848848
e_parallel_axis wanted_axis = chan_type == e_rr_type::CHANX ? e_parallel_axis::X_AXIS : e_parallel_axis::Y_AXIS;
849849
size_t parallel_seg_id = find_parallel_seg_index(seg_id, seg_index_map, wanted_axis);
850-
rr_node_driver_switches[node] = RRSwitchId(segment_infs[parallel_seg_id].arch_opin_switch);
850+
if (Direction::DEC == chan_details.get_track_direction(itrack) && segment_infs[parallel_seg_id].arch_opin_switch_dec != -1) {
851+
rr_node_driver_switches[node] = RRSwitchId(segment_infs[parallel_seg_id].arch_opin_switch_dec);
852+
} else {
853+
rr_node_driver_switches[node] = RRSwitchId(segment_infs[parallel_seg_id].arch_opin_switch);
854+
}
851855

852856
// Update chan_details with node_id
853857
chan_details.set_track_node_id(itrack, size_t(node));

vpr/src/route/segment_stats.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -111,8 +111,8 @@ void get_segment_usage_stats(std::vector<t_segment_inf>& segment_inf) {
111111
}
112112

113113
VTR_LOG("\n");
114-
VTR_LOG("Segment occupancy by length: Length utilization\n");
115-
VTR_LOG(" ------ -----------\n");
114+
VTR_LOG("Segment occupancy by length: Length Occupancy Capacity Utilization\n");
115+
VTR_LOG(" ------ --------- -------- -----------\n");
116116
for (const int seg_length : segment_lengths) {
117117
if (directed_cap_by_length[e_parallel_axis::X_AXIS][seg_length] != 0 || directed_cap_by_length[e_parallel_axis::Y_AXIS][seg_length] != 0) {
118118
std::string seg_name = "L" + std::to_string(seg_length);
@@ -124,7 +124,7 @@ void get_segment_usage_stats(std::vector<t_segment_inf>& segment_inf) {
124124
cap += directed_cap_by_length[ax][seg_length];
125125
}
126126
utilization = (float)occ / (float)cap;
127-
VTR_LOG(" %s %11.3g\n", seg_name.c_str(), utilization);
127+
VTR_LOG(" %-6s %9d %8d %11.3g\n", seg_name.c_str(), occ, cap, utilization);
128128
}
129129
}
130130

0 commit comments

Comments
 (0)