Skip to content

Commit bcf74d0

Browse files
Merge pull request #3178 from AlexandreSinger/feature-packer-iterative-restart-bug
[Packer] Fixed NightlyTest Failure with Tight Floorplan Constr.
2 parents 8447e3b + 3f1b16e commit bcf74d0

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

vpr/src/pack/pack.cpp

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -105,22 +105,6 @@ static e_packer_state get_next_packer_state(e_packer_state current_packer_state,
105105
return e_packer_state::SUCCESS;
106106
}
107107

108-
// Check if the utilizaion of any block types is over 100%
109-
if (!fits_on_device) {
110-
// The utilization of some block types are too high. Need to increase the
111-
// density of the block types available.
112-
113-
// Check if we can turn on unrelated cluster and/or balanced block type
114-
// utilization.
115-
if (packer_opts.allow_unrelated_clustering == e_unrelated_clustering::AUTO && packer_opts.balance_block_type_utilization == e_balance_block_type_util::AUTO) {
116-
117-
// Check if they are not already on. If not, set the next state to turn them on.
118-
if (!using_unrelated_clustering || !using_balanced_block_type_util) {
119-
return e_packer_state::SET_UNRELATED_AND_BALANCED;
120-
}
121-
}
122-
}
123-
124108
// Check if there are overfilled floorplan regions.
125109
if (floorplan_regions_overfull) {
126110
// If there are overfilled region constraints, try to use attraction
@@ -152,6 +136,22 @@ static e_packer_state get_next_packer_state(e_packer_state current_packer_state,
152136
}
153137
}
154138

139+
// Check if the utilizaion of any block types is over 100%
140+
if (!fits_on_device) {
141+
// The utilization of some block types are too high. Need to increase the
142+
// density of the block types available.
143+
144+
// Check if we can turn on unrelated cluster and/or balanced block type
145+
// utilization.
146+
if (packer_opts.allow_unrelated_clustering == e_unrelated_clustering::AUTO && packer_opts.balance_block_type_utilization == e_balance_block_type_util::AUTO) {
147+
148+
// Check if they are not already on. If not, set the next state to turn them on.
149+
if (!using_unrelated_clustering || !using_balanced_block_type_util) {
150+
return e_packer_state::SET_UNRELATED_AND_BALANCED;
151+
}
152+
}
153+
}
154+
155155
// Check if we can increase the target density of the overused block types.
156156
// This is a last resort since increasing the target pin density can have
157157
// bad affects on quality and routability.

0 commit comments

Comments
 (0)