diff options
| author | Thomas Lively <tlively@google.com> | 2019-12-13 17:08:04 -0800 |
|---|---|---|
| committer | Thomas Lively <tlively@google.com> | 2019-12-16 11:48:49 -0800 |
| commit | 3a93756dfbb0dcb7c62fcbe5b0ab8f8591fc9721 (patch) | |
| tree | 25092e97aee0e2bc19cf499520ed7693722f9e56 /clang/test/CodeGen | |
| parent | cc802ea67beb66d2f8a935e647c3aedcf7848211 (diff) | |
| download | bcm5719-llvm-3a93756dfbb0dcb7c62fcbe5b0ab8f8591fc9721.tar.gz bcm5719-llvm-3a93756dfbb0dcb7c62fcbe5b0ab8f8591fc9721.zip | |
[WebAssembly] Replace SIMD int min/max builtins with patterns
Summary:
The instructions were originally implemented via builtins and
intrinsics so users would have to explicitly opt-in to using
them. This was useful while were validating whether these instructions
should have been merged into the spec proposal. Now that they have
been, we can use normal codegen patterns, so the intrinsics and
builtins are no longer useful.
Reviewers: aheejin
Subscribers: dschuff, sbc100, jgravelle-google, hiraditya, sunfish, cfe-commits, llvm-commits
Tags: #clang, #llvm
Differential Revision: https://reviews.llvm.org/D71500
Diffstat (limited to 'clang/test/CodeGen')
| -rw-r--r-- | clang/test/CodeGen/builtins-wasm.c | 84 |
1 files changed, 0 insertions, 84 deletions
diff --git a/clang/test/CodeGen/builtins-wasm.c b/clang/test/CodeGen/builtins-wasm.c index eea51eb71b6..7ea32feb051 100644 --- a/clang/test/CodeGen/builtins-wasm.c +++ b/clang/test/CodeGen/builtins-wasm.c @@ -352,90 +352,6 @@ i16x8 sub_saturate_u_i16x8(i16x8 x, i16x8 y) { // WEBASSEMBLY-NEXT: ret } -i8x16 min_s_i8x16(i8x16 x, i8x16 y) { - return __builtin_wasm_min_s_i8x16(x, y); - // WEBASSEMBLY: call <16 x i8> @llvm.wasm.min.signed.v16i8( - // WEBASSEMBLY-SAME: <16 x i8> %x, <16 x i8> %y) - // WEBASSEMBLY-NEXT: ret -} - -i8x16 min_u_i8x16(i8x16 x, i8x16 y) { - return __builtin_wasm_min_u_i8x16(x, y); - // WEBASSEMBLY: call <16 x i8> @llvm.wasm.min.unsigned.v16i8( - // WEBASSEMBLY-SAME: <16 x i8> %x, <16 x i8> %y) - // WEBASSEMBLY-NEXT: ret -} - -i8x16 max_s_i8x16(i8x16 x, i8x16 y) { - return __builtin_wasm_max_s_i8x16(x, y); - // WEBASSEMBLY: call <16 x i8> @llvm.wasm.max.signed.v16i8( - // WEBASSEMBLY-SAME: <16 x i8> %x, <16 x i8> %y) - // WEBASSEMBLY-NEXT: ret -} - -i8x16 max_u_i8x16(i8x16 x, i8x16 y) { - return __builtin_wasm_max_u_i8x16(x, y); - // WEBASSEMBLY: call <16 x i8> @llvm.wasm.max.unsigned.v16i8( - // WEBASSEMBLY-SAME: <16 x i8> %x, <16 x i8> %y) - // WEBASSEMBLY-NEXT: ret -} - -i16x8 min_s_i16x8(i16x8 x, i16x8 y) { - return __builtin_wasm_min_s_i16x8(x, y); - // WEBASSEMBLY: call <8 x i16> @llvm.wasm.min.signed.v8i16( - // WEBASSEMBLY-SAME: <8 x i16> %x, <8 x i16> %y) - // WEBASSEMBLY-NEXT: ret -} - -i16x8 min_u_i16x8(i16x8 x, i16x8 y) { - return __builtin_wasm_min_u_i16x8(x, y); - // WEBASSEMBLY: call <8 x i16> @llvm.wasm.min.unsigned.v8i16( - // WEBASSEMBLY-SAME: <8 x i16> %x, <8 x i16> %y) - // WEBASSEMBLY-NEXT: ret -} - -i16x8 max_s_i16x8(i16x8 x, i16x8 y) { - return __builtin_wasm_max_s_i16x8(x, y); - // WEBASSEMBLY: call <8 x i16> @llvm.wasm.max.signed.v8i16( - // WEBASSEMBLY-SAME: <8 x i16> %x, <8 x i16> %y) - // WEBASSEMBLY-NEXT: ret -} - -i16x8 max_u_i16x8(i16x8 x, i16x8 y) { - return __builtin_wasm_max_u_i16x8(x, y); - // WEBASSEMBLY: call <8 x i16> @llvm.wasm.max.unsigned.v8i16( - // WEBASSEMBLY-SAME: <8 x i16> %x, <8 x i16> %y) - // WEBASSEMBLY-NEXT: ret -} - -i32x4 min_s_i32x4(i32x4 x, i32x4 y) { - return __builtin_wasm_min_s_i32x4(x, y); - // WEBASSEMBLY: call <4 x i32> @llvm.wasm.min.signed.v4i32( - // WEBASSEMBLY-SAME: <4 x i32> %x, <4 x i32> %y) - // WEBASSEMBLY-NEXT: ret -} - -i32x4 min_u_i32x4(i32x4 x, i32x4 y) { - return __builtin_wasm_min_u_i32x4(x, y); - // WEBASSEMBLY: call <4 x i32> @llvm.wasm.min.unsigned.v4i32( - // WEBASSEMBLY-SAME: <4 x i32> %x, <4 x i32> %y) - // WEBASSEMBLY-NEXT: ret -} - -i32x4 max_s_i32x4(i32x4 x, i32x4 y) { - return __builtin_wasm_max_s_i32x4(x, y); - // WEBASSEMBLY: call <4 x i32> @llvm.wasm.max.signed.v4i32( - // WEBASSEMBLY-SAME: <4 x i32> %x, <4 x i32> %y) - // WEBASSEMBLY-NEXT: ret -} - -i32x4 max_u_i32x4(i32x4 x, i32x4 y) { - return __builtin_wasm_max_u_i32x4(x, y); - // WEBASSEMBLY: call <4 x i32> @llvm.wasm.max.unsigned.v4i32( - // WEBASSEMBLY-SAME: <4 x i32> %x, <4 x i32> %y) - // WEBASSEMBLY-NEXT: ret -} - i32x4 dot_i16x8_s(i16x8 x, i16x8 y) { return __builtin_wasm_dot_s_i32x4_i16x8(x, y); // WEBASSEMBLY: call <4 x i32> @llvm.wasm.dot(<8 x i16> %x, <8 x i16> %y) |

