feat: merge nearby parallel same-net traces (#34)#354
Open
ron1nrest wants to merge 6 commits into
Open
Conversation
Add MergeParallelTracesSolver to align and consolidate close parallel segments on the same net, wired into the pipeline after overlap shift.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Minimal JP6-R1-SJ2 repro; snapshots at traceOverlapShift vs mergeParallelTracesSolver. Co-authored-by: Cursor <cursoragent@cursor.com>
- Use explicit pre-merge trace repro (two parallel same-net segments) - Snapshot single MergeParallelTracesSolver before/after solve() - Deep-clone traces in solver constructor to avoid shared refs Co-authored-by: Cursor <cursoragent@cursor.com>
Reproduces offset parallel horizontal runs on same net snapping to shared y=1, not collapsing two traces into one. Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implemented MergeParallelTracesSolver to merge nearby parallel same-net traces. Added unit tests.
Thanks for the clarification — re-read #34 and updated the example.
Issue #34 is about snapping same-net segments that are almost on the same Y or X onto a shared axis (remove the small jog between parallel runs), not collapsing two unrelated 2-point traces into one line.
Repro (
example35)tests/assets/example35.json— minimal C14/C15-style layout onV3_3tests/assets/example35-pre-merge-traces.json— two routed paths whose internal horizontal runs are offset by ~0.12 (the jog from the screenshot)Before / after
tests/examples/example35.test.tsrunsMergeParallelTracesSolveron deep-cloned traces:Assertions: still 2 traces;
tracePath[1].yandtracePath[2].y→1on both; endpoints at0/0.12preserved.Sorry for the earlier repro — it demonstrated trace consolidation, not same-Y alignment.
Closes #34
/claim #34