diff options
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp index c0d6b54a4b..75c0cb337e 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp @@ -130,6 +130,27 @@ std::string DOTGraphTraits<SelectionDAG*>::getNodeLabel(const SDNode *Node, Op = Op + " VT=" + getValueTypeString(N->getVT()); } else if (const StringSDNode *N = dyn_cast<StringSDNode>(Node)) { Op = Op + "\"" + N->getValue() + "\""; + } else if (const LoadSDNode *LD = dyn_cast<LoadSDNode>(Node)) { + bool doExt = true; + switch (LD->getExtensionType()) { + default: doExt = false; break; + case ISD::EXTLOAD: + Op = Op + "<anyext "; + break; + case ISD::SEXTLOAD: + Op = Op + " <sext "; + break; + case ISD::ZEXTLOAD: + Op = Op + " <zext "; + break; + } + if (doExt) + Op = Op + MVT::getValueTypeString(LD->getLoadVT()) + ">"; + + if (LD->getAddressingMode() == ISD::PRE_INDEXED) + Op = Op + "<pre>"; + else if (LD->getAddressingMode() == ISD::POST_INDEXED) + Op = Op + "<post>"; } return Op; |