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

Anders Carlsson andersca at mac.com
Mon Mar 22 09:11:00 PDT 2010


Author: andersca
Date: Mon Mar 22 11:10:59 2010
New Revision: 99181

URL: http://llvm.org/viewvc/llvm-project?rev=99181&view=rev
Log:
Improve dumping of thunks.

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=99181&r1=99180&r2=99181&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CGVtable.cpp (original)
+++ cfe/trunk/lib/CodeGen/CGVtable.cpp Mon Mar 22 11:10:59 2010
@@ -2306,14 +2306,27 @@
 
         Out << llvm::format("%4d | ", I);
         
+        // If this function pointer has a return pointer adjustment, dump it.
+        if (!Thunk.Return.isEmpty()) {
+          Out << "return adjustment: " << Thunk.This.NonVirtual;
+          Out << " non-virtual";
+          if (Thunk.Return.VBaseOffsetOffset) {
+            Out << ", " << Thunk.Return.VBaseOffsetOffset;
+            Out << " vbase offset offset";
+          }
+
+          if (!Thunk.This.isEmpty())
+            Out << "\n       ";
+        }
+
         // If this function pointer has a 'this' pointer adjustment, dump it.
         if (!Thunk.This.isEmpty()) {
-          Out << "this: ";
-          Out << Thunk.This.NonVirtual << " nv";
+          Out << "this adjustment: ";
+          Out << Thunk.This.NonVirtual << " non-virtual";
           
           if (Thunk.This.VCallOffsetOffset) {
             Out << ", " << Thunk.This.VCallOffsetOffset;
-            Out << " v";
+            Out << " vcall offset offset";
           }
         }
         





More information about the cfe-commits mailing list