Skip to content

Commit

Permalink
Remove reliance on gap routing test (#1117)
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Lavin <[email protected]>
  • Loading branch information
clavin-xlnx authored Dec 2, 2024
1 parent c96faf8 commit 510a87f
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
14 changes: 14 additions & 0 deletions src/com/xilinx/rapidwright/design/NetTools.java
Original file line number Diff line number Diff line change
Expand Up @@ -144,4 +144,18 @@ public static List<NodeTree> getNodeTrees(Net net) {

return subtrees;
}

/**
* Checks if the provided net drives a clock site pin input.
*
* @param net The net to examine.
* @return True if the net has a site pin clock input, false otherwise.
*/
public static boolean hasClockSinks(Net net) {
for (SitePinInst sink : net.getPins()) {
if (sink.isOutPin()) continue;
if (sink.getName().contains("CLK")) return true;
}
return false;
}
}
3 changes: 2 additions & 1 deletion src/com/xilinx/rapidwright/design/tools/RelocationTools.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
import com.xilinx.rapidwright.design.DesignTools;
import com.xilinx.rapidwright.design.Module;
import com.xilinx.rapidwright.design.Net;
import com.xilinx.rapidwright.design.NetTools;
import com.xilinx.rapidwright.design.SiteInst;
import com.xilinx.rapidwright.design.SitePinInst;
import com.xilinx.rapidwright.design.blocks.PBlock;
Expand Down Expand Up @@ -284,7 +285,7 @@ public static boolean relocate(Design design,
}
}

boolean isClockNet = n.isClockNet() || n.hasGapRouting();
boolean isClockNet = n.isClockNet() || NetTools.hasClockSinks(n);
n.getPIPs().removeIf((sp) -> {
Tile st = sp.getTile();
Tile dt = st.getTileXYNeighbor(tileColOffset, tileRowOffset);
Expand Down

0 comments on commit 510a87f

Please sign in to comment.