[cfe-commits] r90747 - /cfe/trunk/lib/CodeGen/CGVtable.cpp

Eli Friedman eli.friedman at gmail.com
Sun Dec 6 20:45:50 PST 2009


Author: efriedma
Date: Sun Dec  6 22:45:50 2009
New Revision: 90747

URL: http://llvm.org/viewvc/llvm-project?rev=90747&view=rev
Log:
Erm, revert for the moment; I didn't test this as thoroughly as I should have
(although it does pass regression tests).


Modified:
    cfe/trunk/lib/CodeGen/CGVtable.cpp

Modified: cfe/trunk/lib/CodeGen/CGVtable.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGVtable.cpp?rev=90747&r1=90746&r2=90747&view=diff

==============================================================================
--- cfe/trunk/lib/CodeGen/CGVtable.cpp (original)
+++ cfe/trunk/lib/CodeGen/CGVtable.cpp Sun Dec  6 22:45:50 2009
@@ -376,9 +376,8 @@
 
     D1(printf("  vfn for %s at %d\n", MD->getNameAsString().c_str(),
               (int)Index[GD]));
-
-    VCallOffset[GD] = Offset/8;
     if (MorallyVirtual) {
+      VCallOffset[GD] = Offset/8;
       Index_t &idx = VCall[GD];
       // Allocate the first one, after that, we reuse the previous one.
       if (idx == 0) {
@@ -845,7 +844,8 @@
       return true;
     }
 
-    int64_t NonVirtualAdjustment = -VCallOffset[OGD] + OverrideOffset/8;
+    // FIXME: finish off
+    int64_t NonVirtualAdjustment = VCallOffset[OGD] - OverrideOffset/8;
 
     if (NonVirtualAdjustment) {
       ThunkAdjustment ThisAdjustment(NonVirtualAdjustment, 0);





More information about the cfe-commits mailing list