Summary: Implementation is the same as in AArch64.
Subscribers: aemerson, jfb, llvm-commits, sunfish
Differential Revision: http://reviews.llvm.org/D11956
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@244655
91177308-0d34-0410-b5e6-
96231b3b80d8
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.
//===----------------------------------------------------------------------===//
namespace WebAssemblyISD {
-enum {
+enum NodeType : unsigned {
FIRST_NUMBER = ISD::BUILTIN_OP_END,
RETURN,
ARGUMENT,
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,