[polly] r311361 - [ManagedMemoryRewrite] slightly tweak debug output style. [NFC]

Siddharth Bhat via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 21 11:58:33 PDT 2017


Author: bollu
Date: Mon Aug 21 11:58:33 2017
New Revision: 311361

URL: http://llvm.org/viewvc/llvm-project?rev=311361&view=rev
Log:
[ManagedMemoryRewrite] slightly tweak debug output style. [NFC]

Modified:
    polly/trunk/lib/CodeGen/ManagedMemoryRewrite.cpp

Modified: polly/trunk/lib/CodeGen/ManagedMemoryRewrite.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/CodeGen/ManagedMemoryRewrite.cpp?rev=311361&r1=311360&r2=311361&view=diff
==============================================================================
--- polly/trunk/lib/CodeGen/ManagedMemoryRewrite.cpp (original)
+++ polly/trunk/lib/CodeGen/ManagedMemoryRewrite.cpp Mon Aug 21 11:58:33 2017
@@ -124,8 +124,8 @@ static void expandConstantExpr(ConstantE
   Instruction *I = Cur->getAsInstruction();
   assert(I && "unable to convert ConstantExpr to Instruction");
 
-  DEBUG(dbgs() << "Expanding ConstantExpression: " << *Cur
-               << " | in Instruction: " << *I << "\n";);
+  DEBUG(dbgs() << "Expanding ConstantExpression: (" << *Cur
+               << ") in Instruction: (" << *I << ")\n";);
 
   // Invalidate `Cur` so that no one after this point uses `Cur`. Rather,
   // they should mutate `I`.
@@ -209,8 +209,8 @@ replaceGlobalArray(Module &M, const Data
                                        Array.hasInternalLinkage() ||
                                        IgnoreLinkageForGlobals;
   if (!OnlyVisibleInsideModule) {
-    DEBUG(dbgs() << "Not rewriting " << Array
-                 << " to managed memory "
+    DEBUG(dbgs() << "Not rewriting (" << Array
+                 << ") to managed memory "
                     "because it could be visible externally. To force rewrite, "
                     "use -polly-acc-rewrite-ignore-linkage-for-globals.\n");
     return;
@@ -218,8 +218,8 @@ replaceGlobalArray(Module &M, const Data
 
   if (!Array.hasInitializer() ||
       !isa<ConstantAggregateZero>(Array.getInitializer())) {
-    DEBUG(dbgs() << "Not rewriting " << Array
-                 << " to managed memory "
+    DEBUG(dbgs() << "Not rewriting (" << Array
+                 << ") to managed memory "
                     "because it has an initializer which is "
                     "not a zeroinitializer.\n");
     return;
@@ -288,14 +288,14 @@ static void getAllocasToBeManaged(Functi
       auto *Alloca = dyn_cast<AllocaInst>(&I);
       if (!Alloca)
         continue;
-      DEBUG(dbgs() << "Checking if " << *Alloca << "may be captured: ");
+      DEBUG(dbgs() << "Checking if (" << *Alloca << ") may be captured: ");
 
       if (PointerMayBeCaptured(Alloca, /* ReturnCaptures */ false,
                                /* StoreCaptures */ true)) {
         Allocas.insert(Alloca);
-        DEBUG(dbgs() << "YES (captured)\n");
+        DEBUG(dbgs() << "YES (captured).\n");
       } else {
-        DEBUG(dbgs() << "NO (not captured)\n");
+        DEBUG(dbgs() << "NO (not captured).\n");
       }
     }
   }
@@ -303,7 +303,7 @@ static void getAllocasToBeManaged(Functi
 
 static void rewriteAllocaAsManagedMemory(AllocaInst *Alloca,
                                          const DataLayout &DL) {
-  DEBUG(dbgs() << "rewriting: " << *Alloca << " to managed mem.\n");
+  DEBUG(dbgs() << "rewriting: (" << *Alloca << ") to managed mem.\n");
   Module *M = Alloca->getModule();
   assert(M && "Alloca does not have a module");
 




More information about the llvm-commits mailing list