summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h
diff options
context:
space:
mode:
authorThomas Lively <tlively@google.com>2019-10-30 13:22:13 -0700
committerThomas Lively <tlively@google.com>2019-10-31 14:59:30 -0700
commit2ab1b8c1ec452fb743f6cc5051e75a01039cabfe (patch)
treeb2994a17a4347a0efb3537dcfacb5325906dc7d1 /llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h
parent80c03fb5c2755d0b91d3437b8b9bc4c8a8393542 (diff)
downloadbcm5719-llvm-2ab1b8c1ec452fb743f6cc5051e75a01039cabfe.tar.gz
bcm5719-llvm-2ab1b8c1ec452fb743f6cc5051e75a01039cabfe.zip
[WebAssembly] Handle multiple loads of splatted loads
Summary: Fixes an ISel failure when a splatted load is used more than once. The failure was due to the hacks we were doing in ISel lowering to preserve the original load as the operand of a LOAD_SPLAT node. The fix is to properly lower the splatted use of the load to a separate LOAD_SPLAT node. Reviewers: aheejin Subscribers: dschuff, sbc100, jgravelle-google, hiraditya, sunfish, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D69640
Diffstat (limited to 'llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h')
-rw-r--r--llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h b/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h
index 90936670c47..58e088a0ba5 100644
--- a/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h
+++ b/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h
@@ -24,8 +24,16 @@ namespace WebAssemblyISD {
enum NodeType : unsigned {
FIRST_NUMBER = ISD::BUILTIN_OP_END,
#define HANDLE_NODETYPE(NODE) NODE,
+#define HANDLE_MEM_NODETYPE(NODE)
#include "WebAssemblyISD.def"
+ FIRST_MEM_OPCODE = ISD::FIRST_TARGET_MEMORY_OPCODE,
#undef HANDLE_NODETYPE
+#undef HANDLE_MEM_NODETYPE
+#define HANDLE_NODETYPE(NODE)
+#define HANDLE_MEM_NODETYPE(NODE) NODE,
+#include "WebAssemblyISD.def"
+#undef HANDLE_NODETYPE
+#undef HANDLE_MEM_NODETYPE
};
} // end namespace WebAssemblyISD
OpenPOWER on IntegriCloud