SelectionDAG::dump() should print SrcValue of LoadSDNode and StoreSDNode.

llvm-svn: 45151
This commit is contained in:
Evan Cheng 2007-12-18 07:02:08 +00:00
parent 9a2e3cb48d
commit e2dbba5828
1 changed files with 18 additions and 0 deletions

View File

@ -3958,6 +3958,15 @@ void SDNode::dump(const SelectionDAG *G) const {
const char *AM = getIndexedModeName(LD->getAddressingMode()); const char *AM = getIndexedModeName(LD->getAddressingMode());
if (*AM) if (*AM)
cerr << " " << AM; cerr << " " << AM;
const Value *SrcValue = LD->getSrcValue();
int SrcOffset = LD->getSrcValueOffset();
cerr << " <";
if (SrcValue)
cerr << SrcValue;
else
cerr << "null";
cerr << ":" << SrcOffset << ">";
} else if (const StoreSDNode *ST = dyn_cast<StoreSDNode>(this)) { } else if (const StoreSDNode *ST = dyn_cast<StoreSDNode>(this)) {
if (ST->isTruncatingStore()) if (ST->isTruncatingStore())
cerr << " <trunc " cerr << " <trunc "
@ -3966,6 +3975,15 @@ void SDNode::dump(const SelectionDAG *G) const {
const char *AM = getIndexedModeName(ST->getAddressingMode()); const char *AM = getIndexedModeName(ST->getAddressingMode());
if (*AM) if (*AM)
cerr << " " << AM; cerr << " " << AM;
const Value *SrcValue = ST->getSrcValue();
int SrcOffset = ST->getSrcValueOffset();
cerr << " <";
if (SrcValue)
cerr << SrcValue;
else
cerr << "null";
cerr << ":" << SrcOffset << ">";
} }
} }