Both bulk converters are strict exact first landing: compress_vertices
736/736 and uncompress_vertices 1088/1088. The object now has ZERO unwritten
functions - 16/19 strict exact plus the 3 parked scheduling ties - up from
9/19 at the start of the session. Board 4,827 -> 4,829 functions and
668,055 -> 669,879 strict code bytes; no other object moved.
Four vertex structs are recovered from the indexing and the stride table:
environment_vertex_uncompressed (56), environment_lightmap_vertex_
uncompressed (20), model_vertex_uncompressed (68) and
model_vertex_compressed (32). The switch uses the _rasterizer_vertex_type_*
enum constants, and prototypes for both functions now live in
rasterizer_geometry.h.
Records a PRESERVED ORIGINAL BUG rather than shipping it silently: the model
node weight is stored by compress with compress_real_to_int16_clamp as a
full 16-bit value (mov word ptr [edi+0xe], ax) but read back by uncompress
as its low byte only (movzx edx, byte ptr [edi+0xe]) and rescaled by 1/255,
so the round trip does not recover the stored weight. Verified against
January's bytes on both sides before concluding it was original rather than
a reconstruction error, and annotated in source with the corrected-build
alternative.
Only extra COMDAT versus January is _fast_ftol; no function is missing.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
uncompress_int32_to_real_vector3d is now written: 144/144 padded bytes, 9/9
relocations with identical destinations, 49/49 instructions. The sole
divergence is one dependency-free transposition - January emits
fadd __real@3f800000 before shl eax,0x16 and we emit them swapped, which
also shifts that relocation's address by three bytes.
The shape that got the frame right was a local real_vector3d copied out
through *result, not three scalar reals: sub esp,0xc is the vector, and
naming three scalars lets VC7 fold them away (112 bytes). Bit fields are
11/11/10 with 2^-20 and 2^-21 pre-scales and 1/2047 and 1/1023 scales,
reached by destructive shifts so the shr sequence matches.
Per the new house rule - fuzzy match and park when easy byte matching is not
achievable - this function and the two vector3d compressors are now parked
as instruction-scheduling ties. All three meet the parking standard: exact
padded size, relocation count and destinations, full instruction-count
parity, a precisely classified single divergence, and an exhausted set of
legal-C controls recorded in each entry. Fuzzy: 95.0, 96.35, 94.8.
Parked audit 15 active / 0 stale / 0 invalid; the build gates on parked
evidence and passes. Board unchanged for every other object.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
compress_real_vector3d_to_int32 (544) and _clamp (512) are now written and
measure size exact, relocations exact 38/38 address-for-address, 181/181 and
164/164 instructions, differing only by one transposition. NOT exact, no
credit claimed.
Recovered from January's bytes: 11/11/10-bit fields with 1023.5f/511.5f
scales and 0x7ff/0x3ff masks; pack ((k << 11) | j) << 11 | i; a
SELF-REFERENCING round-trip copy through one local (&v2 in, *result back
into v2); the assert message goes through the global temporary with a format
that is exactly 36 bytes including NUL, which is what pins 0x%x%x%x rather
than a spaced form. The clamp twin folds PIN into the same multiply.
Two spellings bracket the target: one local gives the correct sub esp,0x10
frame but an interleaved copy (10 insns off), while a separate decompressed
local gives the correct grouped aliasing-safe copy but a 12-byte-too-large
frame (2 bytes off). January needs both. The one-local form is landed
because a frame-size mismatch is structural under the campaign's
frame-layout law, so the byte-closer variant is the wrong reconstruction.
Copy-schedule variants measured inert: named pointer, inner-scoped pointer,
declaration order, and combinations. Naming the packed value regresses to
528 bytes.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Four previously unwritten functions strict exact on first compile:
compress_real_to_int8 (96B), _int8_clamp (80B), _int16 (112B), _int16_clamp
(96B). Object 9/19 -> 13/19; board 4,822 -> 4,826 functions and 667,591 ->
667,975 strict code bytes, with no previously exact function changed.
These are the oracles the fast_ftol attribution predicted - each ends in
fld <param>; fistp <local>, which no ordinary C conversion emits under this
compiler - so they were unreachable until the helper was admitted today.
January pins two details: the scaled value is reassigned into the PARAMETER
rather than a fresh local, and the clamp variants fold PIN into the same
multiply-and-store statement. The int16 pair round through
(real)floor(z * 32767.5f).
get_vertex_size is blocked by a header disagreement, recorded rather than
forced: January asserts type < 12 and indexes a 12-entry table, while the
repository enum has 18 members after importing six later types. The
recovered table is in the ledger for whoever corrects the enum under a full
board rebuild.
uncompress_int32_to_real_vector3d is fully decoded but left unwritten: two
spellings give 128 and 112 bytes against January's 144, which stages results
through float locals. Not landed non-exact.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>