Remove the GlobalDecl from the Thunk as well.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90522 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/CGVtable.cpp b/lib/CodeGen/CGVtable.cpp
index 5cbeeb4..271558f 100644
--- a/lib/CodeGen/CGVtable.cpp
+++ b/lib/CodeGen/CGVtable.cpp
@@ -118,11 +118,9 @@
   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 @@
     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 @@
                                        VirtualAdjustment);
 
         if (!isPure && !ThisAdjustment.isEmpty())
-          Thunks[i] = Thunk(GD, ThisAdjustment);
+          Thunks[i] = Thunk(ThisAdjustment);
         return true;
       }
 
@@ -918,7 +916,7 @@
         ThunkAdjustment ThisAdjustment(NonVirtualAdjustment, 0);
         
         if (!isPure)
-          Thunks[i] = Thunk(GD, ThisAdjustment);
+          Thunks[i] = Thunk(ThisAdjustment);
       }
       return true;
     }