Skip to content

Commit

Permalink
[vpr] fixed a bug where perimeter cb are not connected to adjancet sbs
Browse files Browse the repository at this point in the history
  • Loading branch information
tangxifan committed Jul 4, 2024
1 parent 159bea4 commit fbbf53d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ void build_rr_graph_edges(const RRGraphView& rr_graph,
/* Create a GSB object */
const RRGSB& rr_gsb = build_one_tileable_rr_gsb(grids, rr_graph,
device_chan_width, segment_inf_x, segment_inf_y,
layer, gsb_coord);
layer, gsb_coord, perimeter_cb);

/* adapt the track_to_ipin_lookup for the GSB nodes */
t_track2pin_map track2ipin_map; /* [0..track_gsb_side][0..num_tracks][ipin_indices] */
Expand Down
7 changes: 4 additions & 3 deletions vpr/src/tileable_rr_graph/tileable_rr_graph_gsb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,8 @@ RRGSB build_one_tileable_rr_gsb(const DeviceGrid& grids,
const std::vector<t_segment_inf>& segment_inf_x,
const std::vector<t_segment_inf>& segment_inf_y,
const size_t& layer,
const vtr::Point<size_t>& gsb_coordinate) {
const vtr::Point<size_t>& gsb_coordinate,
const bool& perimeter_cb) {
/* Create an object to return */
RRGSB rr_gsb;

Expand Down Expand Up @@ -719,7 +720,7 @@ RRGSB build_one_tileable_rr_gsb(const DeviceGrid& grids,
break;
case BOTTOM: /* BOTTOM = 2*/
/* For the bording, we should take special care */
if (gsb_coordinate.y() == 0) {
if (!perimeter_cb && gsb_coordinate.y() == 0) {
rr_gsb.clear_one_side(side_manager.get_side());
break;
}
Expand Down Expand Up @@ -749,7 +750,7 @@ RRGSB build_one_tileable_rr_gsb(const DeviceGrid& grids,
break;
case LEFT: /* LEFT = 3 */
/* For the bording, we should take special care */
if (gsb_coordinate.x() == 0) {
if (!perimeter_cb && gsb_coordinate.x() == 0) {
rr_gsb.clear_one_side(side_manager.get_side());
break;
}
Expand Down
3 changes: 2 additions & 1 deletion vpr/src/tileable_rr_graph/tileable_rr_graph_gsb.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ RRGSB build_one_tileable_rr_gsb(const DeviceGrid& grids,
const std::vector<t_segment_inf>& segment_inf_x,
const std::vector<t_segment_inf>& segment_inf_y,
const size_t& layer,
const vtr::Point<size_t>& gsb_coordinate);
const vtr::Point<size_t>& gsb_coordinate,
const bool& perimeter_cb);

void build_edges_for_one_tileable_rr_gsb(RRGraphBuilder& rr_graph_builder,
const RRGSB& rr_gsb,
Expand Down

0 comments on commit fbbf53d

Please sign in to comment.