Residue of #116: 62 of 372 dcbench instances still exceed the 60s cap
The sentry (28->2) and gitpod (34->1) hang classes are fixed, but three repo classes remain, and each traces to a NAMED uncapped/slow builder (all complete at ~35-40s builder time, so these are 60-120s instances, not infinite hangs):
| class |
instances |
culprit (DIFFCTX_TRACE_BUILDERS) |
trace |
| kubernetes |
21 |
GoEdgeBuilder: 14.3M edges / 39.8s on 078f462a955b |
go caps landed (#116) but the per-import package match is a linear scan for (pkg, frag_ids) in &pkg_to_frags — O(imports x packages), plus emission volume |
| home-assistant |
20 |
PythonEdgeBuilder: 38.0M edges / 7.8s on 21e51b83d3ae — capped channels still fan wide on a 10k-module monorepo; AND structural[testing]: 37.3s for 2,562 edges — compute-bound quadratic scan, not emission |
|
| polars |
17 |
RustEdgeBuilder: 35.4M edges / 34.6s on 3b6875ae9879 — rust_type/rust_fn channels have NO max_files_per_name cap (the same disease python/js/go had) |
|
Repro: git -C test-repos/<repo> worktree add --detach wt <commit> then DIFFCTX_TRACE_BUILDERS=1 diffctx . --diff '<commit>^..<commit>' -q -f json --budget 8000 --timeout 120.
Fix sketch, in expected-value order: (1) rust.rs gets the standard MAX_FILES_PER_NAME = 8 def-file cap (mechanical, same patch as python/js/go); (2) go.rs import loop gets a pkg_to_frags.get(&imp_pkg) lookup instead of the full-map scan; (3) profile testing.rs on the home-assistant instance (37s for 2.5k edges is a scan bug, likely same-stem or name-pair quadratic); (4) re-measure the 62. Post-emission single-threaded dedup (~50s of a 52s sentry run, noted at #116 close) is the second-order lever after these.
Full list of the 62 instance ids: results/final/v6/dcbench_new/*.jsonl rows with status != produced.
Residue of #116: 62 of 372 dcbench instances still exceed the 60s cap
The sentry (28->2) and gitpod (34->1) hang classes are fixed, but three repo classes remain, and each traces to a NAMED uncapped/slow builder (all complete at ~35-40s builder time, so these are 60-120s instances, not infinite hangs):
078f462a955bfor (pkg, frag_ids) in &pkg_to_frags— O(imports x packages), plus emission volume21e51b83d3ae— capped channels still fan wide on a 10k-module monorepo; AND structural[testing]: 37.3s for 2,562 edges — compute-bound quadratic scan, not emission3b6875ae9879— rust_type/rust_fn channels have NO max_files_per_name cap (the same disease python/js/go had)Repro:
git -C test-repos/<repo> worktree add --detach wt <commit>thenDIFFCTX_TRACE_BUILDERS=1 diffctx . --diff '<commit>^..<commit>' -q -f json --budget 8000 --timeout 120.Fix sketch, in expected-value order: (1) rust.rs gets the standard
MAX_FILES_PER_NAME = 8def-file cap (mechanical, same patch as python/js/go); (2) go.rs import loop gets apkg_to_frags.get(&imp_pkg)lookup instead of the full-map scan; (3) profile testing.rs on the home-assistant instance (37s for 2.5k edges is a scan bug, likely same-stem or name-pair quadratic); (4) re-measure the 62. Post-emission single-threaded dedup (~50s of a 52s sentry run, noted at #116 close) is the second-order lever after these.Full list of the 62 instance ids:
results/final/v6/dcbench_new/*.jsonlrows withstatus != produced.