stt: no test case exercises `makeSteinerTree`'s alpha branch or its FLUTE fallback
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 72/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Ambito
- testing-qa
Direzione di ricerca
Start at SteinerTreeBuilder::makeSteinerTree and the existing cases under src/stt/test, especially check.tcl and report_stt_net. Review src/stt/test/BUILD and CMakeLists.txt for the two test entry points, then run //src/stt/test:stt_gate-tcl_test and //src/stt/test:stt_gate-py_test. Done means the stt_gate inputs and expected output cover the listed branches and both build-system tests pass.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
SteinerTreeBuilder::makeSteinerTree is the public entry point for Steiner tree construction, and
it is where the choice between the two builders is made:
if (alpha > 0.0) {
Tree tree = pdr::primDijkstra(x, y, drvr_index, alpha, logger_);
if (checkTree(tree)) { return tree; }
// Fall back to flute if PD fails.
}
return flute_->flute(x, y, kFluteAccuracy);
Reading src/stt/test, the cases reach the builders directly rather than through this function:
| case | helper | reaches |
|---|---|---|
flute1, flute_gcd |
report_flute_net |
Flute::flute |
pd1, pd2, pd_gcd |
report_pd_net |
pdr::primDijkstra |
check |
report_stt_net |
makeSteinerTree — one net, one alpha |
parse_clocks |
— | filter_clk_nets, no trees |
check.tcl is the only case that calls it, with a single 11-pin net at alpha 0.3. So the
alpha > 0.0 comparison has a witness on one side only, checkTree is never observed rejecting
anything, and the FLUTE fallback after a failed check has no witness at all. Inverting the
comparison, inverting the check, or returning the rejected tree instead of rebuilding would leave
all seven cases passing.
The fallback is reachable in practice, not just in principle: over randomly generated nets, on the
order of one in thirty thousand produces a Prim-Dijkstra tree that checkTree rejects.
Two smaller gaps in the same area, from the shipped inputs:
-
gcd.nets(which drivesflute_gcdandpd_gcd) has top-level degrees 3–8, 10, 11 and 36;
flute1is one 250-pin net;pd1,pd2andcheckare small. No case has a top-level net of
degree 2 or degree 9. Degree 9 iskMaxLutDegree, andkNumGroup[9]is about 89% of the
groups in the lookup table. Degree 2 is a separate early return in bothFlute::fluteand
Flute::flutes_low_degree, and the two index differently.
⚠️ Both degrees are reachable by recursion from larger nets, so this is a gap in direct
coverage rather than a claim that the code never runs. -
report_stt_neton a one-pin net at alpha 0 aborts:[ERROR STT-0007] Invalid driver index -1.Flute::flutereturnsdeg = 1with an emptybranchvector, sofindLocationIndexscans
nothing and returns -1.primDijkstrahas no such problem —pd1'sonenet reports fine.
Whether that matters outside the reporter is a real question:grtconsumes theTreerather
than printing it, and an emptybranchon a one-pin net may be exactly what it wants.
What we could offer
A single case, stt_gate, in the shape of the existing ones: stt_gate.tcl, stt_gate.py and a
shared stt_gate.ok, plus one line in src/stt/test/BUILD and one in CMakeLists.txt. It drives
41 nets through report_stt_net and reaches:
- every lookup-table degree 4–9 and the degenerate returns below 4, including 2 and 9;
- the medium-degree decomposition, its scoring heuristic and all three merges;
- alpha = 0 and alpha > 0 over the same points, so the branch is crossed both ways;
- a driver index that is not 0, and duplicate pin locations;
- a net whose Prim-Dijkstra tree fails
checkTree, so the fallback executes; - a 120-pin net, above the
deg > 100bound wherecheckTreeis skipped.
It runs under both build systems today — //src/stt/test:stt_gate-tcl_test and
//src/stt/test:stt_gate-py_test both pass locally against an unmodified build.
⚠️ The .ok would be generated at a specific commit rather than at master; happy to regenerate it
against whatever you would merge.
Questions
- Would you want this as a PR? Nothing is opened until you say so.
- Is one broad case welcome in
src/stt/test, or would you rather have it split per behaviour?
Either shape is easy on our side. - Is the FLUTE fallback meant to be reachable at all, or is a
checkTreerejection a sign of
something upstream of it worth fixing?
- Lingua principale
- Verilog
- Stelle
- 3.4k
- Fork
- 1.1k
- Merge medio
- 3g 11h
- PR unite (30g)
- 245
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di The-OpenROAD-Project/OpenROAD
-
odb LEF58_MINIMUMCUT: per-cut-class form never sets isPerCutClass, so drt silently drops the ruleForse già presa @LucasYuki l’ha presa 26 giorni fa. Apertabug drt odb
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
The-OpenROAD-Project/OpenROAD#12176 · 2 commenti · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
drt: LEF58_SPACING ENDOFLINE MINLENGTH l TWOSIDES is checked one-sided (io passes the TWOEDGES flag as TWOSIDES)Forse già presa @osamahammad21 l’ha presa 26 giorni fa. Apertabug drt
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
The-OpenROAD-Project/OpenROAD#12173 · 1 commento · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
cleanup-opportunity: BUILD files never refer to mockturtle in third-partty/Forse di nuovo libera Una pull request per questa issue è stata chiusa senza essere unita. Apertabazel enhancement
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 76/100
The-OpenROAD-Project/OpenROAD#12160 · 4 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
odb: Bazel build fails on linux/aarch64 — char fc compared to EOF in def/lef lexersForse già presa @shivarammysore l’ha presa 32 giorni fa. Apertabazel bug odb
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 80/100
The-OpenROAD-Project/OpenROAD#12095 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
syn: acd_resynth -apply segfaults on a database resynthesized in an earlier processForse di nuovo libera @povik l’ha presa 31 giorni fa e non c’è nessuna pull request aperta. Apertabug syn
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
The-OpenROAD-Project/OpenROAD#12046 · 2 commenti · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di The-OpenROAD-Project/OpenROAD
Issue simili
-
claim
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
Nixitov/Riptide-Native#946 ·
I maintainer di solito rispondono entro 1 giorno
-
Emulator tests fail on mainApertaarea: ci
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
GlassworksHQ/glassworks#1548 ·
I maintainer di solito rispondono entro 1 giorno
-
v3
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
pluginkollektiv/antispam-bee#952 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
JTHCode/secretguard#24 ·
I maintainer di solito rispondono entro 1 giorno
-
agent/quality testing
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 95/100
I maintainer di solito rispondono entro 1 giorno