[PATCH] D105755: [WebAssembly] Custom combines for f32x4.demote_zero_f64x2

Thomas Lively via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 12 11:38:01 PDT 2021


tlively added inline comments.


================
Comment at: clang/include/clang/Basic/BuiltinsWebAssembly.def:192-193
 
 TARGET_BUILTIN(__builtin_wasm_trunc_sat_zero_s_f64x2_i32x4, "V4iV2d", "nc", "simd128")
 TARGET_BUILTIN(__builtin_wasm_trunc_sat_zero_u_f64x2_i32x4, "V4UiV2d", "nc", "simd128")
-TARGET_BUILTIN(__builtin_wasm_demote_zero_f64x2_f32x4, "V4fV2d", "nc", "simd128")
----------------
tlively wrote:
> aheejin wrote:
> > If these share the same pattern, do we need these builtins?
> Hmm, good point. Maybe not. I'll investigate that in a follow up.
Ah, the reason we can't remove these builtins is because there is no good target-independent way to represent the saturating behavior of the float-to-int conversion.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D105755/new/

https://reviews.llvm.org/D105755



More information about the llvm-commits mailing list