OE zero requirement follow-up
Bounded follow-up; no REA target was opened and no implementation edited.
Original target identity and exact evidence are already retained in
local/reports/oe-native-1491-evidence.json and the focused record at
local/briefcase-weapon-research/native/0x10090f10-12efe163.txt.
Observed original instructions
Record ev_12efe16371f012aad98ae3486345dafb6f3b6b4c3ffb2b92ead695410d0c6e6b,
original kkr.dll 10090f10, SHA-256
a37bc1c15053fdcc5572772309f7074c4f83baffe2faa164df40b059b7c480c0:
- 10090f4f checks criterion operator == 2.
- 10090f53/59 copy signed requirement value to the denominator local.
- 10090f76 FILDs signed effective actor skill.
- 10090f79 unconditionally FIDIVs by the signed criterion value.
- 10090f7c compares ratio with 1.0; 10090f82..87 tests x87 C0, taking the calculation branch for less-than and unordered.
- Calculation is (10 - 10 * ratio) * .5; 10090f9b calls imported _ftol.
- 10090fa0..a4 takes a signed maximum with the accumulated tier, initially zero. Final clamp is 0..4.
There is no guard for zero or negative denominators and no skill clamp.
Controlled arithmetic probe and derived zero behavior
tmp_oe_zero.c executes these x87 arithmetic/comparison instructions directly,
with exceptions masked, then uses truncating FISTP64 to model _ftol's signed
64-bit conversion. It is not an execution of shipped MSVCRT or the complete
original function. Build:
cc -Wall -Wextra -O0 local/starter-weapon-research/tmp_oe_zero.c -o /tmp/ao-oe-zero-probe.
Results are retained in oe-zero-probe.log.
The current maintained client also represents _ftol as a 64-bit result split
into EDX:EAX: client/runtime/guest_crt.c:459 and
client/runtime/x87crt.c:31. That corroborates the intended conversion width;
its floating-to-integer helper is not the shipped historical CRT.
| Actual | Requirement | Result |
|---|---|---|
| -1 | 0 | Negative infinity; conversion indefinite int64; low32 0; tier 0 |
| 0 | 0 | NaN; unordered comparison enters conversion; low32 0; tier 0 |
| 1 | 0 | Positive infinity; comparison skips calculation; tier 0 |
| -1 | -5 | Ratio .2; candidate 4; tier 4 |
| 0 | -5 | Ratio 0; candidate 5; tier 4 |
| 1 | -5 | Ratio -.2; candidate 6; tier 4 |
| 4 | 5 | Ratio .8; candidate 1; tier 1 |
Recommendation: skip requirement value == 0 before server integer division. Under the ordinary masked x87 / _ftol conversion model, zero-valued criteria cannot increase the OE tier. Document this as derived parity for the zero edge, not an observed native branch. Do not blanket-skip <=0: negative denominators participate in the original signed ratio calculation.
Limits: original shipped MSVCRT _ftol was not executed. Exception-unmasked execution could trap; the probe explicitly models normal masked execution. No original server evidence or dynamic whole-client zero-skill scenario was obtained. The safe server zero guard prevents a Go division panic regardless of those remaining historical/runtime details.