Skip to content

Add same-net trace alignment phase#306

Open
digzrow-coder wants to merge 4 commits into
tscircuit:mainfrom
digzrow-coder:main
Open

Add same-net trace alignment phase#306
digzrow-coder wants to merge 4 commits into
tscircuit:mainfrom
digzrow-coder:main

Conversation

@digzrow-coder
Copy link
Copy Markdown

Fixes #29.
/claim #29

Adds a pipeline phase that aligns nearby same-net trace segments onto a shared X or Y coordinate when their ranges overlap. This runs after overlap shifting and before net label placement so later stages consume the cleaned-up traces.

The alignment solver:

  • handles horizontal and vertical interior segments
  • preserves trace endpoints connected to pins
  • skips different-net segments
  • rejects a candidate move if it would introduce a coincident overlap with another net

Verified locally:

  • bun test (61 passing, 4 skipped)
  • bunx tsc --noEmit
  • bun run build
  • bunx biome check lib/solvers/SameNetTraceAlignmentSolver/SameNetTraceAlignmentSolver.ts tests/solvers/SameNetTraceAlignmentSolver/same-net-trace-alignment-solver.test.ts lib/solvers/SchematicTracePipelineSolver/SchematicTracePipelineSolver.ts lib/index.ts

@vercel
Copy link
Copy Markdown

vercel Bot commented May 11, 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 May 11, 2026 11:12am

Request Review

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.

New Phase To combine same-net trace segments that are close together

1 participant