diff options
author | Dan Gohman <gohman@apple.com> | 2007-08-20 19:23:34 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2007-08-20 19:23:34 +0000 |
commit | 3a0714836e842533aa2a47385ad8290e7d63cafa (patch) | |
tree | 322db3852083fa9bbf426acd55f67c3f9e04f34e /llvm/lib/VMCore/Function.cpp | |
parent | 1d8e521022a77a61ee04bc40b0d7f8d11d19ed18 (diff) | |
download | bcm5719-llvm-3a0714836e842533aa2a47385ad8290e7d63cafa.tar.gz bcm5719-llvm-3a0714836e842533aa2a47385ad8290e7d63cafa.zip |
When Intrinsic::getName is constructing names for overloaded intrinsics,
use the ValueType name instead of the llvm type name, to match what the
verifier expects. For integers these are the same, but for floating-point
values the intrinsics use f32/f64 instead of float/double.
llvm-svn: 41189
Diffstat (limited to 'llvm/lib/VMCore/Function.cpp')
-rw-r--r-- | llvm/lib/VMCore/Function.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/VMCore/Function.cpp b/llvm/lib/VMCore/Function.cpp index 04541dfbfdc..a4bc69b4721 100644 --- a/llvm/lib/VMCore/Function.cpp +++ b/llvm/lib/VMCore/Function.cpp @@ -15,6 +15,7 @@ #include "llvm/DerivedTypes.h" #include "llvm/ParameterAttributes.h" #include "llvm/IntrinsicInst.h" +#include "llvm/CodeGen/ValueTypes.h" #include "llvm/Support/LeakDetector.h" #include "llvm/Support/ManagedStatic.h" #include "SymbolTableListTraitsImpl.h" @@ -287,7 +288,7 @@ std::string Intrinsic::getName(ID id, const Type **Tys, unsigned numTys) { std::string Result(Table[id]); for (unsigned i = 0; i < numTys; ++i) if (Tys[i]) - Result += "." + Tys[i]->getDescription(); + Result += "." + MVT::getValueTypeString(MVT::getValueType(Tys[i])); return Result; } |