From 42dd62998989bc80ddc133cbc7c3ad6d809247db Mon Sep 17 00:00:00 2001 From: blasty Date: Thu, 9 Jul 2026 20:39:12 +0200 Subject: test: --stop-after for fast single-feature iteration; skip needless decompile - test_tui.py: add --stop-after , ending the run once a matching check has been evaluated so you can iterate on one feature without paying for the expensive tail (e.g. 'search finds' -> 5.6s vs 34.6s full). Default unchanged. - app: skip _decomp_line_for on a plain function-entry jump (line 0 in both views), avoiding a needless decompile on every by-name navigation in the decompiler pane. full suite 60/60. --- idatui/app.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'idatui') diff --git a/idatui/app.py b/idatui/app.py index ba463e2..d1f3e01 100644 --- a/idatui/app.py +++ b/idatui/app.py @@ -1566,11 +1566,14 @@ class IdaTui(App): return model = self.program.disasm(fn.addr, fn.name) idx = 0 if ea == fn.addr else model.index_of_ea(ea) - # The disasm cursor alone doesn't position the pseudocode pane. When it's - # the active view, also resolve the target address to its pseudocode line - # (via the per-line /*0xEA*/ markers) so the jump lands on the reference - # there too (e.g. selecting an xref while in the decompiler view). - dec_idx = self._decomp_line_for(fn.addr, ea) if self._active == "decomp" else -1 + # The disasm cursor alone doesn't position the pseudocode pane. For a + # mid-function target with the decompiler active, resolve the address to + # its pseudocode line (via the per-line /*0xEA*/ markers) so the jump + # lands on the reference there too (e.g. selecting an xref). A plain + # function-entry jump is line 0 in both views -> skip the decompile. + dec_idx = -1 + if self._active == "decomp" and ea != fn.addr: + dec_idx = self._decomp_line_for(fn.addr, ea) self.app.call_from_thread(self._open_at, fn.addr, fn.name, idx, push, dec_idx) def _decomp_line_for(self, fn_addr: int, ea: int) -> int: -- cgit v1.3.1-sl0p