mirror of
https://github.com/Druthulu/BFM-decomp
synced 2026-09-30 15:36:55 -04:00
phase-36: S104 s104_e35 — func_801A3594 banked at 0 through the whole-object gate + propagated — 2 pins → 0: per-case tw with the test + copy sunk into the case (cse.c:4836-4870; local-alloc.c:1486-1500)
This commit is contained in:
@@ -1,35 +1,40 @@
|
||||
s32 func_801A3594(void *a0) {
|
||||
s16 buf[12];
|
||||
u16 b;
|
||||
u16 a;
|
||||
s16 diff;
|
||||
s16 v1;
|
||||
s32 tw;
|
||||
s16 t16;
|
||||
s16 xr;
|
||||
|
||||
v1 = *(s16 *)((s32)a0 + 0x106);
|
||||
switch (v1) {
|
||||
case 0:
|
||||
a = *(u16 *)((s32)a0 + 0xE8);
|
||||
b = *(u16 *)((s32)a0 + 0x6);
|
||||
diff = a - b;
|
||||
case 0: {
|
||||
s32 tw;
|
||||
|
||||
diff = *(u16 *)((s32)a0 + 0xE8) - *(u16 *)((s32)a0 + 0x6);
|
||||
buf[0] = diff;
|
||||
tw = *(s16 *)((s32)a0 + 0xEC);
|
||||
t16 = tw;
|
||||
if (tw == 0) {
|
||||
return 1;
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
a = *(u16 *)((s32)a0 + 0xEA);
|
||||
b = *(u16 *)((s32)a0 + 0xE);
|
||||
diff = a - b;
|
||||
}
|
||||
case 1: {
|
||||
s32 tw;
|
||||
|
||||
diff = *(u16 *)((s32)a0 + 0xEA) - *(u16 *)((s32)a0 + 0xE);
|
||||
buf[1] = diff;
|
||||
tw = *(s16 *)((s32)a0 + 0xEE);
|
||||
t16 = tw;
|
||||
if (tw == 0) {
|
||||
return 1;
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
goto default_case;
|
||||
}
|
||||
|
||||
if (tw == 0) goto ret1;
|
||||
t16 = tw;
|
||||
if (diff == 0) goto ret1;
|
||||
xr = diff ^ t16;
|
||||
if (xr >= 0) goto default_case;
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
# func_801A3594 (md_SC07_004) — P36 S104 agent e35 — score 11 (lever-free; sweep best 7) -> 0, ZERO levers (was 2 pins: `$3` on b, `$2` on tw)
|
||||
|
||||
(a) Residual: 35 vs 36 ins. Lever-free, the SI->HI copy `t16 = tw` vanishes (the `xor` reads `tw` itself, which therefore
|
||||
lands in `$a0`, the target's `move a0,v0` in the `beqz` delay slot is missing), and under it `a`/`b` are swapped
|
||||
(`lhu v1/v0; subu v1,v1,v0` vs the target's `lhu v0/v1; subu v1,v0,v1`).
|
||||
|
||||
(b) Pass and decision — the SAME class agent e30 closed in ov_SC04_011 (`func_801836D4`, its mechanism.md), re-read on this
|
||||
body's free dump (`scratch/dumps_free/`):
|
||||
- The copy `(set (reg/v:HI 78) (subreg:HI (reg/v:SI 77) 0))` (free.i.rtl insn 85) and the `xor`'s read
|
||||
`(subreg:SI (reg:HI 78))` sit in ONE cse block (label 76 .. jump 102). `fold_rtx`'s SUBREG case (`cse.c:4836-4870`,
|
||||
"these SUBREGs just say how to treat the register") finds 78 equivalent to `(subreg:HI 77)` whose inner mode is SI and
|
||||
returns 77: free.i.cse insn 95 is `(xor:SI (subreg:SI (reg/v:HI 75) 0) (reg/v:SI 77))`, 78 is dead, `tw` lives to the
|
||||
xor. (`make_regs_eqv`, `cse.c:846-862`, is the same-mode-copy version of this; an `s32 t16` scores 11 too.)
|
||||
- With the copy AND the `tw == 0` test moved INTO each case (a case-local `s32 tw`), the copy is in the case block and the
|
||||
`xor` in the join block — a new cse block, so no equivalence is available and the copy stays. The three-quantity
|
||||
block (a, b, tw local to the case, `local-alloc.c:1486-1500`, hand-written order, compares 0/1, 1/2, 0/1) puts `a` in
|
||||
`v0` and `b` in `v1`; the two case tails (`beqz v0; move a0,v0`) are merged by the post-reload cross-jump
|
||||
(`jump.c:2371`) into the one the target has. Proven on bytes (`--try` 0, 36/36); the cse fold proven on the free dump.
|
||||
|
||||
(c) Moves (joint; body.c = scratch/p/p1.c, score 0):
|
||||
1. `s32 tw` declared inside each `case N: { ... }` block; `t16 = tw; if (tw == 0) return 1;` sunk into the case (copy
|
||||
BEFORE the test, as e30 found); the join keeps `if (diff == 0) goto ret1; xr = diff ^ t16; if (xr >= 0) goto default_case;`
|
||||
2. `a`, `b` inlined into the subtraction (`diff = *(u16 *)(a0 + 0xE8) - *(u16 *)(a0 + 0x6);`) — the pins deleted.
|
||||
Named case-local `u16 a; u16 b;` also scores 0 (scratch/p/p2.c).
|
||||
3. `s16 buf[12]` kept: the frame is exactly the array (buf[2] -> frame 8, buf[8] -> 16, both score 2 on the two `addiu sp`
|
||||
only); no orphan pseudo pads it (`.lreg`: every temp holds a hard register). 24 bytes = the tree's declaration.
|
||||
|
||||
(d) GENERATOR PROPOSAL: e30's rule, now confirmed on a second body: when a `switch` whose cases each load a value that is
|
||||
tested after the join leaves a `move aK,vN` copy missing (`lh vN; ... join: beqz vN; move aK,vN`), sink the join test and the
|
||||
narrowing copy INTO every case on a case-local variable (`{ s32 v = LOAD; keep = v; if (v == 0) return 1; } break;`) —
|
||||
the copy leaves cse's block, cross-jump re-merges the tails after reload, and the extra case quantity flips local-alloc's
|
||||
3-quantity order. Before any of that: grep `src/` for the same statement shape in other overlays (`xr = diff ^ t16`) —
|
||||
the answer was banked in `.run/P36/agents/ov_SC04_011__func_801836D4/`.
|
||||
|
||||
(e) Did NOT work: a/b load order swapped (v1: 9, count still wrong), a/b per-case or inlined with the tail unchanged
|
||||
(v4/v5: 9), `s16 tw` (cI: 11 — `lhu` + a direct HI test, `combine.c:simplify_comparison` strips the sign_extend, no `lh`),
|
||||
`s32 t16`/`u16 t16`/`s32 xr`/the copy before the test/`(s16)(diff ^ tw)` (cA-cH: 11, the fold or `make_regs_eqv` every
|
||||
time), `s16 tw` + `s32 t16` (cD: 17). The free sweep's best 7 (R2/R4 decl moves, R7 do-while) never moved the copy out
|
||||
of the cse block.
|
||||
|
||||
(f) Method gap: METHOD step 12's "grep the WHOLE src/ for the shape" found the close in one `--try` — but only after I had
|
||||
read the compiler for an hour (combine.c:1882's load+copy split was a plausible but wrong route: it needs a single-set HI
|
||||
reg, and a two-case `switch` sets it twice). The residual-first order is right; "grep the shape across overlays" should be
|
||||
step 0b, before the dumps. Also: the pack's `related.txt` was EMPTY for this function although a same-shape sibling with a
|
||||
closed mechanism existed in another overlay — related.txt should search by statement shape, not by name.
|
||||
|
||||
(g) Structs: NO for the lever — the decision is cse's SUBREG fold over scalar locals and block layout; no memory-ordering
|
||||
question. `a0` is an actor with a target position at 0xE8/0xEA, a direction at 0xEC/0xEE, an axis selector at 0x106 and a
|
||||
position at 0x6/0xE (same layout e30 described for ov_SC04_011); with arrays (`o->tgt[axis]`, `o->dir[axis]`) the switch
|
||||
could collapse to one indexed body, but the target has a real 2-way switch. Not tested (nothing left to close).
|
||||
|
||||
(h) Joint check (e35): all four e35 body.c files spliced into one copy of the tree TU with the four `extern void func_801A395C`
|
||||
turned into `extern s32` (`md_SC07_004__func_801A3594/scratch/joint.py` -> `scratch/joint_tu.c`, object `scratch/joint.o`):
|
||||
each of the four scores 0 through `--try` (whole-TU), and the object's `.text` (sha1 ad583f4dfb0c), `.rodata`, `.data`/`.sdata`/
|
||||
`.bss`, relocations and symbol table are identical to the baseline snapshot; the only difference is the source-path string.
|
||||
Gotcha for the next agent: a splice regex `^[^\n;]*\bfn\([^;{]*\)\s*\{` also matches a CALL line ending in `{`
|
||||
(`if (func_801A3594(...)) {` at :2061) — anchor the definition at column 0 (`^[A-Za-z_]`).
|
||||
@@ -0,0 +1,25 @@
|
||||
s32 func_801A395C(s32 a0, s32 a1) {
|
||||
s16 cur;
|
||||
s32 overshot;
|
||||
s16 t;
|
||||
|
||||
t = a1;
|
||||
cur = *(s16 *)(a0 + 0xA);
|
||||
if (cur == t) {
|
||||
return 1;
|
||||
}
|
||||
if (t < cur) {
|
||||
cur -= 2;
|
||||
*(s16 *)(a0 + 0xA) = cur;
|
||||
overshot = t < cur;
|
||||
} else {
|
||||
cur += 2;
|
||||
*(s16 *)(a0 + 0xA) = cur;
|
||||
overshot = cur < t;
|
||||
}
|
||||
if (overshot) {
|
||||
return 0;
|
||||
}
|
||||
*(s16 *)(a0 + 0xA) = t;
|
||||
return 1;
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
void func_801A395C(s32 a0, s32 a1) {
|
||||
s32 ret;
|
||||
s16 cur;
|
||||
s16 t;
|
||||
s32 overshot;
|
||||
|
||||
t = (s16)a1;
|
||||
cur = *(s16 *)(a0 + 0xA);
|
||||
if (cur == t) {
|
||||
__asm__ __volatile__(""); // !FAKE: barrier — NEEDED DIFFERS (P36 rung B tus9)
|
||||
ret = 1;
|
||||
} else {
|
||||
if (t < cur) {
|
||||
cur -= 2;
|
||||
*(s16 *)(a0 + 0xA) = cur;
|
||||
overshot = (t < cur);
|
||||
} else {
|
||||
cur += 2;
|
||||
*(s16 *)(a0 + 0xA) = cur;
|
||||
overshot = (cur < t);
|
||||
}
|
||||
if (overshot) {
|
||||
ret = 0;
|
||||
} else {
|
||||
*(s16 *)(a0 + 0xA) = t;
|
||||
ret = 1;
|
||||
}
|
||||
}
|
||||
__asm__ __volatile__("" :: "r"(ret)); // !FAKE: keepalive — NEEDED DIFFERS (P36 rung B tus9)
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,62 @@
|
||||
# func_801A395C (md_SC07_004) — P36 S104 agent e35 — score 7 (lever-free) -> 0 in plain C, ZERO levers, but a SIGNATURE change (void -> s32): PARKED (d29 class)
|
||||
|
||||
(a) Residual: 26 vs 29 ins. The target RETURNS a value: `li v0,1` on the `cur == t` path (its own `j epilogue; li v0,1`),
|
||||
`move v0,zero` in the `bnez` slot and `li v0,1` after the final `sh` — every caller in the TU already casts the function to
|
||||
`s32 (*)(s32, s32)` (lines 1122, 1617, 2339) and the tree's `extern` at :1482 says "real sig returns s32". The tree faked
|
||||
the value with a `"r"(ret)` keepalive plus a barrier that kept the two `ret = 1` apart. Lever-free and `void`, `ret` is dead
|
||||
and the three value insns vanish.
|
||||
|
||||
(b) Pass and decision (dumps `scratch/dumps_C/` = the close, `scratch/dumps_s1/` = the 4):
|
||||
- With `s32` and early returns, jump1's block swap (`jump.c:1800-1870`, "Look for if (foo) bar; else break;") fires on
|
||||
`if (overshot) return 0;`: the condjump's label is used once, range1 (`v0 = 0; j Lend`) ends in a simple jump to
|
||||
label2 = Lend, and range2 (`sh; v0 = 1; j Lend`) ends in a jump + barrier, so `invert_jump` and the two ranges are
|
||||
exchanged — the `return 1` block now falls through to Lend and the `return 0` block (`move v0,zero`) is the LAST insn
|
||||
before the return label (C.i.jump: 87 -> 96, `99 sh; 102 li; 104 j 424; L423: 91 move v0,0; L424`).
|
||||
- Therefore jump2's cross-jump (`find_cross_jump`, `jump.c:2371`) finds no match for the equality path's `li v0,1; j Lend`
|
||||
(i2 = `move v0,zero` != `li v0,1`), the block stays, and reorg fills the `j`'s slot with the block's own preceding
|
||||
`li v0,1` (C.i.dbr insn 123: `sequence [jump 29 -> 112, insn 27 v0 = 1]`), and the `return 0` block's `move v0,zero`
|
||||
goes into the `bnez` slot — the target's `bnez v0,epilogue; move v0,zero` / `j epilogue; li v0,1`.
|
||||
- With `return 0` INSIDE each arm (s1, score 4) the swap condition fails (`JUMP_LABEL (range1end) == label2` is false —
|
||||
the label after the skipped `return 0` is the arm's join, not Lend), the final block is `sh; li v0,1`, cross-jump merges
|
||||
the equality path's `li v0,1` into it and the condjump is inverted to `beq v0,a1,<li>` (mine).
|
||||
- `move a2,a1` / `sh a2,10(a0)`: the parameter's raw copy is what the final store writes (its low half is `t` anyway);
|
||||
`= t` and `= a1` both score 0 (C_p32_t, D_p32_a1). A `(s16)a1` cast at each use instead of the `t` local scores 12/13 —
|
||||
the sign-extension is then re-done per use.
|
||||
All claims proven on bytes (whole-TU `--try` 0, 29/29: `scratch/w/C_p32_t_tu.c`, also `D_p32_t_tu.c`, `D_p32_a1_tu.c`).
|
||||
|
||||
(c) Moves (body.c = scratch/w/C_p32_t.c):
|
||||
1. `void` -> `s32`; `ret` deleted; `return 1;` on `cur == t`, `if (overshot) return 0;`, final `*(s16 *)(a0 + 0xA) = t; return 1;`
|
||||
(the tree's `overshot` flag kept — it is what puts the `return 0` in one block after the if/else);
|
||||
2. the barrier and the keepalive deleted; `t = a1` (the `(s16)` cast on an `s16` local is implicit).
|
||||
3. A `D` shape (each arm ends `*(s16 *)(a0 + 0xA) = t; return 1;`, no `overshot`) also scores 0 — cross-jump merges the
|
||||
duplicated tails back. `body_tu_s32.c` = the whole TU with the four `extern void func_801A395C` turned into `extern s32`
|
||||
(the casts at the three call sites can then go) — this is the file that scores 0 with `--try` (no `--body`).
|
||||
|
||||
(d) GENERATOR PROPOSAL: when a `void` body ends with a `"r"(ret)` keepalive and the residual's missing insns are
|
||||
`li v0,K` / `move v0,zero` on return paths, the function RETURNS `ret`: emit the `s32` signature with the TU's `extern`s
|
||||
changed and `return` at each `ret = K` (the R-d29 rule); then, when the equality path's `li v0,1; j` is still merged, put
|
||||
the last `return 0` in ONE block AFTER the if/else (a flag tested once) so jump1's range swap (`jump.c:1800-1870`) makes
|
||||
`return 0` the final block and cross-jump has nothing to merge.
|
||||
|
||||
(e) Did NOT work: every `void` spelling (the free sweep's 190 compiles, all 7; a keepalive-only body `ml/m1.c` 4 — the
|
||||
barrier is needed too, so the tree's two levers are the minimum for `void`: `body_minlever.c` = the tree's body);
|
||||
`s16 a1` parameter (compile error against the TU's `extern`s — not tried further, the `move a2,a1` says the raw parameter
|
||||
is kept anyway); `(s16)a1` at each use (12-13); `return 0` inside the arms (A/B/E shapes: 4).
|
||||
|
||||
(f) Method gap: none — d29 named the class exactly ("a `void` function whose last statement is a keepalive of `v0` RETURNS
|
||||
it"). The one new fact is the block-swap rule that decides whether the equality path keeps its own `li v0,1`
|
||||
(`jump.c:1800`), which no generator can reach because it depends on WHERE the `return 0` sits relative to the if/else.
|
||||
`--try --body` cannot score a signature change (the file-scope `extern void` conflicts); whole-TU `--try` with the
|
||||
`extern`s rewritten does (`scratch/splice_sig.py`).
|
||||
|
||||
(g) Structs: NO — the decisions are jump1's block swap and jump2's cross-jump over the control flow; no memory access is
|
||||
involved in the lever. `a0` is an object whose `s16` at 0xA is an angle stepped by 2 toward the target `a1` (a
|
||||
`step_toward(s16 *field, s16 target)` shape); a struct type would read better (`o->ang`) and would not change the bytes
|
||||
(same `mem:HI`). Not tested.
|
||||
|
||||
(h) Joint check (e35): all four e35 body.c files spliced into one copy of the tree TU with the four `extern void func_801A395C`
|
||||
turned into `extern s32` (`md_SC07_004__func_801A3594/scratch/joint.py` -> `scratch/joint_tu.c`, object `scratch/joint.o`):
|
||||
each of the four scores 0 through `--try` (whole-TU), and the object's `.text` (sha1 ad583f4dfb0c), `.rodata`, `.data`/`.sdata`/
|
||||
`.bss`, relocations and symbol table are identical to the baseline snapshot; the only difference is the source-path string.
|
||||
Gotcha for the next agent: a splice regex `^[^\n;]*\bfn\([^;{]*\)\s*\{` also matches a CALL line ending in `{`
|
||||
(`if (func_801A3594(...)) {` at :2061) — anchor the definition at column 0 (`^[A-Za-z_]`).
|
||||
@@ -0,0 +1,122 @@
|
||||
void func_801A4ACC(void *a0)
|
||||
{
|
||||
s32 *s0;
|
||||
s32 s1;
|
||||
s32 v0;
|
||||
s32 v1;
|
||||
|
||||
s0 = (s32 *)a0;
|
||||
v1 = *(u16 *)((s32)s0 + 0x34);
|
||||
s1 = *(s32 *)((s32)s0 + 0xCC);
|
||||
if ((u32)v1 >= 5) {
|
||||
goto end;
|
||||
}
|
||||
|
||||
switch (v1) {
|
||||
case 0: {
|
||||
s32 *s2;
|
||||
|
||||
if (*(s16 *)((s32)s0 + 0x70) != 0) {
|
||||
goto end;
|
||||
}
|
||||
s2 = &D_801F8888;
|
||||
func_8013240C((s32)s2);
|
||||
if (s1 != 0) {
|
||||
func_8013240C((s32)&D_801F8898);
|
||||
}
|
||||
if ((*(u16 *)&D_801F888C | *(u16 *)&D_801F888E) != 0) {
|
||||
goto end;
|
||||
}
|
||||
func_80132288(s2, &D_801B00EC, D_801B75EC);
|
||||
if (s1 != 0) {
|
||||
func_80132288(&D_801F8898, &D_801B00FC, *(s32 *)D_801B80FC);
|
||||
}
|
||||
func_8002D4C8(4, 0xABE);
|
||||
goto inc;
|
||||
}
|
||||
case 1: {
|
||||
s32 *s2;
|
||||
|
||||
s2 = &D_801F8888;
|
||||
func_8013240C((s32)s2);
|
||||
if (s1 != 0) {
|
||||
func_8013240C((s32)&D_801F8898);
|
||||
}
|
||||
if ((D_801F8894 & 0x4000) == 0) {
|
||||
goto end;
|
||||
}
|
||||
func_80132288(s2, &D_801B010C, D_801B75EC);
|
||||
if (s1 != 0) {
|
||||
func_80132288(&D_801F8898, &D_801B011C, *(s32 *)D_801B80FC);
|
||||
}
|
||||
goto inc;
|
||||
}
|
||||
case 2: {
|
||||
s32 *s2;
|
||||
|
||||
s2 = &D_801F8888;
|
||||
func_8013240C((s32)s2);
|
||||
if (s1 != 0) {
|
||||
func_8013240C((s32)&D_801F8898);
|
||||
}
|
||||
if ((D_801F8894 & 0x4000) == 0) {
|
||||
goto end;
|
||||
}
|
||||
func_80132288(s2, &D_801B012C, D_801B75EC);
|
||||
if (s1 != 0) {
|
||||
func_80132288(&D_801F8898, &D_801B013C, *(s32 *)D_801B80FC);
|
||||
}
|
||||
}
|
||||
inc:
|
||||
*(u16 *)((s32)s0 + 0x34) += 1;
|
||||
goto end;
|
||||
case 3:
|
||||
func_8013240C((s32)&D_801F8888);
|
||||
if (s1 != 0) {
|
||||
func_8013240C((s32)&D_801F8898);
|
||||
}
|
||||
if ((D_801F8894 & 0x4000) == 0) {
|
||||
goto end;
|
||||
}
|
||||
v0 = *(u16 *)((s32)s0 + 0x34);
|
||||
v1 = *(s32 *)((s32)s0 + 0x6C);
|
||||
*(u16 *)((s32)s0 + 0x34) = v0 + 1;
|
||||
if (v1 == 0) {
|
||||
goto end;
|
||||
}
|
||||
*(u16 *)(v1 + 0x34) = 4;
|
||||
goto end;
|
||||
case 4:
|
||||
*(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x1A) -= 0x80;
|
||||
*(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x1C) = *(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x1A);
|
||||
if (*(s16 *)((s32)s0 + 0x70) != 0) {
|
||||
goto dec;
|
||||
}
|
||||
*(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x14) -= 0x10;
|
||||
*(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x18) = *(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x1A);
|
||||
if (*(s16 *)(*(s32 *)((s32)s0 + 0x20) + 0x1A) > 0) {
|
||||
goto end;
|
||||
}
|
||||
*(s32 *)(*(s32 *)((s32)s0 + 0x64) + 0xCC) = 0;
|
||||
if (s1 != 0) {
|
||||
func_8012C218((void *)s1);
|
||||
}
|
||||
func_8012C218((void *)s0);
|
||||
D_8019FF8A &= 0xFFFD;
|
||||
return;
|
||||
dec:
|
||||
*(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x14) += 0x10;
|
||||
*(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x18) = -*(u16 *)(*(s32 *)((s32)s0 + 0x20) + 0x1A);
|
||||
if (*(s16 *)(*(s32 *)((s32)s0 + 0x20) + 0x1A) > 0) {
|
||||
goto end;
|
||||
}
|
||||
if (s1 != 0) {
|
||||
func_8012C218((void *)s1);
|
||||
}
|
||||
func_8012C218((void *)s0);
|
||||
return;
|
||||
}
|
||||
|
||||
end:
|
||||
func_80132784((s32)s0, *(s32 *)((s32)s0 + 0x64), 0);
|
||||
}
|
||||
@@ -0,0 +1,48 @@
|
||||
# func_801A4ACC (md_SC07_004) — P36 S104 agent e35 — score 54 (lever-free; sweep best 24) -> 0, ZERO levers (was 2 pins: `$16` on the object, `$17` on the mirror)
|
||||
|
||||
(a) Residual: REG only (237/237), a rotation of the three callee-saved holders: object `$s1` (target `$s0`), mirror
|
||||
`$s2` (target `$s1`), the `&D_801F8888` pointer `$s0` (target `$s2`).
|
||||
|
||||
(b) Pass and decision (`tools/alloc_table.py free|c1 func_801A4ACC scratch/`):
|
||||
- Lever-free, `s2 = &D_801F8888` is ONE function-scope pseudo set in cases 0/1/2 (r75: 9 refs over a live length of 31,
|
||||
priority 8709) — it outranks the object (r73: 31 refs / 144, 8611) and the mirror (r74: 12 / 90, 4000), so
|
||||
`allocno_compare` (`global.c:594-610`) orders it first and `find_reg` (`global.c:945-990`) hands it the first
|
||||
callee-saved register `$s0`; the object then takes `$s1`, the mirror `$s2`.
|
||||
- With `s32 *s2` declared INSIDE each case block (METHOD d7), there are three pseudos of 3 refs each over ~20 insns
|
||||
(c1: r82 1363, r95 1500, r100 1500) — every one below the mirror's 4000 — so the order is object (`$s0`), mirror
|
||||
(`$s1`), and the three pointers, which do not conflict with each other, all land in `$s2`. The three per-case
|
||||
`lui s2; addiu s2` are the target's. Proven on bytes (`--try` 0, 237/237) and on the two tables.
|
||||
|
||||
(c) Moves:
|
||||
1. `s32 *s2;` moved from the function scope into `case 0: { … }`, `case 1: { … }`, `case 2: { … }` (scratch/c1.c — this ONE
|
||||
move alone closes it, 0); both pins deleted.
|
||||
2. Readability (body.c = scratch/c6.c, also 0): the decompiler temps `v0` (in the tests), `a0_`, `a1`, `a2` and the labels
|
||||
`cb4:`/`e58:` deleted — `if ((D_801F8894 & 0x4000) == 0) goto end;`, `if ((*(u16 *)&D_801F888C | *(u16 *)&D_801F888E) != 0)`,
|
||||
`func_8002D4C8(4, 0xABE)` direct, the case-1/2 mirror call written per case (`func_80132288(&D_801F8898, &D_801B011C,
|
||||
*(s32 *)D_801B80FC)` — post-reload cross-jump re-merges the tails as the target has them, `jump.c:2371`),
|
||||
`*(u16 *)((s32)s0 + 0x34) += 1`, case 4's field updates as compound assignments on the re-read `0x20` pointer,
|
||||
one `end: func_80132784((s32)s0, *(s32 *)((s32)s0 + 0x64), 0);`. Each intermediate step (c2–c5) scored 0 too.
|
||||
|
||||
(d) GENERATOR PROPOSAL (d7, confirmed again): when a REG residual rotates the callee-saved holders and the pseudo that
|
||||
takes `$s0` is a constant/address pointer SET IN SEVERAL switch cases and used only inside each, declare it inside each
|
||||
case — splitting an n-case variable into n per-case ones divides its refs by n (priority `floor_log2(refs)*refs/live`
|
||||
collapses) and the per-case pseudos share the last callee-saved register. Generators move declarations (R2/R4) but never
|
||||
split one declaration into per-arm ones.
|
||||
|
||||
(e) Did NOT work: the free sweep's 190 compiles (best 24: R6 inline `a0_`, which only re-routes the `$a0` temp — the
|
||||
callee-saved rotation stays), R2/R4 declaration moves (provably dead: the three priorities differ, `global.c:604-610`).
|
||||
|
||||
(f) Method gap: none — the allocation table named it in one read (r75 at 8709 vs r73 at 8611 vs r74 at 4000: the
|
||||
pointer must fall below 4000, so it must lose refs, i.e. be split). First `--try`.
|
||||
|
||||
(g) Structs: NO for the lever — global.c's priority arithmetic over a pointer pseudo; no memory-ordering question.
|
||||
`D_801F8888`/`D_801F8898` are two 16-byte objects (a `u16` pair at +4/+6, an `s32` flag at +0xC) that `func_8013240C`/
|
||||
`func_80132288` take by pointer — a struct type would make `s2 = &D_801F8888` a typed pointer and read better; the same
|
||||
pseudo, same bytes. `a0` is an actor (`u16` state at 0x34, `s16` flag at 0x70, pointers at 0x20/0x64/0x6C/0xCC). Not tested.
|
||||
|
||||
(h) Joint check (e35): all four e35 body.c files spliced into one copy of the tree TU with the four `extern void func_801A395C`
|
||||
turned into `extern s32` (`md_SC07_004__func_801A3594/scratch/joint.py` -> `scratch/joint_tu.c`, object `scratch/joint.o`):
|
||||
each of the four scores 0 through `--try` (whole-TU), and the object's `.text` (sha1 ad583f4dfb0c), `.rodata`, `.data`/`.sdata`/
|
||||
`.bss`, relocations and symbol table are identical to the baseline snapshot; the only difference is the source-path string.
|
||||
Gotcha for the next agent: a splice regex `^[^\n;]*\bfn\([^;{]*\)\s*\{` also matches a CALL line ending in `{`
|
||||
(`if (func_801A3594(...)) {` at :2061) — anchor the definition at column 0 (`^[A-Za-z_]`).
|
||||
@@ -0,0 +1,44 @@
|
||||
void func_801ABEE0(void *a0) {
|
||||
s32 r0 = (s32)a0;
|
||||
s32 ptr1;
|
||||
s32 s2;
|
||||
s16 v1;
|
||||
s32 val;
|
||||
s16 orig;
|
||||
s16 dec;
|
||||
|
||||
ptr1 = *(s32 *)(r0 + 0xCC);
|
||||
s2 = *(s32 *)(r0 + 0xD0);
|
||||
func_8012AD80(r0);
|
||||
*(s16 *)(ptr1 + 0x8) = *(u16 *)(r0 + 0x6);
|
||||
*(s16 *)(ptr1 + 0xA) = *(u16 *)(r0 + 0xA);
|
||||
*(s16 *)(ptr1 + 0xC) = *(u16 *)(r0 + 0xE);
|
||||
v1 = *(s16 *)(r0 + 0xA);
|
||||
if (v1 >= -0x200) {
|
||||
*(s16 *)(r0 + 0xA) = -0x200;
|
||||
func_801A9270((void *)r0);
|
||||
} else {
|
||||
if (s2 != 0) {
|
||||
ptr1 = *(s32 *)(s2 + 0xCC);
|
||||
if (ptr1 != 0) {
|
||||
val = (v1 + 0x500) << 4;
|
||||
*(s16 *)(ptr1 + 0x1A) = val;
|
||||
*(s16 *)(ptr1 + 0x18) = val;
|
||||
}
|
||||
}
|
||||
*(s32 *)(r0 + 0x1C) += 1;
|
||||
if ((*(s32 *)(r0 + 0x1C) & 1) == 0) {
|
||||
func_801A93F4((void *)r0);
|
||||
}
|
||||
}
|
||||
func_80128ED8(*(s32 *)(r0 + 0xCC), (s32 *)(r0 + 0xF0));
|
||||
func_801A9378((void *)r0);
|
||||
orig = *(s16 *)(r0 + 0x84);
|
||||
if (orig != 0) {
|
||||
dec = orig - 1;
|
||||
*(s16 *)(r0 + 0x84) = dec;
|
||||
if (dec == 0) {
|
||||
func_801AA60C((void *)r0, 0xAB8);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,40 @@
|
||||
# func_801ABEE0 (md_SC07_004) — P36 S104 agent e35 — score 29 (lever-free; sweep best 9) -> 0, ZERO levers (was 2 `$17` pins: `ptr1` and the block-local `inner`)
|
||||
|
||||
(a) Residual: REG only (70/70): the object pointer sits in `$s1` (target `$s0`), `ptr1` in `$s0` (target `$s1`), the inner
|
||||
pointer `*(s32 *)(s2 + 0xCC)` in `$v1` (target `$s1` — the SAME register as `ptr1`), and `v1` in `$a0` (target `$v1`).
|
||||
|
||||
(b) Pass and decision (`tools/alloc_table.py free|m1 func_801ABEE0 scratch/`):
|
||||
- The tree pinned two differently-named locals (`ptr1`, `inner`) to `$17`: METHOD d12 — they are ONE original variable
|
||||
the decompiler split (the sibling `func_801A9674` in this TU spells it `s1 = *(void **)((s32)s2 + 0xCC); if (s1 != NULL)`).
|
||||
- Lever-free, `ptr1` (r74: 4 refs, live 9, block 0, crosses 1 call) is BLOCK-LOCAL, so local-alloc hands it `$s0` before
|
||||
global runs (`local-alloc.c:2101-2106`), and the object pointer r73 (global, 19 refs, crosses 5 calls) is left `$s1`;
|
||||
`inner` is a separate global allocno (r87, pri 13333) that crosses no call and takes `$v1`.
|
||||
- Merged, `ptr1` (r74: 8 refs, live 15, "dies in 2 places") is global; `.greg` order `96 73 74 78 83 75`: r73 (pri 16521)
|
||||
takes `$s0`, r74 (16000) `$s1` (`allocno_compare`, `global.c:594-610`; `find_reg` `:945-990`). `v1` (r78, 2 bytes) then
|
||||
falls to `$v1`. Proven on bytes (`--try` 0, 70/70) and on the two allocation tables.
|
||||
|
||||
(c) Moves (body.c = scratch/m1.c): `inner` deleted, `ptr1 = *(s32 *)(s2 + 0xCC); if (ptr1 != 0) {...}` in its place; both
|
||||
pins deleted. Nothing else changed from body_free.c.
|
||||
|
||||
(d) GENERATOR PROPOSAL (d12, third confirmation): two locals pinned to the SAME callee-saved register, the second declared
|
||||
inside a nested block, are one variable — rename the inner one to the outer and delete its declaration; a merge that makes a
|
||||
block-local pseudo die in two places moves it from local-alloc's `$s0` grab to global's priority order, which is usually the
|
||||
target's. The free sweep's R18 "bystander" got to 9 by moving a statement; no generator merges two names.
|
||||
|
||||
(e) Did NOT work: nothing else was needed; the sweep's best 9 (R18 bystander, R12 `v1` s32, R4 decl moves) all leave the two
|
||||
pointers as two pseudos.
|
||||
|
||||
(f) Method gap: none — `sites.txt` said both `$17` pins were NEEDED, which is the d12 signature; `related.txt`'s sibling
|
||||
`func_801A9674` shows the reused-`s1` shape in the same TU. First `--try`.
|
||||
|
||||
(g) Structs: NO for the lever — a register-allocation decision over two pointer pseudos. `a0` is an actor (pointers at
|
||||
0xCC/0xD0 to a sprite and a partner actor, `s16` position at 0x6/0xA/0xE, `s32` counter at 0x1C, `s16` timer at 0x84,
|
||||
a vector at 0xF0) and the sprite has `s16` at 0x8/0xA/0xC (position) and 0x18/0x1A (scale) — `spr = o->partner->spr;`
|
||||
would read naturally and give the same pseudos. Not tested (nothing left to close).
|
||||
|
||||
(h) Joint check (e35): all four e35 body.c files spliced into one copy of the tree TU with the four `extern void func_801A395C`
|
||||
turned into `extern s32` (`md_SC07_004__func_801A3594/scratch/joint.py` -> `scratch/joint_tu.c`, object `scratch/joint.o`):
|
||||
each of the four scores 0 through `--try` (whole-TU), and the object's `.text` (sha1 ad583f4dfb0c), `.rodata`, `.data`/`.sdata`/
|
||||
`.bss`, relocations and symbol table are identical to the baseline snapshot; the only difference is the source-path string.
|
||||
Gotcha for the next agent: a splice regex `^[^\n;]*\bfn\([^;{]*\)\s*\{` also matches a CALL line ending in `{`
|
||||
(`if (func_801A3594(...)) {` at :2061) — anchor the definition at column 0 (`^[A-Za-z_]`).
|
||||
+179
-179
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"head": "6e29e3cc6",
|
||||
"head": "c27da130e",
|
||||
"stamp": "15956e4a96c4",
|
||||
"generated": "2026-09-11 05:53",
|
||||
"generated": "2026-09-11 06:08",
|
||||
"aliases": [
|
||||
"main",
|
||||
"ov_SC03_014",
|
||||
@@ -21,207 +21,207 @@
|
||||
"main": {
|
||||
"objects": 85,
|
||||
"identical": 85,
|
||||
"seconds": 6.939999999999999,
|
||||
"mean_s": 0.082
|
||||
"seconds": 6.839,
|
||||
"mean_s": 0.08
|
||||
},
|
||||
"ov_SC03_014": {
|
||||
"objects": 32,
|
||||
"identical": 32,
|
||||
"seconds": 4.711,
|
||||
"seconds": 4.6979999999999995,
|
||||
"mean_s": 0.147
|
||||
},
|
||||
"ov_SC03_015": {
|
||||
"objects": 32,
|
||||
"identical": 32,
|
||||
"seconds": 4.329999999999998,
|
||||
"mean_s": 0.135
|
||||
"seconds": 4.377,
|
||||
"mean_s": 0.137
|
||||
},
|
||||
"ov_SC04_011": {
|
||||
"objects": 28,
|
||||
"identical": 28,
|
||||
"seconds": 3.694,
|
||||
"mean_s": 0.132
|
||||
"seconds": 3.7600000000000002,
|
||||
"mean_s": 0.134
|
||||
}
|
||||
},
|
||||
"per_object_seconds": {
|
||||
"build/src/800.o": 0.724,
|
||||
"build/src/800_b.o": 0.098,
|
||||
"build/src/800_b_2.o": 0.309,
|
||||
"build/src/800_b_o0a.o": 0.07,
|
||||
"build/src/800_c.o": 0.196,
|
||||
"build/src/800b2.o": 0.103,
|
||||
"build/src/800.o": 0.708,
|
||||
"build/src/800_b.o": 0.071,
|
||||
"build/src/800_b_2.o": 0.293,
|
||||
"build/src/800_b_o0a.o": 0.063,
|
||||
"build/src/800_c.o": 0.174,
|
||||
"build/src/800b2.o": 0.09,
|
||||
"build/src/apicard1.o": 0.076,
|
||||
"build/src/apicard2.o": 0.069,
|
||||
"build/src/apicard3.o": 0.096,
|
||||
"build/src/apicard4.o": 0.065,
|
||||
"build/src/apicard5.o": 0.076,
|
||||
"build/src/apicard6.o": 0.067,
|
||||
"build/src/apicard7.o": 0.066,
|
||||
"build/src/boot.o": 0.094,
|
||||
"build/src/gap.o": 0.072,
|
||||
"build/src/libapi1.o": 0.075,
|
||||
"build/src/libapi2.o": 0.065,
|
||||
"build/src/libc2_1.o": 0.068,
|
||||
"build/src/libc2_2.o": 0.065,
|
||||
"build/src/libcd1.o": 0.08,
|
||||
"build/src/libcd2.o": 0.066,
|
||||
"build/src/libetc.o": 0.068,
|
||||
"build/src/libgpu.o": 0.062,
|
||||
"build/src/libgpu2.o": 0.072,
|
||||
"build/src/libgs1.o": 0.054,
|
||||
"build/src/libgs2.o": 0.068,
|
||||
"build/src/libgs3.o": 0.058,
|
||||
"build/src/libgs4.o": 0.066,
|
||||
"build/src/libgs5.o": 0.066,
|
||||
"build/src/libgs6.o": 0.085,
|
||||
"build/src/libgs7.o": 0.066,
|
||||
"build/src/libgs8.o": 0.069,
|
||||
"build/src/libgte1.o": 0.062,
|
||||
"build/src/libgte10.o": 0.063,
|
||||
"build/src/libgte11.o": 0.06,
|
||||
"build/src/apicard2.o": 0.07,
|
||||
"build/src/apicard3.o": 0.078,
|
||||
"build/src/apicard4.o": 0.078,
|
||||
"build/src/apicard5.o": 0.066,
|
||||
"build/src/apicard6.o": 0.066,
|
||||
"build/src/apicard7.o": 0.09,
|
||||
"build/src/boot.o": 0.081,
|
||||
"build/src/gap.o": 0.094,
|
||||
"build/src/libapi1.o": 0.076,
|
||||
"build/src/libapi2.o": 0.055,
|
||||
"build/src/libc2_1.o": 0.074,
|
||||
"build/src/libc2_2.o": 0.061,
|
||||
"build/src/libcd1.o": 0.095,
|
||||
"build/src/libcd2.o": 0.067,
|
||||
"build/src/libetc.o": 0.079,
|
||||
"build/src/libgpu.o": 0.08,
|
||||
"build/src/libgpu2.o": 0.098,
|
||||
"build/src/libgs1.o": 0.057,
|
||||
"build/src/libgs2.o": 0.052,
|
||||
"build/src/libgs3.o": 0.06,
|
||||
"build/src/libgs4.o": 0.072,
|
||||
"build/src/libgs5.o": 0.049,
|
||||
"build/src/libgs6.o": 0.116,
|
||||
"build/src/libgs7.o": 0.063,
|
||||
"build/src/libgs8.o": 0.07,
|
||||
"build/src/libgte1.o": 0.054,
|
||||
"build/src/libgte10.o": 0.062,
|
||||
"build/src/libgte11.o": 0.061,
|
||||
"build/src/libgte12.o": 0.065,
|
||||
"build/src/libgte13.o": 0.071,
|
||||
"build/src/libgte14.o": 0.063,
|
||||
"build/src/libgte15.o": 0.065,
|
||||
"build/src/libgte16.o": 0.072,
|
||||
"build/src/libgte17.o": 0.065,
|
||||
"build/src/libgte18.o": 0.066,
|
||||
"build/src/libgte19.o": 0.074,
|
||||
"build/src/libgte2.o": 0.065,
|
||||
"build/src/libgte13.o": 0.057,
|
||||
"build/src/libgte14.o": 0.07,
|
||||
"build/src/libgte15.o": 0.062,
|
||||
"build/src/libgte16.o": 0.064,
|
||||
"build/src/libgte17.o": 0.052,
|
||||
"build/src/libgte18.o": 0.067,
|
||||
"build/src/libgte19.o": 0.06,
|
||||
"build/src/libgte2.o": 0.063,
|
||||
"build/src/libgte20.o": 0.066,
|
||||
"build/src/libgte21.o": 0.066,
|
||||
"build/src/libgte22.o": 0.066,
|
||||
"build/src/libgte23.o": 0.062,
|
||||
"build/src/libgte24.o": 0.069,
|
||||
"build/src/libgte25.o": 0.068,
|
||||
"build/src/libgte26.o": 0.068,
|
||||
"build/src/libgte27.o": 0.056,
|
||||
"build/src/libgte28.o": 0.067,
|
||||
"build/src/libgte29.o": 0.067,
|
||||
"build/src/libgte3.o": 0.068,
|
||||
"build/src/libgte21.o": 0.063,
|
||||
"build/src/libgte22.o": 0.062,
|
||||
"build/src/libgte23.o": 0.059,
|
||||
"build/src/libgte24.o": 0.062,
|
||||
"build/src/libgte25.o": 0.059,
|
||||
"build/src/libgte26.o": 0.059,
|
||||
"build/src/libgte27.o": 0.065,
|
||||
"build/src/libgte28.o": 0.068,
|
||||
"build/src/libgte29.o": 0.066,
|
||||
"build/src/libgte3.o": 0.066,
|
||||
"build/src/libgte30.o": 0.071,
|
||||
"build/src/libgte4.o": 0.069,
|
||||
"build/src/libgte5.o": 0.07,
|
||||
"build/src/libgte6.o": 0.063,
|
||||
"build/src/libgte7.o": 0.065,
|
||||
"build/src/libgte8.o": 0.063,
|
||||
"build/src/libgte9.o": 0.064,
|
||||
"build/src/libmcrd1.o": 0.076,
|
||||
"build/src/libmcrd2.o": 0.068,
|
||||
"build/src/libpad1.o": 0.069,
|
||||
"build/src/libpad2.o": 0.073,
|
||||
"build/src/sgap.o": 0.073,
|
||||
"build/src/sgap_2.o": 0.067,
|
||||
"build/src/sgap_3.o": 0.068,
|
||||
"build/src/sgap_4.o": 0.071,
|
||||
"build/src/sgap_5.o": 0.067,
|
||||
"build/src/sgap_6.o": 0.068,
|
||||
"build/src/sgap_8.o": 0.07,
|
||||
"build/src/snd1.o": 0.075,
|
||||
"build/src/snd10.o": 0.073,
|
||||
"build/src/snd11.o": 0.073,
|
||||
"build/src/snd12.o": 0.072,
|
||||
"build/src/snd2.o": 0.08,
|
||||
"build/src/snd3.o": 0.068,
|
||||
"build/src/snd4.o": 0.068,
|
||||
"build/src/snd5.o": 0.066,
|
||||
"build/src/snd6.o": 0.067,
|
||||
"build/src/snd7.o": 0.069,
|
||||
"build/src/snd8.o": 0.07,
|
||||
"build/src/snd9.o": 0.076,
|
||||
"build/src/ov_SC03_014/ov_SC03_014.o": 0.129,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_after.o": 0.533,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8012ACE0.o": 0.39,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80135888.o": 0.059,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80135A4C.o": 0.072,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80135D20.o": 0.122,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801380E0.o": 0.162,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8013C98C.o": 0.122,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8013F350.o": 0.082,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8013FFD8.o": 0.088,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80140608.o": 0.182,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8015444C.o": 0.082,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80154C24.o": 0.167,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801588CC.o": 0.095,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80159C84.o": 0.07,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8015A3C8.o": 0.069,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8015AE2C.o": 0.09,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8015C32C.o": 0.452,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8016AB6C.o": 0.275,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80171B4C.o": 0.093,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801734BC.o": 0.208,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801789AC.o": 0.058,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80178D40.o": 0.105,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8017A4AC.o": 0.076,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8017AE2C.o": 0.167,
|
||||
"build/src/libgte4.o": 0.067,
|
||||
"build/src/libgte5.o": 0.067,
|
||||
"build/src/libgte6.o": 0.066,
|
||||
"build/src/libgte7.o": 0.061,
|
||||
"build/src/libgte8.o": 0.061,
|
||||
"build/src/libgte9.o": 0.06,
|
||||
"build/src/libmcrd1.o": 0.109,
|
||||
"build/src/libmcrd2.o": 0.069,
|
||||
"build/src/libpad1.o": 0.068,
|
||||
"build/src/libpad2.o": 0.078,
|
||||
"build/src/sgap.o": 0.067,
|
||||
"build/src/sgap_2.o": 0.061,
|
||||
"build/src/sgap_3.o": 0.06,
|
||||
"build/src/sgap_4.o": 0.064,
|
||||
"build/src/sgap_5.o": 0.057,
|
||||
"build/src/sgap_6.o": 0.057,
|
||||
"build/src/sgap_8.o": 0.058,
|
||||
"build/src/snd1.o": 0.081,
|
||||
"build/src/snd10.o": 0.075,
|
||||
"build/src/snd11.o": 0.051,
|
||||
"build/src/snd12.o": 0.046,
|
||||
"build/src/snd2.o": 0.096,
|
||||
"build/src/snd3.o": 0.082,
|
||||
"build/src/snd4.o": 0.069,
|
||||
"build/src/snd5.o": 0.072,
|
||||
"build/src/snd6.o": 0.086,
|
||||
"build/src/snd7.o": 0.068,
|
||||
"build/src/snd8.o": 0.063,
|
||||
"build/src/snd9.o": 0.095,
|
||||
"build/src/ov_SC03_014/ov_SC03_014.o": 0.131,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_after.o": 0.48,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8012ACE0.o": 0.372,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80135888.o": 0.055,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80135A4C.o": 0.07,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80135D20.o": 0.124,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801380E0.o": 0.151,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8013C98C.o": 0.152,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8013F350.o": 0.091,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8013FFD8.o": 0.072,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80140608.o": 0.186,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8015444C.o": 0.071,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80154C24.o": 0.176,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801588CC.o": 0.096,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80159C84.o": 0.099,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8015A3C8.o": 0.07,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8015AE2C.o": 0.1,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8015C32C.o": 0.457,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8016AB6C.o": 0.274,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80171B4C.o": 0.105,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801734BC.o": 0.201,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801789AC.o": 0.059,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80178D40.o": 0.1,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8017A4AC.o": 0.065,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8017AE2C.o": 0.177,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_8017EB7C.o": 0.201,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80184440.o": 0.054,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801848E4.o": 0.267,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_o0b.o": 0.061,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_o0c.o": 0.057,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_o0d.o": 0.054,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_80184440.o": 0.045,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_jr_801848E4.o": 0.278,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_o0b.o": 0.06,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_o0c.o": 0.06,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_o0d.o": 0.051,
|
||||
"build/src/ov_SC03_014/ov_SC03_014_o0e.o": 0.069,
|
||||
"build/src/ov_SC03_015/ov_SC03_015.o": 0.114,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_after.o": 0.486,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8012ACE0.o": 0.376,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80135888.o": 0.054,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80135A4C.o": 0.05,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80135D20.o": 0.114,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801380E0.o": 0.135,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8013C98C.o": 0.098,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8013F350.o": 0.067,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8013FFD8.o": 0.059,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80140608.o": 0.161,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8015444C.o": 0.069,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80154C24.o": 0.159,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801588CC.o": 0.081,
|
||||
"build/src/ov_SC03_015/ov_SC03_015.o": 0.109,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_after.o": 0.497,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8012ACE0.o": 0.38,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80135888.o": 0.049,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80135A4C.o": 0.045,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80135D20.o": 0.106,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801380E0.o": 0.138,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8013C98C.o": 0.102,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8013F350.o": 0.072,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8013FFD8.o": 0.061,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80140608.o": 0.183,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8015444C.o": 0.064,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80154C24.o": 0.163,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801588CC.o": 0.08,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80159C84.o": 0.061,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8015A3C8.o": 0.069,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8015AE2C.o": 0.087,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8015C32C.o": 0.449,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8016AB6C.o": 0.252,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80171B4C.o": 0.098,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801734BC.o": 0.195,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801789AC.o": 0.054,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80178D40.o": 0.087,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8017A4AC.o": 0.061,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8017AE2C.o": 0.157,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8017EB7C.o": 0.186,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80184440.o": 0.046,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801848E4.o": 0.279,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_o0b.o": 0.055,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_o0c.o": 0.051,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_o0d.o": 0.052,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_o0e.o": 0.068,
|
||||
"build/src/ov_SC04_011/ov_SC04_011.o": 0.111,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_after.o": 0.409,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8012ACE0.o": 0.343,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80135888.o": 0.051,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80135A4C.o": 0.048,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80135D20.o": 0.109,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_801380E0.o": 0.14,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8013C98C.o": 0.104,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8013F350.o": 0.064,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8013FFD8.o": 0.059,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80140608.o": 0.168,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8015444C.o": 0.062,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80154C24.o": 0.133,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_801588CC.o": 0.085,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80159C84.o": 0.061,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8015A3C8.o": 0.062,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8015AE2C.o": 0.09,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8015C32C.o": 0.347,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8016AB6C.o": 0.215,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80171B4C.o": 0.087,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_801734BC.o": 0.159,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_801789AC.o": 0.047,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80178D40.o": 0.074,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8017A4AC.o": 0.062,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8017AE2C.o": 0.093,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8017D494.o": 0.41,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_o0b.o": 0.047,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8015A3C8.o": 0.068,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8015AE2C.o": 0.088,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8015C32C.o": 0.453,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8016AB6C.o": 0.263,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80171B4C.o": 0.091,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801734BC.o": 0.184,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801789AC.o": 0.052,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80178D40.o": 0.102,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8017A4AC.o": 0.059,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8017AE2C.o": 0.164,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_8017EB7C.o": 0.178,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_80184440.o": 0.049,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_jr_801848E4.o": 0.281,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_o0b.o": 0.063,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_o0c.o": 0.052,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_o0d.o": 0.054,
|
||||
"build/src/ov_SC03_015/ov_SC03_015_o0e.o": 0.066,
|
||||
"build/src/ov_SC04_011/ov_SC04_011.o": 0.117,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_after.o": 0.401,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8012ACE0.o": 0.32,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80135888.o": 0.048,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80135A4C.o": 0.053,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80135D20.o": 0.122,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_801380E0.o": 0.141,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8013C98C.o": 0.111,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8013F350.o": 0.065,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8013FFD8.o": 0.058,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80140608.o": 0.158,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8015444C.o": 0.07,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80154C24.o": 0.153,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_801588CC.o": 0.094,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80159C84.o": 0.062,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8015A3C8.o": 0.056,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8015AE2C.o": 0.085,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8015C32C.o": 0.336,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8016AB6C.o": 0.221,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80171B4C.o": 0.095,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_801734BC.o": 0.155,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_801789AC.o": 0.057,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_80178D40.o": 0.086,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8017A4AC.o": 0.057,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8017AE2C.o": 0.092,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_jr_8017D494.o": 0.45,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_o0b.o": 0.043,
|
||||
"build/src/ov_SC04_011/ov_SC04_011_o0c.o": 0.054
|
||||
},
|
||||
"ok": true,
|
||||
"seconds": 2.2
|
||||
"seconds": 2.3
|
||||
}
|
||||
|
||||
@@ -29553,3 +29553,4 @@
|
||||
{"ts": "2026-09-11 05:53:03", "label": "s104_e36", "rung": "E", "calib": {"head": "ef4676a1d", "stamp": "15956e4a96c4"}, "tu": "src/ov_SC03_089/ov_SC03_089_jr_8017CA80.c", "fn": "func_80184BAC", "addr": 2149075884, "aliases": null, "header": false, "includers": 0, "nhash_before": "9429495b95e5262d280f67fba1d9004a69168724", "nhash_after": "82458caa346ca220abb9c5781ccd5fa0a13ab303", "source": "propagate:src/ov_SC03_090/ov_SC03_090_jr_8017CA80.c:func_80184888", "verdict": "LEVER-FREE", "sites": [], "compiles": 1, "seconds": 0.233, "objects": ["build/src/ov_SC03_089/ov_SC03_089_jr_8017CA80.o"], "before_text": "void func_80184BAC(s32 out, s32 a1, s32 a2) {\n s32 sp10[4];\n s32 sp20;\n s16 *q;\n u16 *p;\n s16 t;\n extern s32 func_80184D28();\n register s32 dst __asm__(\"$2\"); // !FAKE: pin $2 \u2014 NEEDED DIFFERS (P36 rung B tus9)\n\n q = &D_80126CBA;\n if (*q == 0) {\n if (func_80184D28(a1) == 0) {\n p = (u16 *)(q - 3);\n *(s32 *)(a1 + 0xDC) = 0;\n } else {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n }\n } else {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n }\n *(s16 *)((s32)sp10 + 0x2) = p[0] + *(u16 *)a2;\n t = p[1] + *(u16 *)(a2 + 2);\n *(s16 *)((s32)sp10 + 0x6) = t;\n *(s16 *)(a1 + 0x100) = t;\n *(s16 *)((s32)sp10 + 0xA) = p[2] + *(u16 *)(a2 + 4);\n func_8012B77C((s32)&sp20, a1 + 4, (s32)sp10);\n dst = (s32)out;\n *(s32 *)dst = sp20;\n __asm__ __volatile__(\"\" : : \"r\" (dst)); // !FAKE: keepalive \u2014 NEEDED DIFFERS (P36 rung B tus9)\n}\n", "after_text": "s32 *aF80184888(s32 *a0, s32 a1, s32 a2) __asm__(\"func_80184BAC\");\n\ns32 *aF80184888(s32 *a0, s32 a1, s32 a2) {\n s32 sp10[4];\n s32 sp20;\n s16 *q;\n u16 *p;\n s16 t;\n extern s32 func_80184D28();\n extern s16 D_80126CBA;\n extern s32 func_8012B77C(s32 out, s32 from, s32 to);\n\n q = &D_80126CBA;\n if (*q == 0) {\n if (func_80184D28(a1)) {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n } else {\n p = (u16 *)(q - 3);\n *(s32 *)(a1 + 0xDC) = 0;\n }\n } else {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n }\n *(s16 *)((s32)sp10 + 0x2) = p[0] + *(u16 *)a2;\n t = p[1] + *(u16 *)(a2 + 2);\n *(s16 *)((s32)sp10 + 0x6) = t;\n *(s16 *)(a1 + 0x100) = t;\n *(s16 *)((s32)sp10 + 0xA) = p[2] + *(u16 *)(a2 + 4);\n func_8012B77C((s32)&sp20, a1 + 4, (s32)sp10);\n *a0 = sp20;\n return a0;\n}\n"}
|
||||
{"ts": "2026-09-11 05:53:40", "label": "s104_e36", "rung": "E", "calib": {"head": "f1000a814", "stamp": "15956e4a96c4"}, "tu": "src/ov_SC03_089/ov_SC03_089_jr_8017CA80.c", "fn": "func_80184BAC", "addr": 2149075884, "aliases": null, "header": false, "includers": 0, "nhash_before": "82458caa346ca220abb9c5781ccd5fa0a13ab303", "nhash_after": "18589be924e6d952313a791fe88fa7062a777c8d", "source": ".run/P36/agents/ov_SC03_091__func_80185730/scratch/copyp_func_80184BAC.c", "verdict": "LEVER-FREE", "sites": [], "compiles": 1, "seconds": 0.235, "objects": ["build/src/ov_SC03_089/ov_SC03_089_jr_8017CA80.o"], "before_text": "s32 *aF80184888(s32 *a0, s32 a1, s32 a2) {\n s32 sp10[4];\n s32 sp20;\n s16 *q;\n u16 *p;\n s16 t;\n extern s32 func_80184D28();\n extern s16 D_80126CBA;\n extern s32 func_8012B77C(s32 out, s32 from, s32 to);\n\n q = &D_80126CBA;\n if (*q == 0) {\n if (func_80184D28(a1)) {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n } else {\n p = (u16 *)(q - 3);\n *(s32 *)(a1 + 0xDC) = 0;\n }\n } else {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n }\n *(s16 *)((s32)sp10 + 0x2) = p[0] + *(u16 *)a2;\n t = p[1] + *(u16 *)(a2 + 2);\n *(s16 *)((s32)sp10 + 0x6) = t;\n *(s16 *)(a1 + 0x100) = t;\n *(s16 *)((s32)sp10 + 0xA) = p[2] + *(u16 *)(a2 + 4);\n func_8012B77C((s32)&sp20, a1 + 4, (s32)sp10);\n *a0 = sp20;\n return a0;\n}\n", "after_text": "s32 *aF80184BAC(s32 *a0, s32 a1, s32 a2) __asm__(\"func_80184BAC\");\n\ns32 *aF80184BAC(s32 *a0, s32 a1, s32 a2) {\n s32 sp10[4];\n s32 sp20;\n s16 *q;\n u16 *p;\n s16 t;\n extern s32 func_80184D28();\n extern s16 D_80126CBA;\n extern s32 func_8012B77C(s32 out, s32 from, s32 to);\n\n q = &D_80126CBA;\n if (*q == 0) {\n if (func_80184D28(a1)) {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n } else {\n p = (u16 *)(q - 3);\n *(s32 *)(a1 + 0xDC) = 0;\n }\n } else {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n }\n *(s16 *)((s32)sp10 + 0x2) = p[0] + *(u16 *)a2;\n t = p[1] + *(u16 *)(a2 + 2);\n *(s16 *)((s32)sp10 + 0x6) = t;\n *(s16 *)(a1 + 0x100) = t;\n *(s16 *)((s32)sp10 + 0xA) = p[2] + *(u16 *)(a2 + 4);\n func_8012B77C((s32)&sp20, a1 + 4, (s32)sp10);\n *a0 = sp20;\n return a0;\n}\n"}
|
||||
{"ts": "2026-09-11 05:53:57", "label": "s104_e36", "rung": "E", "calib": {"head": "6e29e3cc6", "stamp": "15956e4a96c4"}, "tu": "src/ov_SC03_104/ov_SC03_104_jr_80182038.c", "fn": "func_8018271C", "addr": 2149066524, "aliases": null, "header": false, "includers": 0, "nhash_before": "5e5c930b17254e5c16461e25a8bceb1369d15010", "nhash_after": "38bc6baf0d609d66d9f2d6fea8f4ffdc67f7ab19", "source": ".run/P36/agents/ov_SC03_091__func_80185730/scratch/copyp_func_8018271C.c", "verdict": "LEVER-FREE", "sites": [], "compiles": 1, "seconds": 0.112, "objects": ["build/src/ov_SC03_104/ov_SC03_104_jr_80182038.o"], "before_text": "void func_8018271C(s32 out, s32 a1, s32 a2) {\n s32 sp10[4];\n s32 sp20;\n s16 *q;\n u16 *p;\n s16 t;\n register s32 rv __asm__(\"$2\"); // !FAKE: pin $2 \u2014 NEEDED DIFFERS (P36 rung B tus9)\n\n q = &D_80126CBA;\n if (*q == 0) {\n if (func_80182898(a1) == 0) {\n p = (u16 *)(q - 3);\n *(s32 *)(a1 + 0xDC) = 0;\n } else {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n }\n } else {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n }\n *(s16 *)((s32)sp10 + 0x2) = p[0] + *(u16 *)a2;\n t = p[1] + *(u16 *)(a2 + 2);\n *(s16 *)((s32)sp10 + 0x6) = t;\n *(s16 *)(a1 + 0x100) = t;\n *(s16 *)((s32)sp10 + 0xA) = p[2] + *(u16 *)(a2 + 4);\n func_8012B77C((s32)&sp20, a1 + 4, (s32)sp10);\n rv = (s32)out;\n *(s32 *)rv = sp20;\n __asm__ __volatile__(\"\" : : \"r\" (rv)); // !FAKE: keepalive \u2014 NEEDED DIFFERS (P36 rung B tus9)\n}\n", "after_text": "s32 *aF8018271C(s32 *a0, s32 a1, s32 a2) __asm__(\"func_8018271C\");\n\ns32 *aF8018271C(s32 *a0, s32 a1, s32 a2) {\n s32 sp10[4];\n s32 sp20;\n s16 *q;\n u16 *p;\n s16 t;\n extern s32 func_80182898();\n extern s16 D_80126CBA;\n extern s32 func_8012B77C(s32 out, s32 from, s32 to);\n\n q = &D_80126CBA;\n if (*q == 0) {\n if (func_80182898(a1)) {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n } else {\n p = (u16 *)(q - 3);\n *(s32 *)(a1 + 0xDC) = 0;\n }\n } else {\n p = (u16 *)(a1 + 0x88);\n *(s32 *)(a1 + 0xDC) = 1;\n }\n *(s16 *)((s32)sp10 + 0x2) = p[0] + *(u16 *)a2;\n t = p[1] + *(u16 *)(a2 + 2);\n *(s16 *)((s32)sp10 + 0x6) = t;\n *(s16 *)(a1 + 0x100) = t;\n *(s16 *)((s32)sp10 + 0xA) = p[2] + *(u16 *)(a2 + 4);\n func_8012B77C((s32)&sp20, a1 + 4, (s32)sp10);\n *a0 = sp20;\n return a0;\n}\n"}
|
||||
{"ts": "2026-09-11 06:08:46", "label": "s104_e35", "rung": "E", "calib": {"head": "c27da130e", "stamp": "15956e4a96c4"}, "tu": "src/md_SC07_004/md_SC07_004.c", "fn": "func_801A3594", "addr": 2149201300, "aliases": null, "header": false, "includers": 0, "nhash_before": "af746f7ee508be551cc6cbb6f6c5ac3d69fc1ebf", "nhash_after": "e7180037006a1e72720d650c1d9b13e59ac3f9cb", "source": ".run/P36/agents/md_SC07_004__func_801A3594/body.c", "verdict": "LEVER-FREE", "sites": [], "compiles": 1, "seconds": 0.304, "objects": ["build/src/md_SC07_004/md_SC07_004.o"], "before_text": "s32 func_801A3594(void *a0) {\n s16 buf[12];\n register u16 b __asm__(\"$3\"); // !FAKE: pin $3 \u2014 NEEDED DIFFERS (P36 rung B tus9)\n u16 a;\n s16 diff;\n s16 v1;\n register s32 tw __asm__(\"$2\"); // !FAKE: pin $2 \u2014 NEEDED DIFFERS (P36 rung B tus9)\n s16 t16;\n s16 xr;\n\n v1 = *(s16 *)((s32)a0 + 0x106);\n switch (v1) {\n case 0:\n a = *(u16 *)((s32)a0 + 0xE8);\n b = *(u16 *)((s32)a0 + 0x6);\n diff = a - b;\n buf[0] = diff;\n tw = *(s16 *)((s32)a0 + 0xEC);\n break;\n case 1:\n a = *(u16 *)((s32)a0 + 0xEA);\n b = *(u16 *)((s32)a0 + 0xE);\n diff = a - b;\n buf[1] = diff;\n tw = *(s16 *)((s32)a0 + 0xEE);\n break;\n default:\n goto default_case;\n }\n\n if (tw == 0) goto ret1;\n t16 = tw;\n if (diff == 0) goto ret1;\n xr = diff ^ t16;\n if (xr >= 0) goto default_case;\nret1:\n return 1;\ndefault_case:\n return 0;\n}\n", "after_text": "s32 func_801A3594(void *a0) {\n s16 buf[12];\n s16 diff;\n s16 v1;\n s16 t16;\n s16 xr;\n\n v1 = *(s16 *)((s32)a0 + 0x106);\n switch (v1) {\n case 0: {\n s32 tw;\n\n diff = *(u16 *)((s32)a0 + 0xE8) - *(u16 *)((s32)a0 + 0x6);\n buf[0] = diff;\n tw = *(s16 *)((s32)a0 + 0xEC);\n t16 = tw;\n if (tw == 0) {\n return 1;\n }\n break;\n }\n case 1: {\n s32 tw;\n\n diff = *(u16 *)((s32)a0 + 0xEA) - *(u16 *)((s32)a0 + 0xE);\n buf[1] = diff;\n tw = *(s16 *)((s32)a0 + 0xEE);\n t16 = tw;\n if (tw == 0) {\n return 1;\n }\n break;\n }\n default:\n goto default_case;\n }\n\n if (diff == 0) goto ret1;\n xr = diff ^ t16;\n if (xr >= 0) goto default_case;\nret1:\n return 1;\ndefault_case:\n return 0;\n}\n"}
|
||||
|
||||
@@ -2165,36 +2165,41 @@ void func_801A34FC(s32 arg0, u16 *arg1) {
|
||||
|
||||
s32 func_801A3594(void *a0) {
|
||||
s16 buf[12];
|
||||
register u16 b __asm__("$3"); // !FAKE: pin $3 — NEEDED DIFFERS (P36 rung B tus9)
|
||||
u16 a;
|
||||
s16 diff;
|
||||
s16 v1;
|
||||
register s32 tw __asm__("$2"); // !FAKE: pin $2 — NEEDED DIFFERS (P36 rung B tus9)
|
||||
s16 t16;
|
||||
s16 xr;
|
||||
|
||||
v1 = *(s16 *)((s32)a0 + 0x106);
|
||||
switch (v1) {
|
||||
case 0:
|
||||
a = *(u16 *)((s32)a0 + 0xE8);
|
||||
b = *(u16 *)((s32)a0 + 0x6);
|
||||
diff = a - b;
|
||||
case 0: {
|
||||
s32 tw;
|
||||
|
||||
diff = *(u16 *)((s32)a0 + 0xE8) - *(u16 *)((s32)a0 + 0x6);
|
||||
buf[0] = diff;
|
||||
tw = *(s16 *)((s32)a0 + 0xEC);
|
||||
t16 = tw;
|
||||
if (tw == 0) {
|
||||
return 1;
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
a = *(u16 *)((s32)a0 + 0xEA);
|
||||
b = *(u16 *)((s32)a0 + 0xE);
|
||||
diff = a - b;
|
||||
}
|
||||
case 1: {
|
||||
s32 tw;
|
||||
|
||||
diff = *(u16 *)((s32)a0 + 0xEA) - *(u16 *)((s32)a0 + 0xE);
|
||||
buf[1] = diff;
|
||||
tw = *(s16 *)((s32)a0 + 0xEE);
|
||||
t16 = tw;
|
||||
if (tw == 0) {
|
||||
return 1;
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
goto default_case;
|
||||
}
|
||||
|
||||
if (tw == 0) goto ret1;
|
||||
t16 = tw;
|
||||
if (diff == 0) goto ret1;
|
||||
xr = diff ^ t16;
|
||||
if (xr >= 0) goto default_case;
|
||||
|
||||
Reference in New Issue
Block a user