Fix routing correctness and bound optional routing work
Check physical keepout clearance, retain useful partial paths, and account for all pair repair searches. Verify complete seeds early and recover narrower corridors when shared guides are blocked. Keep frontier diagnostics outside routing decisions and bound their work by the worker deadline. Correct benchmark scaling and scenario validation, and update the guides and release metadata.
This commit is contained in:
parent
f6e7bac4c5
commit
63acb94642
5 changed files with 1073 additions and 199 deletions
|
|
@ -10,7 +10,7 @@ Follow the left column while coverage is below the target. Reaching the target s
|
|||
|
||||
1. **Set a coverage target.** Conflicting aligned port faces and [track capacity](../inire/router/_capacity.py#L29) at rectangular cuts can bound how many nets fit.
|
||||
2. **Try constructive plans.** Bundles assign ordered tracks, columns schedule turns, and compact planners fit short links. Each plan supplies seeds for the worker to verify.
|
||||
3. **Search for missing routes.** Early attempts use small budgets and can hold verified routes fixed. When a column plan stalls, try separated channels or a shared bypass around the keepouts. If the locks cut off a port, retry with movable seeds or different lanes. With one net left, try a verified detour around the locked paths, including incumbents found by the seed fallback. Lattice search handles custom outlines or proxies and is the fallback when corridor planning is unavailable.
|
||||
3. **Search for missing routes.** Early attempts use small budgets and can hold verified routes fixed. When a column plan stalls, try separated channels or a shared bypass around the keepouts. If the locks cut off a port, retry with movable seeds or different lanes. With one net left, try a verified detour around the locked paths, including incumbents found by the seed fallback. Lattice search handles custom outlines and proxies and can retry unresolved nets after corridor-guided attempts.
|
||||
4. **Select and refine.** Prefer higher verified coverage. Compare cost on matching verified net IDs. Refinement can replace the selected layout only if those IDs remain verified.
|
||||
|
||||
### Example of a poor lock
|
||||
|
|
|
|||
|
|
@ -5,16 +5,16 @@
|
|||
|
||||
## Micron-scale routing cases
|
||||
|
||||
The `expanded` group adds 72 deterministic, unseeded boards with independently constructed reference routes. The authored grid units are 10, 100, 250, 500, and 1000 nm. Bend radii span 10–100 µm and trace widths span 1–20 µm. The comparison script records `grid_nm` for these boards. Convert benchmark-weighted lengths to microns by multiplying by `grid_nm / 1000`.
|
||||
The `expanded` group adds 75 deterministic, unseeded boards with independently constructed reference routes. The authored grid units are 10, 100, 250, 500, and 1000 nm. Bend radii span 10–100 µm and trace widths span 1–20 µm. The comparison script records `grid_nm` for these boards and the imported fixtures. Convert benchmark-weighted lengths to microns by multiplying by `grid_nm / 1000`.
|
||||
|
||||
| Group | Boards | Coverage |
|
||||
| --- | ---: | --- |
|
||||
| `geometry-corners` | 32 | Exact four-bend spans, tight returns and paired routes, exact-span S-bend slots, mixed widths, and saturated or overloaded apertures. |
|
||||
| `complex-layouts` | 24 | Serial aperture banks with opposing tracks, concave and fixed-route keepouts, and staggered crossing arrays. |
|
||||
| `search-challenges` | 8 | Alternating comb walls that force repeated turns and exercise search-budget exhaustion. |
|
||||
| `search-challenges` | 11 | Alternating comb walls and other tight passages that require repeated turns or exercise search-budget exhaustion. |
|
||||
| `scaling` | 8 | Banks and crossing arrays of up to 256 nets, obstacle fields with up to 320 keepouts, and a 240-net board with 240 keepouts and four blocked approaches. |
|
||||
|
||||
Pytest verifies the 72 reference layouts and checks that unseeded routing reaches the known bound on every board. Use `--case search-challenges` or `--case scaling` with an explicit budget to compare routing policies on the harder boards. For scaling comparisons, use the same grid, mode, and budget and collect repeated timings with `--repeat`.
|
||||
Pytest verifies the 75 reference layouts and checks that unseeded routing reaches the known bound on every board. Use `--case search-challenges` or `--case scaling` with an explicit budget to compare routing policies on the harder boards. For scaling comparisons, use the same grid, mode, and budget and collect repeated timings with `--repeat`.
|
||||
|
||||
To exercise the low-budget fallbacks on tight geometry, run `--case geometry-corners --profile corpus-regression --mode automatic --nodes 1 --seed-nodes 1 --iterations 1`.
|
||||
|
||||
|
|
|
|||
|
|
@ -22,10 +22,12 @@ Use repeated wall times to check whether counter changes affect runtime.
|
|||
| Similar expansions, more search time | Check `ray_cast_calls*` and `ray_cast_exact_geometry_checks` for visibility work. Compare dynamic `congestion_candidate_ids` with `congestion_exact_pair_checks` to see how much candidate geometry reaches exact tests. |
|
||||
| Verification dominates | Compare `verify_path_report_calls` with `verify_static_buffer_ops` and `verify_dynamic_exact_pair_checks`. This can distinguish repeated path checks from expensive checks of the same paths. |
|
||||
| Refinement takes longer | Compare `refinement_windows_considered`, `refinement_candidates_verified`, and `refinement_candidates_accepted`. Check whether the added windows buy a better path before enlarging the default budget. |
|
||||
| Attempts reach targets while verified coverage stays flat | Compare `iteration_conflict_edges` and `nets_carried_forward`. After congestion iterations finish, check how many pair repairs were tried and how many were installed. `pair_local_search_nodes_expanded` counts expansions from searches that produced a locally valid pair. Use `pair_local_search_attempts` to count every try. |
|
||||
| Attempts reach targets while verified coverage stays flat | Compare `iteration_conflict_edges` and `nets_carried_forward`. After congestion iterations finish, check how many pair repairs were tried and how many were installed. `pair_local_search_nodes_expanded` counts expansions from every pair-local search and is included in `nodes_expanded`. Use `pair_local_search_attempts` to count every try. |
|
||||
|
||||
`nets_routed` and `nets_reached_target` count attempts. Use `result.is_valid` or `verified_net_ids` for final successes.
|
||||
|
||||
`timeout_events` counts routing workers that reached their deadline. Frontier diagnostics use the time left after routing and final verification. They gather component details for colliding nets and check the deadline during that work and during frontier replay. `diagnostic_timeout_events` counts workers where the deadline stopped or skipped frontier diagnostics. A diagnostic timeout leaves the routing result, retry decisions, and replay callback intact.
|
||||
|
||||
- [Full metrics field list](../inire/results.py)
|
||||
|
||||
Exact corner visibility uses cached local queries. Track them with `visibility_corner_queries_exact` and `visibility_point_cache_hits`. The legacy graph counters `visibility_builds` and `visibility_corner_pairs_checked` report zero, as do `ray_cast_calls_visibility_build` and `ray_cast_calls_visibility_query`.
|
||||
|
|
@ -43,7 +45,7 @@ Returned traces describe the selected attempt. Numbered entries use the same run
|
|||
| Which net consumed an iteration's budget? | `capture_iteration_trace` records `iteration_trace`. Inspect per-net `net_attempts` for expansions, pruning, congestion calls, and seed usage. |
|
||||
| Which routes have a clearance conflict? | `capture_conflict_trace` records the conflicting net IDs and the component indices in `conflict_trace`. |
|
||||
| Which candidate moves were pruned near the conflict? | `capture_frontier_trace` records `frontier_trace` for routes that reached their targets and still conflict with other nets. The trace samples moves and their prune reasons during a replay. |
|
||||
| What did the last unresolved iteration hand to pair-local repair? | `capture_pre_pair_frontier_trace` records `pre_pair_frontier_trace`. Check reroute order, conflict edges, and per-net attempt work immediately before repair. |
|
||||
| What layout did the worker restore for pair-local repair? | `capture_pre_pair_frontier_trace` records the selected congestion iteration, its reroute order, conflict edges, and work. The worker saves that layout and replays it after repair and verification. A conflicting net carried from an earlier iteration has zero attempt work for the selected iteration. |
|
||||
| Where did detailed search explore? | `capture_expanded` records positions and headings from the detailed routing iterations in `expanded_nodes`. Use `plot_expanded_nodes()` as in the [fan-out script](../examples/07_large_scale_routing.py). |
|
||||
|
||||
<a id="find-overlapping-components"></a>
|
||||
|
|
|
|||
|
|
@ -10,17 +10,17 @@
|
|||
|
||||
Read the panels from top to bottom. Follow the crossed triangle edges, the suggested crossing points, then the S-bend in the verified route.
|
||||
|
||||
1. **Find space for centerlines.** Inset the board by half the widest guide's width. Expand obstacles by that amount plus clearance. Try a straight port lead to reach the mesh, or use the port itself. A flush port can reach the inset mesh via a lead whose flat end fits on the board. If a narrow net has no passage, retry with its own width.
|
||||
1. **Find space for centerlines.** Inset the board by half the widest guide's width. Expand obstacles by that amount plus clearance. Try a straight port lead to reach the mesh, or use the port itself. A flush port can reach the inset mesh via a lead whose flat end fits on the board. Nets can reuse shared corridors when the mesh has open space around both ports and the area between them. A narrower mesh can recover missing corridors and add passages near keepouts or board edges. If a shared guide fails and a reserved route occupies that shared space, the worker can build a narrower mesh on demand. A straight path that fits in the shared mesh can supply its own alternate guide.
|
||||
|
||||
<a id="design-background"></a>
|
||||
|
||||
A portal is an edge shared by adjacent free-space triangles. For an earlier representation of a route by its crossings of triangle edges, see Section III-A and Figure 1 of [Hama and Etoh's curvilinear detailed-routing paper](https://www.cecs.uci.edu/~papers/compendium94-03/papers/1998/aspdac98/pdffiles/06c_3.pdf).
|
||||
|
||||
2. **Choose a passage and a lane.** Rank passages by distance and competing nets. Place lanes on shared triangle edges according to turn room and reservations. A joint retry can move lanes for several nets.
|
||||
2. **Choose a passage and a lane.** Rank passages by distance and competing nets. Assign lanes jointly by reserving space on shared triangle edges as each net is planned.
|
||||
|
||||
- [Lane scoring](../inire/router/_topology.py#L255)
|
||||
|
||||
3. **Turn the sketch into a path.** Guide mode suggests moves and adds a soft cost. Seed mode searches within a corridor and checks the resulting seed against obstacles and earlier seeds. With alternatives, it allocates at least half the seed budget to the first corridor.
|
||||
3. **Turn the sketch into a path.** Guide mode suggests moves and adds a soft cost. Seed mode searches within a corridor and checks the resulting seed against obstacles and earlier seeds. With alternatives, it allocates at least half the seed budget to the first corridor. With at least two iterations and positive guidance strength, an explicit guided run that leaves unresolved nets can retry with the guidance cost disabled. Guide and seed modes can verify a complete supplied layout before building corridors.
|
||||
|
||||
A passage can be connected in the mesh and leave too little room to bend onto the target port's heading. For the bend-radius and port-alignment rules that constrain the physical route, see Section II-B of [LiDAR 2.0](https://arxiv.org/html/2505.17239v1#S2.SS2).
|
||||
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ Set `TopologyOptions(mode=...)` and pass it as `topology` in `RoutingOptions`.
|
|||
- **`off`.** Run lattice search directly to measure what search can do without corridor suggestions.
|
||||
- **`guide`.** Suggest a passage through free space. Search can leave it to make a turn.
|
||||
- **`seed`.** Try to build a valid starting path inside the suggested passage before the detailed search.
|
||||
- **`bundle`.** Route supported ordered rectangular bundles with an empty `initial_paths` mapping. Use circular physical bends. The smallest 90-degree bend radius must be a positive integer and must also appear in `sbend_radii`. Unsupported layouts and invalid schedules raise `ValueError`.
|
||||
- **`bundle`.** Route supported ordered rectangular bundles with an empty `initial_paths` mapping. Use circular physical bends and configure a usable positive integer radius in both `bend_radii` and `sbend_radii`. Unsupported layouts and invalid schedules raise `ValueError` when routing iterations are enabled.
|
||||
|
||||
### Mode requirements
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue