Skip to content

Commit

Permalink
ifp: move x_offset check
Browse files Browse the repository at this point in the history
Signed-off-by: Eder Monteiro <[email protected]>
  • Loading branch information
eder-matheus committed Oct 10, 2022
1 parent 64a40a8 commit b5736ab
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/ifp/src/InitFloorplan.cc
Original file line number Diff line number Diff line change
Expand Up @@ -483,9 +483,13 @@ void InitFloorplan::makeTracks(odb::dbTechLayer* layer,
grid = dbTrackGrid::create(block_, layer);
}

if (x_offset == 0) {
x_offset = x_pitch;
}
if (y_offset == 0) {
y_offset = y_pitch;
}

if (x_offset > die_area.dx()) {
logger_->warn(
IFP,
Expand All @@ -505,8 +509,8 @@ void InitFloorplan::makeTracks(odb::dbTechLayer* layer,
auto x_track_count = int((die_area.dx() - x_offset) / x_pitch) + 1;
grid->addGridPatternX(die_area.xMin() + x_offset, x_track_count, x_pitch);

if (x_offset == 0) {
x_offset = x_pitch;
// Check if track origin is usable during router
int layer_min_width = layer->getMinWidth();
}
auto y_track_count = int((die_area.dy() - y_offset) / y_pitch) + 1;
grid->addGridPatternY(die_area.yMin() + y_offset, y_track_count, y_pitch);
Expand Down

0 comments on commit b5736ab

Please sign in to comment.