Skip to content

Commit

Permalink
[WebAssembly] Update utility functions with SIMD types
Browse files Browse the repository at this point in the history
Reviewers: aheejin, dschuff

Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits

Differential Revision: https://reviews.llvm.org/D51516

llvm-svn: 341131
  • Loading branch information
tlively committed Aug 30, 2018
1 parent b737d4d commit abf6bdc
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions llvm/lib/Target/WebAssembly/WebAssemblyUtilities.cpp
Expand Up @@ -63,6 +63,8 @@ bool WebAssembly::isCopy(const MachineInstr &MI) {
case WebAssembly::COPY_F32_S:
case WebAssembly::COPY_F64:
case WebAssembly::COPY_F64_S:
case WebAssembly::COPY_V128:
case WebAssembly::COPY_V128_S:
return true;
default:
return false;
Expand All @@ -79,6 +81,8 @@ bool WebAssembly::isTee(const MachineInstr &MI) {
case WebAssembly::TEE_F32_S:
case WebAssembly::TEE_F64:
case WebAssembly::TEE_F64_S:
case WebAssembly::TEE_V128:
case WebAssembly::TEE_V128_S:
return true;
default:
return false;
Expand Down Expand Up @@ -177,6 +181,18 @@ unsigned WebAssembly::getCalleeOpNo(const MachineInstr &MI) {
case WebAssembly::CALL_F32_S:
case WebAssembly::CALL_F64:
case WebAssembly::CALL_F64_S:
case WebAssembly::CALL_v16i8:
case WebAssembly::CALL_v16i8_S:
case WebAssembly::CALL_v8i16:
case WebAssembly::CALL_v8i16_S:
case WebAssembly::CALL_v4i32:
case WebAssembly::CALL_v4i32_S:
case WebAssembly::CALL_v2i64:
case WebAssembly::CALL_v2i64_S:
case WebAssembly::CALL_v4f32:
case WebAssembly::CALL_v4f32_S:
case WebAssembly::CALL_v2f64:
case WebAssembly::CALL_v2f64_S:
case WebAssembly::CALL_EXCEPT_REF:
case WebAssembly::CALL_EXCEPT_REF_S:
case WebAssembly::CALL_INDIRECT_I32:
Expand All @@ -187,6 +203,18 @@ unsigned WebAssembly::getCalleeOpNo(const MachineInstr &MI) {
case WebAssembly::CALL_INDIRECT_F32_S:
case WebAssembly::CALL_INDIRECT_F64:
case WebAssembly::CALL_INDIRECT_F64_S:
case WebAssembly::CALL_INDIRECT_v16i8:
case WebAssembly::CALL_INDIRECT_v16i8_S:
case WebAssembly::CALL_INDIRECT_v8i16:
case WebAssembly::CALL_INDIRECT_v8i16_S:
case WebAssembly::CALL_INDIRECT_v4i32:
case WebAssembly::CALL_INDIRECT_v4i32_S:
case WebAssembly::CALL_INDIRECT_v2i64:
case WebAssembly::CALL_INDIRECT_v2i64_S:
case WebAssembly::CALL_INDIRECT_v4f32:
case WebAssembly::CALL_INDIRECT_v4f32_S:
case WebAssembly::CALL_INDIRECT_v2f64:
case WebAssembly::CALL_INDIRECT_v2f64_S:
case WebAssembly::CALL_INDIRECT_EXCEPT_REF:
case WebAssembly::CALL_INDIRECT_EXCEPT_REF_S:
return 1;
Expand Down

0 comments on commit abf6bdc

Please sign in to comment.