You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Preserve representable subnormal results for negative integer powers #557
pow_f32_i32 and pow_f64_i32 first compute the positive power, then take its reciprocal for negative exponents. If the positive power overflows, the reciprocal becomes zero even when the actual negative power is representable as a subnormal. Examples are pow_f32_i32(2.0, -128) and pow_f64_i32(2.0, -1024). This is premature intermediate overflow, not unavoidable underflow of the requested result.
Handle negative exponents without requiring an overflowing positive-power intermediate.
Add exact power-of-two subnormal cases, including the smallest representable power where supported.
Retain behavior for exponent zero, minimum i32 exponent, negative bases with odd/even exponents, signed zero and non-finite inputs.
Verify normal-range powers as well as underflow/overflow boundaries without adding a math-library dependency.
Audit status: static source inspection against canonical master ea74c2dafc31da876e5561f2d176ba719f5a0458 on 2026-09-10. No compiler build, test execution, implementation change or local reproduction was performed for this report. The examples describe the source-derived behavior to verify when implementing the fix.
Activity
fix: preserve numeric results, file data, and I/O deadlines (wavefnd#631