summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/TargetInfo.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-06-26 21:52:32 +0000
committerChris Lattner <sabre@nondot.org>2010-06-26 21:52:32 +0000
commitfa20e95043d754afe785530803a24bd1dad76d5f (patch)
treee5537c65fa7095d2e880dc139f39c1efbfd393dc /clang/lib/CodeGen/TargetInfo.cpp
parent0bf27620f0cd12ba436ae698645cce079611cfb2 (diff)
downloadbcm5719-llvm-fa20e95043d754afe785530803a24bd1dad76d5f.tar.gz
bcm5719-llvm-fa20e95043d754afe785530803a24bd1dad76d5f.zip
use more efficient type comparison predicates.
llvm-svn: 106958
Diffstat (limited to 'clang/lib/CodeGen/TargetInfo.cpp')
-rw-r--r--clang/lib/CodeGen/TargetInfo.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/TargetInfo.cpp b/clang/lib/CodeGen/TargetInfo.cpp
index 1de0ebc41c3..667220063b6 100644
--- a/clang/lib/CodeGen/TargetInfo.cpp
+++ b/clang/lib/CodeGen/TargetInfo.cpp
@@ -1076,7 +1076,7 @@ void X86_64ABIInfo::classify(QualType Ty,
ABIArgInfo X86_64ABIInfo::getCoerceResult(QualType Ty,
const llvm::Type *CoerceTo,
ASTContext &Context) const {
- if (CoerceTo == llvm::Type::getInt64Ty(CoerceTo->getContext())) {
+ if (CoerceTo->isIntegerTy(64)) {
// Integer and pointer types will end up in a general purpose
// register.
@@ -1087,7 +1087,7 @@ ABIArgInfo X86_64ABIInfo::getCoerceResult(QualType Ty,
if (Ty->isIntegralOrEnumerationType() || Ty->hasPointerRepresentation())
return (Ty->isPromotableIntegerType() ?
ABIArgInfo::getExtend() : ABIArgInfo::getDirect());
- } else if (CoerceTo == llvm::Type::getDoubleTy(CoerceTo->getContext())) {
+ } else if (CoerceTo->isDoubleTy()) {
assert(Ty.isCanonical() && "should always have a canonical type here");
assert(!Ty.hasQualifiers() && "should never have a qualified type here");
OpenPOWER on IntegriCloud