[PATCH] D11956: WebAssembly: implement WebAssemblyTargetLowering::getTargetNodeName
JF Bastien via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 11 13:14:05 PDT 2015
This revision was automatically updated to reflect the committed changes.
Closed by commit rL244655: WebAssembly: implement WebAssemblyTargetLowering::getTargetNodeName (authored by jfb).
Changed prior to commit:
http://reviews.llvm.org/D11956?vs=31853&id=31854#toc
Repository:
rL LLVM
http://reviews.llvm.org/D11956
Files:
llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.h
Index: llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.h
===================================================================
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.h
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.h
@@ -22,7 +22,7 @@
namespace WebAssemblyISD {
-enum {
+enum NodeType : unsigned {
FIRST_NUMBER = ISD::BUILTIN_OP_END,
RETURN,
ARGUMENT,
@@ -47,6 +47,8 @@
MVT getScalarShiftAmountTy(const DataLayout &DL, EVT) const override;
+ const char *getTargetNodeName(unsigned Opcode) const override;
+
bool CanLowerReturn(CallingConv::ID CallConv, MachineFunction &MF,
bool isVarArg,
const SmallVectorImpl<ISD::OutputArg> &Outs,
Index: llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
===================================================================
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
@@ -120,6 +120,16 @@
return VT.getSimpleVT();
}
+const char *
+WebAssemblyTargetLowering::getTargetNodeName(unsigned Opcode) const {
+ switch (static_cast<WebAssemblyISD::NodeType>(Opcode)) {
+ case WebAssemblyISD::FIRST_NUMBER: break;
+ case WebAssemblyISD::RETURN: return "WebAssemblyISD::RETURN";
+ case WebAssemblyISD::ARGUMENT: return "WebAssemblyISD::ARGUMENT";
+ }
+ return nullptr;
+}
+
//===----------------------------------------------------------------------===//
// WebAssembly Lowering private implementation.
//===----------------------------------------------------------------------===//
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D11956.31854.patch
Type: text/x-patch
Size: 1640 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150811/c39e9e15/attachment.bin>
More information about the llvm-commits
mailing list