summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--polly/lib/Analysis/Dependences.cpp26
-rw-r--r--polly/lib/Analysis/ScopDetection.cpp2
-rw-r--r--polly/lib/CodeGen/CodeGeneration.cpp2
-rw-r--r--polly/lib/Support/SCEVValidator.cpp14
4 files changed, 33 insertions, 11 deletions
diff --git a/polly/lib/Analysis/Dependences.cpp b/polly/lib/Analysis/Dependences.cpp
index 827143f7c30..b8247431939 100644
--- a/polly/lib/Analysis/Dependences.cpp
+++ b/polly/lib/Analysis/Dependences.cpp
@@ -309,7 +309,11 @@ void Dependences::calculateDependences(Scop &S) {
isl_union_map_domain(isl_union_map_copy(StmtSchedule)));
STMT_WAR = isl_union_map_intersect_domain(isl_union_map_copy(WAR),
isl_union_map_domain(StmtSchedule));
- DEBUG(dbgs() << "Wrapped Dependences:\n"; printScop(dbgs()); dbgs() << "\n");
+ DEBUG({
+ dbgs() << "Wrapped Dependences:\n";
+ printScop(dbgs());
+ dbgs() << "\n";
+ });
// To handle reduction dependences we proceed as follows:
// 1) Aggregate all possible reduction dependences, namely all self
@@ -352,8 +356,11 @@ void Dependences::calculateDependences(Scop &S) {
addPrivatizationDependences();
}
- DEBUG(dbgs() << "Final Wrapped Dependences:\n"; printScop(dbgs());
- dbgs() << "\n");
+ DEBUG({
+ dbgs() << "Final Wrapped Dependences:\n";
+ printScop(dbgs());
+ dbgs() << "\n";
+ });
// RED_SIN is used to collect all reduction dependences again after we
// split them according to the causing memory accesses. The current assumption
@@ -397,7 +404,11 @@ void Dependences::calculateDependences(Scop &S) {
RED = isl_union_map_zip(RED);
TC_RED = isl_union_map_zip(TC_RED);
- DEBUG(dbgs() << "Zipped Dependences:\n"; printScop(dbgs()); dbgs() << "\n");
+ DEBUG({
+ dbgs() << "Zipped Dependences:\n";
+ printScop(dbgs());
+ dbgs() << "\n";
+ });
RAW = isl_union_set_unwrap(isl_union_map_domain(RAW));
WAW = isl_union_set_unwrap(isl_union_map_domain(WAW));
@@ -405,8 +416,11 @@ void Dependences::calculateDependences(Scop &S) {
RED = isl_union_set_unwrap(isl_union_map_domain(RED));
TC_RED = isl_union_set_unwrap(isl_union_map_domain(TC_RED));
- DEBUG(dbgs() << "Unwrapped Dependences:\n"; printScop(dbgs());
- dbgs() << "\n");
+ DEBUG({
+ dbgs() << "Unwrapped Dependences:\n";
+ printScop(dbgs());
+ dbgs() << "\n";
+ });
RAW = isl_union_map_union(RAW, STMT_RAW);
WAW = isl_union_map_union(WAW, STMT_WAW);
diff --git a/polly/lib/Analysis/ScopDetection.cpp b/polly/lib/Analysis/ScopDetection.cpp
index 234aa6356ac..fb9e65f39a8 100644
--- a/polly/lib/Analysis/ScopDetection.cpp
+++ b/polly/lib/Analysis/ScopDetection.cpp
@@ -813,7 +813,7 @@ bool ScopDetection::isValidRegion(DetectionContext &Context) const {
DEBUG(dbgs() << "Checking region: " << R.getNameStr() << "\n\t");
if (R.isTopLevelRegion()) {
- DEBUG(dbgs() << "Top level region is invalid"; dbgs() << "\n");
+ DEBUG(dbgs() << "Top level region is invalid\n");
return false;
}
diff --git a/polly/lib/CodeGen/CodeGeneration.cpp b/polly/lib/CodeGen/CodeGeneration.cpp
index 421aa79e774..d58d40d2ac5 100644
--- a/polly/lib/CodeGen/CodeGeneration.cpp
+++ b/polly/lib/CodeGen/CodeGeneration.cpp
@@ -822,7 +822,7 @@ int ClastStmtCodeGen::getNumberOfIterations(const clast_for *For) {
}
void ClastStmtCodeGen::codegenForVector(const clast_for *F) {
- DEBUG(dbgs() << "Vectorizing loop '" << F->iterator << "'\n";);
+ DEBUG(dbgs() << "Vectorizing loop '" << F->iterator << "'\n");
int VectorWidth = getNumberOfIterations(F);
Value *LB = ExpGen.codegen(F->LB, getIntPtrTy());
diff --git a/polly/lib/Support/SCEVValidator.cpp b/polly/lib/Support/SCEVValidator.cpp
index 3a8895f6cad..6c38782ea9d 100644
--- a/polly/lib/Support/SCEVValidator.cpp
+++ b/polly/lib/Support/SCEVValidator.cpp
@@ -471,12 +471,20 @@ bool isAffineExpr(const Region *R, const SCEV *Expr, ScalarEvolution &SE,
return false;
SCEVValidator Validator(R, SE, BaseAddress);
- DEBUG(dbgs() << "\n"; dbgs() << "Expr: " << *Expr << "\n";
- dbgs() << "Region: " << R->getNameStr() << "\n"; dbgs() << " -> ");
+ DEBUG({
+ dbgs() << "\n";
+ dbgs() << "Expr: " << *Expr << "\n";
+ dbgs() << "Region: " << R->getNameStr() << "\n";
+ dbgs() << " -> ";
+ });
ValidatorResult Result = Validator.visit(Expr);
- DEBUG(if (Result.isValid()) dbgs() << "VALID\n"; dbgs() << "\n";);
+ DEBUG({
+ if (Result.isValid())
+ dbgs() << "VALID\n";
+ dbgs() << "\n";
+ });
return Result.isValid();
}
OpenPOWER on IntegriCloud