[PATCH] D100596: [WebAssembly] Remove saturating fp-to-int target intrinsics

Thomas Lively via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Apr 15 13:38:59 PDT 2021


tlively created this revision.
tlively added reviewers: aheejin, dschuff.
Herald added subscribers: wingo, ecnelises, sunfish, hiraditya, jgravelle-google, sbc100.
tlively requested review of this revision.
Herald added projects: clang, LLVM.
Herald added subscribers: llvm-commits, cfe-commits.

Use the target-independent @llvm.fptosi and @llvm.fptoui intrinsics instead.
This includes removing the instrinsics for i32x4.trunc_sat_zero_f64x2_{s,u},
which are now represented in IR as a saturating truncation to a v2i32 followed by
a concatenation with a zero vector.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D100596

Files:
  clang/lib/CodeGen/CGBuiltin.cpp
  clang/test/CodeGen/builtins-wasm.c
  llvm/include/llvm/IR/IntrinsicsWebAssembly.td
  llvm/lib/Analysis/ConstantFolding.cpp
  llvm/lib/Target/WebAssembly/WebAssemblyISD.def
  llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
  llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h
  llvm/lib/Target/WebAssembly/WebAssemblyInstrConv.td
  llvm/lib/Target/WebAssembly/WebAssemblyInstrSIMD.td
  llvm/test/CodeGen/WebAssembly/conv.ll
  llvm/test/CodeGen/WebAssembly/simd-intrinsics.ll
  llvm/test/Transforms/InstSimplify/ConstProp/WebAssembly/trunc_saturate.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D100596.337888.patch
Type: text/x-patch
Size: 64199 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210415/b908a0db/attachment-0001.bin>


More information about the cfe-commits mailing list