diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2011-02-01 23:22:34 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2011-02-01 23:22:34 +0000 |
commit | ccd5259d33cbbdd6f5fbf7ccab4cb4a2702309ea (patch) | |
tree | fbbf276e87148ef59204fd1cf98a467bccc3556d /lib/CodeGen/CGClass.cpp | |
parent | 110a68e38bb37526f9bd1d4e8f1b941fe5410b27 (diff) |
-fapple-kext support for indirect call to virtuals dtors - wip.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124701 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGClass.cpp')
-rw-r--r-- | lib/CodeGen/CGClass.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/CodeGen/CGClass.cpp b/lib/CodeGen/CGClass.cpp index 7efd2bc807..f4a45e4f61 100644 --- a/lib/CodeGen/CGClass.cpp +++ b/lib/CodeGen/CGClass.cpp @@ -1264,7 +1264,12 @@ void CodeGenFunction::EmitCXXDestructorCall(const CXXDestructorDecl *DD, llvm::Value *This) { llvm::Value *VTT = GetVTTParameter(*this, GlobalDecl(DD, Type), ForVirtualBase); - llvm::Value *Callee = CGM.GetAddrOfCXXDestructor(DD, Type); + llvm::Value *Callee = 0; + if (getContext().getLangOptions().AppleKext) + Callee = BuildAppleKextVirtualDestructorCall(DD, Type); + + if (!Callee) + Callee = CGM.GetAddrOfCXXDestructor(DD, Type); EmitCXXMemberCall(DD, Callee, ReturnValueSlot(), This, VTT, 0, 0); } |