ReviewOS

zig-utils/zig-js

WebAssembly SIMD: floating lanes and numeric conversions

#282
Closed chris opened this 9 days ago ·
9 days ago

Parent: #264 Depends on: #279, #280 Roadmap: #142, #134

Complete f32x4/f64x2 and SIMD conversion semantics with lane-exact observable behavior.

Acceptance:

  • Implement float comparisons, arithmetic, abs/neg/sqrt, rounding, min/max, and pseudo-min/max.
  • Implement integer/float conversions, trunc_sat, promote/demote, and low-lane zeroing rules.
  • Preserve signed zero and exact non-NaN bits; implement the specification-permitted NaN result rules without hiding mismatches.
  • Keep a portable scalar oracle/fallback and compare optimized paths lane-for-lane where available.
  • Publish per-family focused official-corpus totals with zero hidden exclusions.
9 days ago

First portable float checkpoint is on main as 6306ed59: f32x4/f64x2 comparisons, abs/neg/sqrt, add/sub/mul/div, specification min/max helpers, and f32x4↔i32x4 saturating conversions. It clears #280’s last 13 shared-file execution failures; the terminal movement inventory is now 2,253/2,253 applicable with zero failures (9aa42500). Full rounding, pseudo-min/max, promote/demote, f64 conversions, and NaN-rule corpus scoring remain here.

9 days ago

Completed on main: 16361aba finishes rounding, pseudo-min/max, promote/demote, low-lane conversions, signed-zero behavior, and quiet-NaN rules; b5a9876a adds lane-aware canonical/arithmetic NaN scoring; ceaedf3d publishes the terminal README/docs score.

Across all 13 focused official float/conversion files: 19,106/19,106 applicable pass, 0 fail, 98 explicit text-format n/a, 0 runner errors. The two 3,887-command pseudo-min/max files were evaluated ReleaseFast and are fully green. There is no native acceleration, so the portable implementation is the runtime path and scalar oracle. All five acceptance items are checked.

Sign in to comment on this issue.