diff options
Diffstat (limited to 'polly/lib/CodeGen/ManagedMemoryRewrite.cpp')
-rw-r--r-- | polly/lib/CodeGen/ManagedMemoryRewrite.cpp | 29 |
1 files changed, 15 insertions, 14 deletions
diff --git a/polly/lib/CodeGen/ManagedMemoryRewrite.cpp b/polly/lib/CodeGen/ManagedMemoryRewrite.cpp index a8240140809..e14da1dbdb9 100644 --- a/polly/lib/CodeGen/ManagedMemoryRewrite.cpp +++ b/polly/lib/CodeGen/ManagedMemoryRewrite.cpp @@ -124,8 +124,8 @@ static void expandConstantExpr(ConstantExpr *Cur, PollyIRBuilder &Builder, Instruction *I = Cur->getAsInstruction(); assert(I && "unable to convert ConstantExpr to Instruction"); - DEBUG(dbgs() << "Expanding ConstantExpression: (" << *Cur - << ") in Instruction: (" << *I << ")\n";); + LLVM_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,19 +209,20 @@ replaceGlobalArray(Module &M, const DataLayout &DL, GlobalVariable &Array, Array.hasInternalLinkage() || IgnoreLinkageForGlobals; if (!OnlyVisibleInsideModule) { - 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"); + LLVM_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; } if (!Array.hasInitializer() || !isa<ConstantAggregateZero>(Array.getInitializer())) { - DEBUG(dbgs() << "Not rewriting (" << Array - << ") to managed memory " - "because it has an initializer which is " - "not a zeroinitializer.\n"); + LLVM_DEBUG(dbgs() << "Not rewriting (" << Array + << ") to managed memory " + "because it has an initializer which is " + "not a zeroinitializer.\n"); return; } @@ -288,14 +289,14 @@ static void getAllocasToBeManaged(Function &F, auto *Alloca = dyn_cast<AllocaInst>(&I); if (!Alloca) continue; - DEBUG(dbgs() << "Checking if (" << *Alloca << ") may be captured: "); + LLVM_DEBUG(dbgs() << "Checking if (" << *Alloca << ") may be captured: "); if (PointerMayBeCaptured(Alloca, /* ReturnCaptures */ false, /* StoreCaptures */ true)) { Allocas.insert(Alloca); - DEBUG(dbgs() << "YES (captured).\n"); + LLVM_DEBUG(dbgs() << "YES (captured).\n"); } else { - DEBUG(dbgs() << "NO (not captured).\n"); + LLVM_DEBUG(dbgs() << "NO (not captured).\n"); } } } @@ -303,7 +304,7 @@ static void getAllocasToBeManaged(Function &F, static void rewriteAllocaAsManagedMemory(AllocaInst *Alloca, const DataLayout &DL) { - DEBUG(dbgs() << "rewriting: (" << *Alloca << ") to managed mem.\n"); + LLVM_DEBUG(dbgs() << "rewriting: (" << *Alloca << ") to managed mem.\n"); Module *M = Alloca->getModule(); assert(M && "Alloca does not have a module"); |