mirror of
https://github.com/Cesarus85/ringfall-mjolnir-vr.git
synced 2026-10-23 07:00:30 +02:00
2.6 KiB
2.6 KiB
path_structure_bsp.obj — structure_surface_index_from_point
This isolated lane reconstructs only structure_surface_index_from_point from
the January 14, 2002 target. The remaining five object functions are intentionally
absent and are owned by the parent atomic-object lane.
Target evidence
- Padded size:
0x60(96 bytes); meaningful size: 82 bytes. - Relocations: one
REL32call to_structure_test_line2dat function offset0x28. - The target has three distinct returns: immediate
NONE, fallback toknown_surface_index, and the recovered surface index. Multiple returns are retained because they are required by the January control flow, despite the project's general preference for a single return. - The stack local is a
0x1c-bytepath_collision_result; its point begins at offset+0x04, and its surface index is at+0x10.
Experiments
E1 — HCEA topology with January-authoritative types
- Shape: guard return for
known_surface_index == NONE, one line-test call, copy the resulting 2D point, then fallback/result returns. - Source provenance: HCEA supplied the control-flow hypothesis; January bytes independently proved every parameter, stack offset, call argument, and return.
- Result: size and relocation count matched (
0x60, 1), but the call relocation landed at+0x2finstead of+0x28. VC7 placed the immediateNONEreturn before the body, adding a seven-byte early epilogue that January places after the body. Rejected.
E2 — positive body guard, trailing NONE return
- Shape: wrap the line-test body in
if (known_surface_index != NONE), keep the fallback return within it, and put theNONEreturn after the guarded body. - Prediction: this preserves the same three semantic exits while putting the
immediate-
NONEmaterialization after the body, as required by the target CFG. - Result: strict exact. Target/candidate padded size
0x60; relocation count1/1; call relocation address/type/destination/addend equal at+0x28; both normalized SHA-256 values are29cfb8955fc45cfc7972505dddb757d4374ca33735024c18aa7f5baac71b8f49.
Verification
ninja build/base/source/ai/path_structure_bsp.obj
python -m tools.coff_compare build/split/source/ai/path_structure_bsp.obj \
build/base/source/ai/path_structure_bsp.obj \
_structure_surface_index_from_point
The hardened comparator returned all_equal: true. No data sections are owned
by this function-only lane. Whole-object admission remains the parent lane's
responsibility after the other five functions and shared data are reconstructed.