Skip to content

Add SameNetTraceMergeSolver to merge close parallel trace segments#135

Open
Nithinfgs wants to merge 4 commits intotscircuit:mainfrom
Nithinfgs:same-net-trace-merge
Open

Add SameNetTraceMergeSolver to merge close parallel trace segments#135
Nithinfgs wants to merge 4 commits intotscircuit:mainfrom
Nithinfgs:same-net-trace-merge

Conversation

@Nithinfgs
Copy link

/claim #29

Implementation Summary:

This PR introduces a new pipeline phase called SameNetTraceMergeSolver that merges trace segments belonging to the same net when they are sufficiently close together. The goal is to eliminate redundant parallel traces and produce a cleaner schematic trace output.

The solver checks trace endpoints and merges segments when the geometric distance between them is below a small threshold. This ensures traces that should logically form a continuous connection are represented as a single merged segment.

Verification:

• Implemented the solver SameNetTraceMergeSolver to detect and merge close same-net trace segments.

• Verified the implementation by running the full test suite (bun test).

• All existing tests pass successfully after adding the solver.

Integration:

The new solver is designed to run as part of the schematic trace solving pipeline and processes trace segments before the final output stage, ensuring that redundant segments are merged before further processing.

@vercel
Copy link

vercel bot commented Mar 23, 2026

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

Project Deployment Actions Updated (UTC)
schematic-trace-solver Ready Ready Preview, Comment Mar 23, 2026 3:01pm

Request Review

@Nithinfgs
Copy link
Author

Hey @seveibar, I’ve added the SameNetTraceMergeSolver and verified all tests pass. Could you take a look and check this out for the bounty? Thanks

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.

1 participant