Skip to content

Add same-net trace segment merge helper#555

Open
defgtyg wants to merge 13 commits into
tscircuit:mainfrom
defgtyg:main
Open

Add same-net trace segment merge helper#555
defgtyg wants to merge 13 commits into
tscircuit:mainfrom
defgtyg:main

Conversation

@defgtyg

@defgtyg defgtyg commented Jun 19, 2026

Copy link
Copy Markdown

Summary

  • add a reusable TraceCleanupSolver helper for nearby same-net horizontal/vertical trace segments
  • use endpoint segments as stable anchors while only moving interior segments so pin attachments stay pinned
  • add regression tests for horizontal, vertical, different-net isolation, and endpoint preservation

Validation

  • GitHub Actions are re-running after removing the broader pipeline hook that changed existing routing snapshots
  • Vercel preview is ready
  • Not run locally; authored and reviewed through the GitHub web editor in the fork.

/claim #34

@vercel

vercel Bot commented Jun 19, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
schematic-trace-solver Ready Ready Preview, Comment Jun 19, 2026 12:11pm

Request Review

@defgtyg

defgtyg commented Jun 19, 2026 via email

Copy link
Copy Markdown
Author

Copy link
Copy Markdown

Update after CI: I kept this PR scoped to the reusable same-net segment merge helper plus focused regression tests. A direct TraceCleanupSolver pipeline hook changed several existing routing snapshots, so I backed that out to avoid mixing the reusable geometry fix with broader solver behavior changes. If this direction looks good, I can wire the helper into the cleanup pipeline in a follow-up with whatever collision/snapshot constraints maintainers prefer.

Current checks are passing: format, type check, tests, and Vercel preview.

Wire the same-net segment merge helper into the final TraceCleanupSolver pipeline step.

yijianli79-tech commented Jun 19, 2026

Copy link
Copy Markdown

Correction: I tested wiring the same-net segment merge helper directly into the final TraceCleanupSolver pipeline step, but that broader hook changed six existing routing snapshots. I reverted that hook so this PR stays scoped to the reusable helper plus focused regression coverage while preserving the existing pipeline behavior.

The helper still preserves endpoint-only traces and only moves interior segments. If maintainers want the helper enabled in the cleanup pipeline, I can do that separately with the expected snapshot/collision constraints.

@defgtyg defgtyg changed the title Merge nearby same-net trace segments during cleanup Add same-net trace segment merge helper Jun 19, 2026
Connects the same-net segment merge helper as the final TraceCleanupSolver pipeline step so nearby horizontal or vertical same-net traces are merged during cleanup for tscircuit#34.
Keeps the cleanup pipeline integration for tscircuit#34 but falls back to the existing traces if the merged result collides with chips or net labels.
Formats the collision guard added for the cleanup pipeline same-net merge step.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants