Skip to content

Repair trace overlaps using geometry-sized clearance detours - #130

Draft
Abse2001 wants to merge 7 commits into
fix/broad-repulsion-trace-pad-widthfrom
fix/terminal-pad-overlap-via-relocation
Draft

Repair trace overlaps using geometry-sized clearance detours#130
Abse2001 wants to merge 7 commits into
fix/broad-repulsion-trace-pad-widthfrom
fix/terminal-pad-overlap-via-relocation

Conversation

@Abse2001

@Abse2001 Abse2001 commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

When an overlap remains after force-based repair, fixed-distance doglegs can miss the same conflict at another size or across several trace vertices. Add a geometry-sized same-layer detour that uses the blocker extent, trace width, and declared clearance. It covers trace-to-pad, trace-to-plated-hole, trace-to-trace, and trace-to-via conflicts, including rotated obstacles.

The detour grows across same-layer vertices while preserving ports, layer transitions, through-obstacle spans, and other routes. It is attempted after existing candidates stall, without a low-DRC-count gate. Each stalled error is attempted once until the routes change. Acceptance requires fewer full-board DRC errors and no new DRC error identities. The repair does not change fabrication constraints or remove requested routes.

This is broader overlap handling, not a guarantee that every board is routable. Crowded multi-obstacle paths and terminals without a legal escape can remain unresolved. The original SRJ33 sample051 has not been demonstrated clean under its original fabrication rules. The existing explicitly permitted small-via test remains a separate configuration test.

Validation on c51c84722093839f9f603d26f5a78e8f05c9af91:

  • Remote repair suite: 100 passed, zero failed; typecheck passed.
  • 384 candidate configurations vary overlap kind, dimensions, 45-degree rotations, translation, route reversal, and detour direction. Segmented traces are checked with both the repair engine and the autorouter's exact @tscircuit/checks@0.0.163 version, added only as a test dependency.
  • An eight-overlap board verifies that large blockers are repaired without changing endpoints or via rules.
  • Remote run: https://github.com/tscircuit/high-density-repair03/actions/runs/34626335012

The existing terminal-via relocation overlap fix is retained, with its permission and drill-fit checks. This PR is stacked on the exact Repair03 dependency pinned by the autorouter baseline (5f6c9af547dbb70c8948227011e1769b5dfa16a5).

Applied autorouter PR: tscircuit/tscircuit-autorouter#2545. Full applied tests and unchanged-input same-machine benchmarks are pending. No tests, builds, installs, or solver benchmarks run locally.

@tscircuitbot

Copy link
Copy Markdown

Benchmark This PR

Run benchmarks by commenting on this PR:

/benchmark [benchmark.sh args...]
/benchmark [scenario-limit|all] --dataset <drc14|srj18> --concurrency <n> --effort <n> --max-iterations <n>

Everything after /benchmark is forwarded directly to ./benchmark.sh.

Examples:

  • /benchmark -> run default SRJ18 benchmark settings
  • /benchmark 10 -> run first 10 SRJ18 samples
  • /benchmark --dataset srj18 -> run all SRJ18 samples
  • /benchmark 1 --dataset srj18 -> run the first SRJ18 sample
  • /benchmark --dataset drc14 -> run all DRC14 samples
  • /benchmark all --concurrency 4 -> run all SRJ18 samples with 4 workers
  • /benchmark --scenario-limit all --effort 2 -> run all samples with effort 2
  • /benchmark --scenario-limit 20 --max-iterations 100 -> run 20 samples with a max iteration override

Any PR whose title contains [BENCHMARK TEST] will automatically run the benchmark workflow on PR updates.

@Abse2001 Abse2001 changed the title Repair overlapping terminal approaches with via-in-pad relocation Repair trace overlaps using geometry-sized clearance detours Sep 11, 2026
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.

2 participants