diff options
author | John McCall <rjmccall@apple.com> | 2010-02-16 22:04:33 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2010-02-16 22:04:33 +0000 |
commit | 347132b32f69c9d4abb1cdcb5329f56f98904440 (patch) | |
tree | 605ce847ef56ec8a09586059b3e60b816f15b687 /clang/lib/CodeGen/CGClass.cpp | |
parent | 37f106e18c67944888f789a2192cb4cd4928417e (diff) | |
download | bcm5719-llvm-347132b32f69c9d4abb1cdcb5329f56f98904440.tar.gz bcm5719-llvm-347132b32f69c9d4abb1cdcb5329f56f98904440.zip |
IRgen optimization: cache the value of 'this' and 'vtt' instead of
repeatedly reloading from an alloca. We still need to create the alloca
for debug info purposes (although we currently create it in all cases
because of some abstraction boundaries that're hard to break down).
llvm-svn: 96403
Diffstat (limited to 'clang/lib/CodeGen/CGClass.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGClass.cpp | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/clang/lib/CodeGen/CGClass.cpp b/clang/lib/CodeGen/CGClass.cpp index fa5a47f3156..d9051675ba0 100644 --- a/clang/lib/CodeGen/CGClass.cpp +++ b/clang/lib/CodeGen/CGClass.cpp @@ -1405,11 +1405,3 @@ void CodeGenFunction::InitializeVtablePtrsRecursive( // Store address point Builder.CreateStore(VtableAddressPoint, VtableField); } - -llvm::Value *CodeGenFunction::LoadCXXVTT() { - assert((isa<CXXConstructorDecl>(CurFuncDecl) || - isa<CXXDestructorDecl>(CurFuncDecl)) && - "Must be in a C++ ctor or dtor to load the vtt parameter"); - - return Builder.CreateLoad(LocalDeclMap[CXXVTTDecl], "vtt"); -} |