[PATCH] D79471: [MLIR][NFC] Fix/update debug messages for analysis utils and affine fusion
Uday Bondhugula via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 5 23:25:44 PDT 2020
bondhugula created this revision.
bondhugula added reviewers: andydavis1, mehdi_amini.
Herald added subscribers: llvm-commits, Kayjukh, frgossen, grosul1, Joonsoo, stephenneuendorffer, liufengdb, lucyrfox, mgester, arpith-jacob, nicolasvasilache, antiagainst, shauheen, jpienaar, rriddle, aprantl.
Herald added a project: LLVM.
Drop trailing period in debug messages. Add an extra line for fusion
debug info.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D79471
Files:
mlir/lib/Analysis/Utils.cpp
mlir/lib/Transforms/LoopFusion.cpp
Index: mlir/lib/Transforms/LoopFusion.cpp
===================================================================
--- mlir/lib/Transforms/LoopFusion.cpp
+++ mlir/lib/Transforms/LoopFusion.cpp
@@ -1063,8 +1063,8 @@
unsigned *dstLoopDepth, bool maximalFusion,
double computeToleranceThreshold) {
LLVM_DEBUG({
- llvm::dbgs() << "Checking whether fusion is profitable between:\n";
- llvm::dbgs() << " " << *srcOpInst << " and \n";
+ llvm::dbgs() << "Checking whether fusion is profitable between src op:\n";
+ llvm::dbgs() << ' ' << *srcOpInst << " and destination op(s)\n";
for (auto dstOpInst : dstLoadOpInsts) {
llvm::dbgs() << " " << *dstOpInst << "\n";
};
Index: mlir/lib/Analysis/Utils.cpp
===================================================================
--- mlir/lib/Analysis/Utils.cpp
+++ mlir/lib/Analysis/Utils.cpp
@@ -571,7 +571,7 @@
// Check if 'loopDepth' exceeds nesting depth of src/dst ops.
if ((!isBackwardSlice && loopDepth > getNestingDepth(opsA[i])) ||
(isBackwardSlice && loopDepth > getNestingDepth(opsB[j]))) {
- LLVM_DEBUG(llvm::dbgs() << "Invalid loop depth\n.");
+ LLVM_DEBUG(llvm::dbgs() << "Invalid loop depth\n");
return failure();
}
@@ -584,7 +584,7 @@
&dependenceConstraints, /*dependenceComponents=*/nullptr,
/*allowRAR=*/readReadAccesses);
if (result.value == DependenceResult::Failure) {
- LLVM_DEBUG(llvm::dbgs() << "Dependence check failed\n.");
+ LLVM_DEBUG(llvm::dbgs() << "Dependence check failed\n");
return failure();
}
if (result.value == DependenceResult::NoDependence)
@@ -601,7 +601,7 @@
// Initialize 'sliceUnionCst' with the bounds computed in previous step.
if (failed(tmpSliceState.getAsConstraints(&sliceUnionCst))) {
LLVM_DEBUG(llvm::dbgs()
- << "Unable to compute slice bound constraints\n.");
+ << "Unable to compute slice bound constraints\n");
return failure();
}
assert(sliceUnionCst.getNumDimAndSymbolIds() > 0);
@@ -612,7 +612,7 @@
FlatAffineConstraints tmpSliceCst;
if (failed(tmpSliceState.getAsConstraints(&tmpSliceCst))) {
LLVM_DEBUG(llvm::dbgs()
- << "Unable to compute slice bound constraints\n.");
+ << "Unable to compute slice bound constraints\n");
return failure();
}
@@ -645,8 +645,7 @@
tmpSliceCst.getNumLocalIds() > 0 ||
failed(sliceUnionCst.unionBoundingBox(tmpSliceCst))) {
LLVM_DEBUG(llvm::dbgs()
- << "Unable to compute union bounding box of slice bounds."
- "\n.");
+ << "Unable to compute union bounding box of slice bounds\n");
return failure();
}
}
@@ -665,7 +664,7 @@
unsigned innermostCommonLoopDepth =
getInnermostCommonLoopDepth(ops, surroundingLoops);
if (loopDepth > innermostCommonLoopDepth) {
- LLVM_DEBUG(llvm::dbgs() << "Exceeds max loop depth\n.");
+ LLVM_DEBUG(llvm::dbgs() << "Exceeds max loop depth\n");
return failure();
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D79471.262297.patch
Type: text/x-patch
Size: 3244 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200506/051125d8/attachment.bin>
More information about the llvm-commits
mailing list