AArch64 page loads and import-slot loads are shown through what uses them, but skipping them also skipped forgetting what their destination held, so movz x9; adrp x9; movk x9 folded the MOVK with a constant the page load had replaced, and an argument register reloaded by adrp could show its old value. Those loads now forget every register they write.
mov w9, #0x2493 followed by movk w9, #0x9249, lsl #16 now lifts to pseudo-C as the one constant it builds (w9 = 0x92492493;) instead of two statements, through a full 64-bit chain of MOVKs too; a W pair stays 32-bit, and the two statements stay when anything reads or writes the register between them.
A register-offset AArch64 memory operand such as ldr w0, [x1, w2, sxtw #2] now keeps its index at its written width with its extension or shift, so pseudo-C shows the sign-extended index ((int64_t)(int32_t)w2 << 2) instead of a plain unsigned x2 * 4. An unchanged index stays plain, and x86 scaled indices render as before.
Shifted-register operands lost their shift and extended registers their extension, so add w9, w10, w9, lsr #31 read as w9 = w10 + w9; and sub w9, w9, w9, lsl #3 as w9 -= w9; (#1725). Operands now carry a shift or extension (LSL, LSR, ASR, ROR and the eight extensions), dropped only when it changes nothing, and pseudo-C spells out what C needs, such as ((uint32_t)w9 >> 31) and sign or zero extension before a shift.
MOVK replaces 16 bits and keeps the rest, but lifted as a whole move (mov w9, #0x2493; movk w9, #0x9249, lsl #16 read as w9 = 0x92490000;), and MOVN's value is the inverted immediate but lifted as the immediate (mov w0, #-1 read as w0 = 0;) (#1724). MOVK now decodes as an insert carrying the shifted immediate and the mask of the bits kept, printed as w9 = (w9 & 0xffff) | 0x92490000;, and MOVN carries the inverted value, shown for a W register as the signed value the assembler shows.
mov xd, xm and mov wd, #bitmask are ORR from the zero register, and the lifter took the zero register as the value moved, so mov x19, x0 read as x19 = xzr; and a loop then read from address 0 (#1723). The A64 decoder now recognises the ORR form of mov from its operands, with or without formatted text, and keeps only the destination and the moved value; pseudo-C prints x19 = x0; and constant tracking follows a known value through the move. A shifted source or a real first source is still an ORR.
The AArch64 address tracker kept an old value after an addition with an unknown register, read unknown memory indices as zero, could keep a stale base after a load with writeback or a stale link register after a call, and did W-register additions in 64 bits, so stale values could name a later indirect call as an import its instructions didn't establish. Address facts are now kept only when the operands prove them: unknown addends and indices clear the result, W additions wrap at 32 bits, every register an instruction writes is forgotten before new facts are recorded, and calls clear the link register too.
With FEAT_PAuth_LR and PSTATE.PACM set, RETAA and RETAB use x16 as an extra modifier. The decoder knows neither the CPU's features nor PSTATE, so authenticated returns now also record a possible read of x16, beside their link register and stack pointer, and value flow keeps that input.
A native function can branch to a body block placed before its entry address. The control-flow graph already included that block, but reference and string scans only looked from the entry onward, and parameter inference took the lowest-address block as the entry, so a register set by the real entry could become a false parameter while the real input disappeared. Reference scans now cover the address range of all of the function's body blocks, and parameters are read from the block at the function's actual entry.
The AArch64 decoder drops XZR and WZR from the register list, so for an ordinary arithmetic instruction whose result is discarded, the first remaining source register was marked as written. That false write broke reaching definitions and could erase a proven import-slot base before a later load and call. The discarded-destination rule, which covered only flag-setting instructions, now applies to ordinary arithmetic too, so those registers stay inputs.
Ordinary AArch64 returns treated the selected target register as a destination and unconditionally read `x30`, even for `ret x19`. Authenticated branches and calls had correct control-flow categories but fell through the generic operand-write rule, which overwrote their target's reaching definition. Authenticated returns also omitted their stack-pointer input.
The value-flow graph decoded every instruction of every block and only then applied its node limit, so a huge function did all that work before most of it was thrown away. The node budget is now spent as nodes are made: parameters first, then instructions, and decoding stops once it runs out. Blocks that weren't decoded in full are tracked so their edges and definitions aren't treated as complete, and the graph is marked truncated.
AArch64 exclusive stores treated their status result as an input and never defined it, exclusive pair loads defined only their first result, and acquire-exclusive single loads were unknown operations. The value-flow graph lost the status edge into a retry loop's condition and the second loaded value, and pseudo-C could show an exclusive store as an assignment from its status register, or drop an exclusive load from a known import slot. Exclusive stores now write their status (unless it's discarded to WZR) and read their values, exclusive and acquire-exclusive loads are loads, pair forms define both results, and pseudo-C keeps them as memory operations.
In a stripped program, an unconditional jump to code below a function's entry that the function hasn't reached otherwise is a tail call to a function of its own (such as frame_dummy jumping to register_tm_clones), instead of pulling that code into the caller.
ARM32 and Thumb loads and stores keep their memory operands, so pseudo-C shows r0 = *(uint32_t*)(r1 + 4); instead of r0 = 0;; write-back and shifted or subtracted index forms are shown as written. Fixes#277.
ARM and Thumb branches, BL/BLX calls and CBZ/CBNZ point at the targets llvm-objdump reports, so Thumb calls no longer land four bytes early. Fixes#250.
ELF files whose section headers were removed (common in NAS and router firmware) now show their functions, imports and exports. The dynamic symbol table is found through PT_DYNAMIC (DT_SYMTAB/DT_STRTAB, counted from DT_HASH, then DT_GNU_HASH, then an estimate with a warning), shared with the Flutter reader. The prologue scan walks executable segments when there are no sections.
Fixes#223
An A32 LDRD/STRD with Rt=15 (e.g. 0xc0c7fef3) made the decoder library panic on the nonexistent r16; such a word now decodes as no instruction, before the library sees it.
The PLT, prologue and pointer scans in disasm/program.rs use checked steps, so code near u64::MAX no longer wraps to 0 and walks the whole address space. Adds open roadmap lines for an A32 STRD/LDRD decoder panic and unchecked header offsets in dart.rs.
A native, pure-Rust app that shows anyone how a piece of software works, with
evidence-backed answers, then helps them rebuild it. It ships a desktop app, a
CLI and an MCP server, all driven by one engine.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>