[PATCH] D85392: [WebAssembly][ConstantFolding] Fold fp-to-int truncation intrinsics
Heejin Ahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 10 12:41:52 PDT 2020
aheejin added a comment.
Nice! Just wondering, then are we able to fold most of our SIMD intrinsics here too?
================
Comment at: llvm/test/Analysis/ConstantFolding/WebAssembly/trunc.ll:160
+ store volatile i32 %t14, i32* %p
+ %t15 = call i32 @llvm.wasm.trunc.unsigned.i32.f32(float 0x7ff0000000000000); inf
+ store volatile i32 %t15, i32* %p
----------------
It'd probably be easier to read if there is a comment dividing the instructions that are supposed to be folded and ones that are not, such as
```
; Instructions below this line are not supposed to folded because they are nan or overflow/underflow
```
or something. The same for other functions
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D85392/new/
https://reviews.llvm.org/D85392
More information about the llvm-commits
mailing list