Skip to content

cts: add regression test for single-sink cluster buffer balance (#9070)#10728

Open
saurav-fermions wants to merge 1 commit into
The-OpenROAD-Project:masterfrom
Fermions-ASI:fix/9070
Open

cts: add regression test for single-sink cluster buffer balance (#9070)#10728
saurav-fermions wants to merge 1 commit into
The-OpenROAD-Project:masterfrom
Fermions-ASI:fix/9070

Conversation

@saurav-fermions

Copy link
Copy Markdown
Contributor

Summary

Adds a regression test for single-sink ('orphan') cluster sink-buffer balance in TritonCTS. The behavior is already correct on current master; this test guards against regression of the per-cluster sink buffer for single-sink clusters (whose absence otherwise caused a buffer-depth/latency imbalance). Test-only, no code change.

Type of Change

  • Tests

Impact

Test-only; no code or golden change.

Verification

  • Local build succeeds.
  • Relevant tests pass (rebuilt from source): ctest -R '^cts\.' passes with the added test.
  • Code follows the repository's formatting guidelines.
  • I have signed my commits (DCO).

Related Issues

Fixes #9070


Developed with SAIGE, Fermions' autonomous RTL/EDA debugging agent; root-caused, tested, and signed off by the submitter (@saurav-fermions).

…OpenROAD-Project#9070)

CTS sink clustering could leave isolated sinks in single-sink (orphan)
clusters that bypassed the clkbuf_leaf_ buffer level, giving those sinks
one fewer buffer in their clock path than clustered sinks and creating
skew (issue The-OpenROAD-Project#9070, visible on sky130hd/aes).

The source fix (every non-empty cluster, including single-sink ones, gets
a leaf buffer in HTreeBuilder::preSinkClustering) is already in place. This
adds a regression test that reproduces the orphan condition: a dense block
of >200 sinks plus several far-apart isolated sinks that each form their
own single-sink cluster. It asserts balanced clock-path buffer depth
(CTS-0012 minimum == CTS-0013 maximum).

Verified: with the fix reverted the test design reports min 3 / max 4
buffers; with the fix it reports min 4 / max 4. Registered in both CMake
and Bazel.

Signed-off-by: Saurav Singh <saurav.singh@fermions.co>
@saurav-fermions saurav-fermions requested a review from a team as a code owner June 21, 2026 05:17

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new regression test, sink_clustering_single_sink, to ensure that single-sink (orphan) clusters do not bypass the leaf-buffer level during CTS sink clustering. The review feedback correctly identifies that some of the isolated orphan sinks are placed outside the defined die area (up to 3,850,000 DBUs, whereas the die area is set to 2,600,000 DBUs) and suggests increasing the die area to prevent potential downstream issues.


$block setDefUnits [$tech getDbUnitsPerMicron]
set rect [odb::Rect]
$rect init 0 0 2600000 2600000

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The die area is initialized to 2600000 x 2600000 DBUs, but the isolated orphan sinks are placed at coordinates up to 3850000 DBUs (far + off where far = 2000000 and the maximum offset is 1850000). This places several instances outside the defined die area, which can lead to unexpected behavior or downstream failures. Consider increasing the die area to at least 4000000 x 4000000 DBUs to fully enclose all placed instances.

  $rect init 0 0 4000000 4000000

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CTS leaves sinks that are in no cluster degrading QoR

1 participant