Skip to content

sky130hd/litepci: route-fix via spread lever (util 30 / density 0.40 / halo 100) — now closes#166

Merged
mguthaus merged 2 commits into
mainfrom
sky130hd-litepci-route-fix
May 21, 2026
Merged

sky130hd/litepci: route-fix via spread lever (util 30 / density 0.40 / halo 100) — now closes#166
mguthaus merged 2 commits into
mainfrom
sky130hd-litepci-route-fix

Conversation

@mguthaus
Copy link
Copy Markdown
Contributor

Summary

Closes sky130hd/litepci, which was previously failing in global routing on main. Same spreading lever as PR #165 (sky130hd NVDLA partitions) and the longstanding sky130hd/cnn config, scaled for litepci's macro-pin density.

Problem

sky130hd/litepci on main fails GRT with:

[WARNING GRT-0281] Net rst has a large fanout of 3211 terminals.
Error: detail_route.tcl, 8 Global routing failed
[ERROR GRT-0116] Global routing finished with congestion

~460k total overflow, max_v=12 on met2 — local congestion from the 6-FakeRAM-macro + pcie_us-PHY layout, exacerbated by a 3211-terminal reset net. (PLACE_DENSITY_LB_ADDON was forcing density above the achieved util, packing std cells against macro pin clusters.)

Fix

Knob Before After
CORE_UTILIZATION 55 30
PLACE_DENSITY — (LB_ADDON wired) 0.40
MACRO_PLACE_HALO 20 20 100 100

Drops the packing forcing function (PLACE_DENSITY_LB_ADDON), explicitly sets PLACE_DENSITY: 0.40 per the new optimize-ppa 2c' spread recipe (~10 pp below achieved util), and triples MACRO_PLACE_HALO to push std cells off the macro pin edges. This is the same family as sky130hd/cnn's 0.20 + 300 and PR #165's partition configs, scaled for litepci's macro pin density (partition_p ≤ 6 macros + central placement = halo 60; litepci 6 SRAM + PHY blackbox + 3211-fanout reset = halo 100).

Also includes the sky130hd portion of c75ea18 (FakeRAM macro rename to unified _sram naming, the sister of PR #162 for nangate45) which is required for the design to find its macros.

Validation on NRP k8s (4h57m, Complete, exit 0)

Metric Value
Die area 105.8 mm²
Achieved util 31.4%
TNS setup 0
Hold violations 0
Cells (seq+comb) ~41 k
Macros 21
IOs 875

finish__timing__setup__ws returns a sentinel value (1e+39) — litepci has no constrained internal setup paths (PHY blackbox handles the timing-critical work). Standard for this design family.

Known DRVs (not blocking, pre-existing class)

13 028 max_slew + 427 max_cap violations. The reset net's 3211-terminal fanout is the dominant contributor — it's an RTL property, not introduced by this change. Sky130hd's coarse pitch amplifies the count vs. nangate45. Tracked as a follow-up that would need a PRE_GRT_TCL script to buffer the reset tree, or upstream RTL gating (not in scope for HighTide as a benchmark suite).

Cross-references

  • PR #164 — the optimize-ppa skill's new 2c' section that documents this lever
  • PR #165 — sister application of 2c' to sky130hd NVDLA partitions
  • PR #162 — the matching nangate45/litepci macro rename

mguthaus added 2 commits May 20, 2026 15:27
…o 20->60

Pre-existing util=55 was tuned against the buggy pre-wd_in-fix LEFs (where
upper-half wd_in pins had inverted DIRECTION; routing through them was
silently underestimated). With electrically-correct macros, the same util
fails GRT with 460k+ overflow (242k met1, 204k met2) and local MaxV=12 on
met2 — local congestion, not global density.

Backoff:
  CORE_UTILIZATION   55 -> 40   (-15pp; aligns with cnn-sky strategy of
                                  large macro count + low util on sky130hd)
  PLACE_DENSITY    0.65 -> 0.55 (small drop; spread std cells)
  MACRO_PLACE_HALO  20 -> 60    (push macros apart so met2 escape lanes
                                  don't collide; cnn-sky uses 300)

Also cherry-picks the sky130hd portion of c75ea18 (fakeram macro renames
to unified _sram naming) which was excluded from PR #162. Both changes
together (rename + backoff) needed to close.
R1 backoff (util 40 / density 0.55 / halo 60) STILL FAILED at GRT with same
signature: 'Global routing failed' + Net rst fanout 3211 + ~460k overflow on
met1/met2. Backoff not aggressive enough.

R2: bigger backoff matching sky130hd/cnn-style spread (cnn-sky uses util 28.6%
achieved with PLACE_DENSITY 0.20 + MACRO_PLACE_HALO 300):
  util  40 -> 30  (similar absolute level to cnn-sky's achieved)
  density 0.55 -> 0.40  (explicit spread per 2c')
  halo 60 -> 100  (wider macro keep-out so escape lanes don't collide)

If this still fails -> escalate to halo 200 (between current 100 and cnn-sky's 300).
@mguthaus mguthaus merged commit 01ca876 into main May 21, 2026
mguthaus added a commit that referenced this pull request May 21, 2026
NEW design row. sky130hd/litepci previously failed at GRT on main; the
route-fix (PR #166, branch sky130hd-litepci-route-fix at 5777394) closes it
cleanly after 4h57m. Metrics from k8s build:

  die_um2     105807000  (~106 mm^2; pcie_us PHY + 5 SRAMs + 21 macros total)
  util %      31.4
  cells       58014 (12762 seq + 28659 comb + 16593 buf/inv)
  io          875
  power_mW    1.021

ws/skew/fmax shown as 0 because litepci has no constrained internal setup
paths (PHY blackbox handles timing-critical work) — same pattern as
nangate45/litepci. TNS setup = 0, hold = 0 (no real violations).

Gallery image deferred — the k8s build targeted _final, and a local _gallery
re-derive would re-run the place/route from scratch (5h+). When PR #166
merges to main, the next /update-results sweep will pick up the cached
_gallery from a fresh k8s run.

Note: 13028 max_slew + 427 max_cap DRVs (high-fanout reset net is dominant;
documented in PR #166 body, not a setup/hold-violating timing issue).
mguthaus added a commit that referenced this pull request May 21, 2026
LitePCIe was missing from gallery.html entirely even though nangate45/litepci
had a built image (litepci_nangate45_c941d626.png from PR #162). Added a
card matching the LiteEth card style:
  - asap7: placeholder ('pending') — no image yet; the litepci-multiplat-fix
    asap7 build completed earlier but gallery wasn't rendered. Will populate
    on next /update-results sweep once cached.
  - nangate45: shows litepci_nangate45_c941d626 (the post-PR-#162 build)
  - sky130hd: placeholder — sky/litepci R2 (PR #166) build targeted _final,
    no gallery yet; will populate when PR #166 merges and a fresh sweep runs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant