summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-08-15 15:16:50 +0000
committerChris Lattner <sabre@nondot.org>2008-08-15 15:16:50 +0000
commit2fdbcfb576961cea678f32474ef1924f94faeebc (patch)
tree2bfa827e691c6f17d5997d4c82f759210db5fcbd /llvm/lib
parent86834d29f3a7f4a141c79474f41af202d76304b2 (diff)
downloadbcm5719-llvm-2fdbcfb576961cea678f32474ef1924f94faeebc.tar.gz
bcm5719-llvm-2fdbcfb576961cea678f32474ef1924f94faeebc.zip
Inline the fastpath of PATypeHolder::get(). This is a small speedup in
instcombine among other things. llvm-svn: 54814
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/VMCore/Type.cpp15
1 files changed, 0 insertions, 15 deletions
diff --git a/llvm/lib/VMCore/Type.cpp b/llvm/lib/VMCore/Type.cpp
index b7bf339ab8d..be211949799 100644
--- a/llvm/lib/VMCore/Type.cpp
+++ b/llvm/lib/VMCore/Type.cpp
@@ -35,21 +35,6 @@ AbstractTypeUser::~AbstractTypeUser() {}
//===----------------------------------------------------------------------===//
-// Type PATypeHolder Implementation
-//===----------------------------------------------------------------------===//
-
-/// get - This implements the forwarding part of the union-find algorithm for
-/// abstract types. Before every access to the Type*, we check to see if the
-/// type we are pointing to is forwarding to a new type. If so, we drop our
-/// reference to the type.
-///
-Type* PATypeHolder::get() const {
- const Type *NewTy = Ty->getForwardedType();
- if (!NewTy) return const_cast<Type*>(Ty);
- return *const_cast<PATypeHolder*>(this) = NewTy;
-}
-
-//===----------------------------------------------------------------------===//
// Type Class Implementation
//===----------------------------------------------------------------------===//
OpenPOWER on IntegriCloud