Repository navigation
[AUTOMATED] fix(p5): a constant used as a number is not the function that sits at that address - #694
Merged
Merged
Conversation
…code address can appear inferfuncentry lifts ActionConstantPtr's bit_transitions<3 guard for any constant that resolves to an exact function entry, whatever the operand means. A round buffer size in a PIE lands on one: coreutils tail -O0 bounds a byte count by BUFSIZ 0x2000, which is _DT_INIT. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
…scape narrowing Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
… as a number The opcode alone cannot separate MIN (n, BUFSIZ) from a function-pointer table: both assign the constant with a plain COPY. What separates them is that the function orders the one value and never orders the other, so the escape now also asks whether this numeric value is read as a number anywhere in the function. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
…e narrowing Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
The strict/non-strict rewrite moves an ordering comparison's literal by one before this pass sees it, so the same MIN (n, BUFSIZ) arrives as INT_LESS(0x2000, n) in coreutils tail and INT_LESS(0x2001, n) in head. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
…rrowing Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
Both arms re-run on the rebased tree: the numbers are unchanged. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
force-pushed
the
fix/ptrfromuseint
branch
from
September 20, 2026 15:27
bbaa7b8 to
e6ffa41
Compare
mahaloz
added a commit
that referenced
this pull request
Sep 20, 2026
main gained a stages file in #694; the baseline is re-recorded rather than hand-merged, so the six LIBCTYPES assertions this branch adds land on top of 1,254 and nothing else moves. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 20, 2026
… collides with The corpus file count in kuna-base/src/xml.rs is the silent-auto-merge case: main and this branch both moved 322 -> 323 for different stage tests, so the textual merge kept 323 and lost one. Re-derived to 324, and docs/baseline-stages.json re-recorded rather than hand-merged (1,254 -> 1,261, seven additive charptr rows). Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 20, 2026
Third full run of both arms, this time at 69d252d. The perfect counts, the improved/worse split and every per-variable table are unchanged; only the pooled mean moves, 0.3403 -> 0.3405 off and 0.3417 -> 0.3419 on, which is #694 lifting both arms alike. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 20, 2026
main gained a stages file in #694; the baseline is re-recorded rather than hand-merged, so the six LIBCTYPES assertions this branch adds land on top of 1,254 and nothing else moves. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 20, 2026
Third full run of both arms, this time at 69d252d. The perfect counts, the improved/worse split and every per-variable table are unchanged; only the pooled mean moves, 0.3403 -> 0.3405 off and 0.3417 -> 0.3419 on, which is #694 lifting both arms alike. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
pushed a commit
that referenced
this pull request
Sep 20, 2026
…ecord the re-run sweep The option's catalog text gained the reversal-class cost sentence, so tests/fixtures/phase_catalog.json is recaptured. The 444-slice sweep was re-run on the rebased tree with the loader fix in: the option's 24 moved rows are byte-identical, and the base aggregate moved only by #694's own published delta. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 21, 2026
Third full run of both arms, this time at 69d252d. The perfect counts, the improved/worse split and every per-variable table are unchanged; only the pooled mean moves, 0.3403 -> 0.3405 off and 0.3417 -> 0.3419 on, which is #694 lifting both arms alike. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
pushed a commit
that referenced
this pull request
Sep 21, 2026
…ecord the re-run sweep The option's catalog text gained the reversal-class cost sentence, so tests/fixtures/phase_catalog.json is recaptured. The 444-slice sweep was re-run on the rebased tree with the loader fix in: the option's 24 moved rows are byte-identical, and the base aggregate moved only by #694's own published delta. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 21, 2026
Third full run of both arms, this time at 69d252d. The perfect counts, the improved/worse split and every per-variable table are unchanged; only the pooled mean moves, 0.3403 -> 0.3405 off and 0.3417 -> 0.3419 on, which is #694 lifting both arms alike. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
pushed a commit
that referenced
this pull request
Sep 21, 2026
…ecord the re-run sweep The option's catalog text gained the reversal-class cost sentence, so tests/fixtures/phase_catalog.json is recaptured. The 444-slice sweep was re-run on the rebased tree with the loader fix in: the option's 24 moved rows are byte-identical, and the base aggregate moved only by #694's own published delta. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 21, 2026
Third full run of both arms, this time at 69d252d. The perfect counts, the improved/worse split and every per-variable table are unchanged; only the pooled mean moves, 0.3403 -> 0.3405 off and 0.3417 -> 0.3419 on, which is #694 lifting both arms alike. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 21, 2026
Third full run of both arms, this time at 69d252d. The perfect counts, the improved/worse split and every per-variable table are unchanged; only the pooled mean moves, 0.3403 -> 0.3405 off and 0.3417 -> 0.3419 on, which is #694 lifting both arms alike. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG
mahaloz
added a commit
that referenced
this pull request
Sep 21, 2026
* [AUTOMATED] wip(analysis): libctypes second round of named libc structs Mined the libc/POSIX-named ptr_struct ground-truth pool from the DWARF twins of the 444-slice corpus and added the slots that pay. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] wip(analysis): obstack fixture, stage passes 11-12, unit tests Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] wip: spec prose, phases.toml summary, options.md, stages baseline Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] wip: probe/test fixtures repointed, feature bundle analysis+plan Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] wip: re-capture phase_catalog fixture, move the ghidra-sim C-line pins Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] wip: feature record.json Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] wip: refresh the module header for the second round Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): cite the twin's debug info for the nl witness Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): record the export compile-error cost Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): tidy the unreachable half of the ranked pool Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): list every newly-wrong row Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): the speed block and the gate results Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): the quieter-moment speed confirmation Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] fix(analysis): the obstack size slots follow the channel, not the corpus gnulib's copy of obstack.c declares its size type size_t; the installed glibc header declares int. The table asserted size_t for both, so an image that IMPORTS _obstack_begin/_obstack_newchunk from glibc (the five dpkg programs at each optimization level, 15 slices of the same results tree) got a false declaration, and the caller of a two-line glibc-obstack program went from `void f(int n)` to `void f(unsigned int n)` with two inserted casts. Split the channel: LIBC_DEFINED_NAMED (size_t) is seeded only from the names the image defines and does not also import, LIBC_IMPORTED_OBSTACK (int) from the import channel by name and by resolver address. Corrects the module and spec prose that claimed obstack is never an import. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): the gzip row in full, and the two obstack channels The single worse typesweep row said "a by-value struct stat local that becomes a byte blob". What it actually is: char v5 [80] handed to an lstat that writes 144 bytes, with st_atim/st_mtim detached into locals the body reads and nothing writes. State that, say what causes it (the timespec * slot on utimensat/futimens -- reverting those two slots brings stat v5 back), and record the measurement it is kept on: over the 30 corpus slices that import either name, 122 functions gain a timespec rendering and this is the only new under-declared stat, against 7 that main already prints in those same slices. Also: rebased onto argclobber (#689), stages baseline re-recorded, PR body cut under a screen, and the statfs/export redeclaration noted beside the option's documented export cost. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] test(stages): pin the imported obstack channel end to end libctypes_obstack_import_x86_64 is the twin of the existing obstack fixture on the other channel: _obstack_newchunk imported from glibc rather than linked in from gnulib. Two assertions, off and on, pin `void grow_import(obstack *a0,int4 a1)` against #28's `uint8` -- a table that spelled both channels the same fails one of them. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): re-measure on the rebased base The 444-slice typesweep was run again in full after the rebase onto argclobber (#689), base arm built from origin/main's kuna_libctypes.rs + protos/mod.rs in this tree. Identical to the first run down to the per-variable tables: 1,349 -> 1,353 perfect, mean .3403 -> .3417, 147 newly correct / 6 newly wrong, 91 improved / 1 worse. Also completes the newly-correct breakdown, which was listing 139 of the 147. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): the channel split's load cost min-of-9 interleaved `kuna functions` over -O2 tar: 0.144s before the extra defined-name walk, 0.142s after. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] style(analysis): shorten the inline note at the obstack seam Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): the channel split's blast radius decompile-all over five whole binaries, the two builds differing only by the split: grep/tar/ls/gzip byte-identical, dpkg-query moves 7 lines. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] style(analysis): present-name set is module-private again Nothing outside protos/mod.rs reads it now that the obstack seam takes the defined-name set. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): disclose the sigaction frame split The `sigfillset(sigset_t *)` slot gives the `sa_mask` sub-object its own identity, so a 152-byte `sigaction` frame slot splits at 136 and the `sa_flags` store lands outside the object handed to `sigaction()`. Measured by ablating that one table row: no `sigaction` declaration moves anywhere in the 444 scored slices (6 of them import `sigfillset`), and in a disjoint openssh -O2 sweep exactly one function per binary changes, all of them `ssh_signal`. The shape already ships through `sigemptyset`, which prints the identical split on the ablated build. Also records the `statfs` name collision as it appears in plain `decompile-all`, not only in a project export. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): the sigaction repro in full The mitigation claim is only checkable with the program it was measured on. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): re-measure the typesweep on the new base Third full run of both arms, this time at 69d252d. The perfect counts, the improved/worse split and every per-variable table are unchanged; only the pooled mean moves, 0.3403 -> 0.3405 off and 0.3417 -> 0.3419 on, which is #694 lifting both arms alike. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): the utmp rows measured, the 32-bit size limit, the re-derived fixture swap Adds three sections to the feature analysis: the utmp/utmpx rows reaching a caller's own local on who/logoutd/runlevel (they ship on a pool count, not a sweep delta, and this is what they buy); the table's sizes being glibc x86-64 with nothing scaling them by word size, and what that is confined to; and the export fixture swap re-derived under #693's callee-first schedule. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): record the rebase onto the callee-first export The gate block now names the base it was run on, and a new section records how the two repointed fixtures were re-derived under that schedule, the nine-binary `libctypes off` identity against a build of the new base, and why the type sweep did not need re-running (`decompile-all --json` is byte-identical between the two bases). The timespec rows are recorded as a decision rather than a disclosure. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] docs(libcstructs): the workspace suite result on the rebased tree Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG * [AUTOMATED] feat(analysis): drop the sigfillset row from libctypes It splits a struct sigaction frame slot in openssh's ssh_signal and buys nothing in the mined pool. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] feat(analysis): drop the two-element time slots and the sigset_t sub-object rows utimensat/futimens/utimes/futimesat take a two-element array; naming one element shrinks the caller's frame object (gzip lutimens reads a stat tail nothing writes; scp/sftp hand utimes 16 of 32 bytes). sigsuspend, pthread_sigmask, sigdelset, sigismember and sigwait split a struct sigaction local when handed &sa.sa_mask. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] docs(libcstructs): the spec and option row say which slots are left out and why Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] docs(libcstructs): round-5 measurements, the dropped rows, off-pool notes for every kept row Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] docs(libcstructs): the frame checker, the sigset_t repro and the 15-binary hunk classification Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] docs(libcstructs): record.json for round 5 Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] test(analysis): the frame-splitting slots stay out of the libctypes tables Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] chore(libcstructs): re-derive counts and generated files after rebase Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] docs(libcstructs): round-5 speed block and the gates on the rebased tree Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL * [AUTOMATED] docs(libcstructs): the gates on the #703-rebased tree Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017ei9zqc7XHgZdMAzrk8jAL --------- Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The problem
A round buffer size that happens to land on a function entry is printed as that
function, and everything it touches becomes a pointer. coreutils
tailbounds abyte count by
BUFSIZ;BUFSIZis0x2000, and0x2000is where.initstarts in a PIE, so
MIN (n_remaining, BUFSIZ)comes out as a comparison against_DT_INITanduintmax_t n_bytescomes out asvoid *:a3isuintmax_t n_bytesandv9isuintmax_t n_remaining, so thesubtraction is byte arithmetic, not pointer arithmetic.
protoorderthen handsthe
void *to every caller:tail_forever'suintmax_t bytes_to_readis avoid *for the same reason.head,seqandodhave it too.The fix
inferfuncentrylifts thebit_transitions < 3guard — the only thing keepinginteger flags, masks and round sizes out of the symbol table — for a constant
that resolves to an exact function entry. It now lifts it only where the
constant is being used as an address.
a multiply, a divide, a remainder or a shift.
MINis a plainCOPY and so is every entry of a function-pointer table —
od'sdecode_one_formatpicks betweensub_3f20,sub_3ff0,sub_40a0andsub_4150, and0x3ff0is the one of the four the guard would have caught.What separates them is that the function orders the one value and never orders
the other, so a value read as a number anywhere disqualifies it everywhere.
The set is built once per pass from the constant snapshot
apply()alreadytakes.
rewrite moves the bound by one, so the same
MINarrives asINT_LESS(0x2000, n)intailandINT_LESS(0x2001, n)inhead.The tests
tests/stages/kuna-inferfuncentry-intbound.xmlputshandlerat0x100000andasks four questions of it: a bound that lands on it stays a number (fails before
the fix —
code * bound(code *a0)returninghandler), GH-6930's callbackargument still prints the name, a COPY of the same address in a body that never
orders it still prints the name, and
option inferfuncentry offis stillupstream. Five unit tests on the two predicates.
444-slice typesweep (coreutils grep gzip diffutils bzip2 findutils tar shadow,
O0/O2/O2-noinline): perfect 1349 = 1349, aggregate 3657.76 → 3659.62, 13
functions improved, 0 worse. Whole-binary
decompile-allbefore/after over 16builds and 6,882 functions: 18 functions changed, every hunk read, no statement
moved or deleted. Speed within noise (worst credible +1.79%);
gzip -O2measured+7.1% and then −7.1%, so the effect is under this box's floor.
🤖 Generated with Claude Code
https://claude.ai/code/session_01YFCA715QE6ZBSnTn7bwabG