diff options
| author | Anders Carlsson <andersca@mac.com> | 2009-12-04 02:14:12 +0000 |
|---|---|---|
| committer | Anders Carlsson <andersca@mac.com> | 2009-12-04 02:14:12 +0000 |
| commit | 597c776c414351f565b558308946c509fd79bf51 (patch) | |
| tree | 05567b777eb5071b1d80669a8901425bcd0d7eaa /clang/lib | |
| parent | f3da334da6f95d47419b04f1a865010c59da8616 (diff) | |
| download | bcm5719-llvm-597c776c414351f565b558308946c509fd79bf51.tar.gz bcm5719-llvm-597c776c414351f565b558308946c509fd79bf51.zip | |
Remove the GlobalDecl from the Thunk as well.
llvm-svn: 90522
Diffstat (limited to 'clang/lib')
| -rw-r--r-- | clang/lib/CodeGen/CGVtable.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/clang/lib/CodeGen/CGVtable.cpp b/clang/lib/CodeGen/CGVtable.cpp index 5cbeeb46a1b..271558fb93d 100644 --- a/clang/lib/CodeGen/CGVtable.cpp +++ b/clang/lib/CodeGen/CGVtable.cpp @@ -118,11 +118,9 @@ private: struct Thunk { Thunk() { } - Thunk(GlobalDecl GD, const ThunkAdjustment &Adjustment) - : GD(GD), Adjustment(Adjustment) { } + Thunk(const ThunkAdjustment &Adjustment) + : Adjustment(Adjustment) { } - GlobalDecl GD; - /// Adjustment - The thunk adjustment. ThunkAdjustment Adjustment; }; @@ -351,9 +349,9 @@ public: for (ThunksMapTy::const_iterator i = Thunks.begin(), e = Thunks.end(); i != e; ++i) { uint64_t Index = i->first; + GlobalDecl GD = Methods[Index]; const Thunk& Thunk = i->second; - GlobalDecl GD = Thunk.GD; const CXXMethodDecl *MD = cast<CXXMethodDecl>(GD.getDecl()); assert(!MD->isPure() && "Can't thunk pure virtual methods!"); @@ -907,7 +905,7 @@ bool VtableBuilder::OverrideMethod(GlobalDecl GD, llvm::Constant *m, VirtualAdjustment); if (!isPure && !ThisAdjustment.isEmpty()) - Thunks[i] = Thunk(GD, ThisAdjustment); + Thunks[i] = Thunk(ThisAdjustment); return true; } @@ -918,7 +916,7 @@ bool VtableBuilder::OverrideMethod(GlobalDecl GD, llvm::Constant *m, ThunkAdjustment ThisAdjustment(NonVirtualAdjustment, 0); if (!isPure) - Thunks[i] = Thunk(GD, ThisAdjustment); + Thunks[i] = Thunk(ThisAdjustment); } return true; } |

