aboutsummaryrefslogtreecommitdiffstats
path: root/lib/CodeGen/PseudoSourceValue.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2008-12-03 21:37:21 +0000
committerDan Gohman <gohman@apple.com>2008-12-03 21:37:21 +0000
commitde2163821ddbffb3ac78b7f0e1060b0754e9a502 (patch)
treefc1e18f70a58f40a047e8051090cc01842a5e1dd /lib/CodeGen/PseudoSourceValue.cpp
parent48e16f9429bb1cadf522841c06fcf3bb53397e26 (diff)
downloadexternal_llvm-de2163821ddbffb3ac78b7f0e1060b0754e9a502.zip
external_llvm-de2163821ddbffb3ac78b7f0e1060b0754e9a502.tar.gz
external_llvm-de2163821ddbffb3ac78b7f0e1060b0754e9a502.tar.bz2
Have PseudoSourceValue override Value::dump, so that it works
on PseudoSourceValue values. This also fixes a FIXME in lib/VMCode/AsmWriter.cpp. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60507 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/PseudoSourceValue.cpp')
-rw-r--r--lib/CodeGen/PseudoSourceValue.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/CodeGen/PseudoSourceValue.cpp b/lib/CodeGen/PseudoSourceValue.cpp
index 5247906..d0ea706 100644
--- a/lib/CodeGen/PseudoSourceValue.cpp
+++ b/lib/CodeGen/PseudoSourceValue.cpp
@@ -41,6 +41,10 @@ static const char *const PSVNames[] = {
PseudoSourceValue::PseudoSourceValue() :
Value(PointerType::getUnqual(Type::Int8Ty), PseudoSourceValueVal) {}
+void PseudoSourceValue::dump() const {
+ print(errs()); errs() << '\n'; errs().flush();
+}
+
void PseudoSourceValue::print(raw_ostream &OS) const {
OS << PSVNames[this - *PSVs];
}