aboutsummaryrefslogtreecommitdiff
path: root/lib/VMCore/Function.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2007-08-20 19:23:34 +0000
committerDan Gohman <gohman@apple.com>2007-08-20 19:23:34 +0000
commit7abff319570dd286f2b9529ea7749fe4f97e47f6 (patch)
tree6fe6c48a3185d9e3992dc1c9719dcab867c8b281 /lib/VMCore/Function.cpp
parent0c6dcbb23b935f3dedddd0d90d81649e9bdd1a30 (diff)
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. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41189 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/Function.cpp')
-rw-r--r--lib/VMCore/Function.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/VMCore/Function.cpp b/lib/VMCore/Function.cpp
index 04541dfbfd..a4bc69b472 100644
--- a/lib/VMCore/Function.cpp
+++ b/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;
}