@@ -1187,12 +1187,12 @@ void initial_placement(const t_placer_opts& placer_opts,
1187
1187
clear_all_grid_locs ();
1188
1188
1189
1189
/* Go through cluster blocks to calculate the tightest placement
1190
- * floorplan constraint for each constrained block
1191
- */
1190
+ * floorplan constraint for each constrained block
1191
+ */
1192
1192
propagate_place_constraints ();
1193
1193
1194
1194
/* Mark the blocks that have already been locked to one spot via floorplan constraints
1195
- * as fixed, so they do not get moved during initial placement or later during the simulated annealing stage of placement*/
1195
+ * as fixed, so they do not get moved during initial placement or later during the simulated annealing stage of placement*/
1196
1196
mark_fixed_blocks ();
1197
1197
1198
1198
// Compute and store compressed floorplanning constraints
@@ -1204,17 +1204,22 @@ void initial_placement(const t_placer_opts& placer_opts,
1204
1204
read_constraints (constraints_file);
1205
1205
}
1206
1206
1207
- if (noc_opts.noc ) {
1208
- // NoC routers are placed before other blocks
1209
- initial_noc_placement (noc_opts, placer_opts);
1210
- propagate_place_constraints ();
1211
- }
1207
+ if (!placer_opts.read_initial_place_file .empty ()) {
1208
+ const auto & grid = g_vpr_ctx.device ().grid ;
1209
+ read_place (nullptr , placer_opts.read_initial_place_file .c_str (), false , grid);
1210
+ } else {
1211
+ if (noc_opts.noc ) {
1212
+ // NoC routers are placed before other blocks
1213
+ initial_noc_placement (noc_opts, placer_opts);
1214
+ propagate_place_constraints ();
1215
+ }
1212
1216
1213
- // Assign scores to blocks and placement macros according to how difficult they are to place
1214
- vtr::vector<ClusterBlockId, t_block_score> block_scores = assign_block_scores ();
1217
+ // Assign scores to blocks and placement macros according to how difficult they are to place
1218
+ vtr::vector<ClusterBlockId, t_block_score> block_scores = assign_block_scores ();
1215
1219
1216
- // Place all blocks
1217
- place_all_blocks (placer_opts, block_scores, placer_opts.pad_loc_type , constraints_file);
1220
+ // Place all blocks
1221
+ place_all_blocks (placer_opts, block_scores, placer_opts.pad_loc_type , constraints_file);
1222
+ }
1218
1223
1219
1224
alloc_and_load_movable_blocks ();
1220
1225
0 commit comments