diff options
| author | idatui <user@clank> | 2026-08-09 13:55:31 +0200 |
|---|---|---|
| committer | idatui <user@clank> | 2026-08-09 13:55:31 +0200 |
| commit | d7966c178047d190faba7100a40385eb00f5894b (patch) | |
| tree | f4a2796d166adb41f85518601c6de44266102504 /docs | |
| parent | Graph: name the interpreter when pytriskel is missing (diff) | |
| download | ida-tui-d7966c178047d190faba7100a40385eb00f5894b.tar.gz ida-tui-d7966c178047d190faba7100a40385eb00f5894b.tar.xz ida-tui-d7966c178047d190faba7100a40385eb00f5894b.zip | |
Graph: fix the triskel fallbacks, and say why when it still falls back
"engine triskel -> native+triskel-failed" was unreadable and, worse,
gave no reason: the cause went to a logger a TUI user never sees.
Dumped all 400 functions of bin/ls (echo's 128 were not enough) and swept
them at three zoom levels: 6 of 1200 layouts fell back, all of them my
own _verify tripping over a detour that could not be placed.
- the detour jumped to the nearest side of the FIRST box in the way,
which in a dense layout is usually inside the next box along. It now
collects every box the run passes and picks the nearest genuinely
free line.
- it skipped the first and last segments because they carry the port
and the arrowhead. But that is exactly where the failures were:
triskel is happy to park a block directly above its successor and
drive the final approach straight through it. Those segments may now
move ALONG their own box's border, which is free almost every time.
- repairs are swept to a fixed point: moving one segment stretches its
neighbours, which can push those into a box.
0/1200 fallbacks after that. Then the bigger corpus turned up a second,
genuinely upstream defect: superimposing SESE regions can leave two
blocks a couple of columns into each other (2 of ls's 400 functions,
in float space, before rounding). Cosmetic in a PNG; here the boxes are
made of text, so one block's disassembly overwrites another's. _verify
now checks it and falls back, which is the right trade.
Reporting, so this is never mute again:
- stats["engine_error"] carries the reason, the status line shows it,
and the label is "native (triskel failed)".
- the corpus test asserts fallbacks are rare AND explained, rather
than asserting they never happen.
Also lowered AUTO_TRISKEL_MAX_BLOCKS 250 -> 180. Layout runs on every
zoom keypress and triskel knees hard past ~175 blocks (174: 66ms,
233: 489ms, 329: 555ms). The old cap allowed a 489ms stall. The corpus
timing check now measures only sizes `auto` can actually reach, plus a
5s ceiling so nothing blows up quadratically when forced.
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/GRAPH_VIEW.md | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/docs/GRAPH_VIEW.md b/docs/GRAPH_VIEW.md index d588b3d..d4f0180 100644 --- a/docs/GRAPH_VIEW.md +++ b/docs/GRAPH_VIEW.md @@ -61,9 +61,13 @@ text. `graph.layout(blocks, sizer, engine=...)` takes `auto` (the default, also `$IDATUI_GRAPH_ENGINE`), `native` or `triskel`, and `e` cycles them in the view. -`auto` prefers **triskel** where it is installed and the function is at most 250 +`auto` prefers **triskel** where it is installed and the function is at most 180 blocks, and falls back to **native** otherwise — including if triskel raises, -which is never fatal. +which is never fatal, and the status line then says why. + +The 180 is an interactivity budget: layout runs on every open and every zoom +keypress, and triskel's cost knees hard just past it (174 blocks: 66 ms; +233 blocks: 489 ms; 329: 555 ms; 424: 1.5 s, against native's 25/72/93/144). | | native | triskel | |---|---|---| |
