[llvm] [mlir] [MLIR] Adopt LDBG() in EliminateBarriers.cpp (NFC) (PR #155092)
Mehdi Amini via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 25 07:30:14 PDT 2025
================
@@ -424,27 +422,18 @@ static bool maybeCaptured(Value v) {
/// everything. This seems sufficient to achieve barrier removal in structured
/// control flow, more complex cases would require a proper dataflow analysis.
static bool mayAlias(Value first, Value second) {
- DEBUG_WITH_TYPE(DEBUG_TYPE_ALIAS, {
- DBGS_ALIAS() << "checking aliasing between ";
- DBGS_ALIAS() << first << "\n";
- DBGS_ALIAS() << " and ";
- DBGS_ALIAS() << second << "\n";
- });
+ LDBG(1, DEBUG_TYPE_ALIAS)
----------------
joker-eph wrote:
Let me look at the overload idea, I like it :)
I wanted to preserve the more common case where you have a single DEBUG_TYPE in a file and you just want to adjust for the log level `LDBG(2)` instead of having to be explicit about the DEBUG_TYPE just to change the log level.
https://github.com/llvm/llvm-project/pull/155092
More information about the llvm-commits
mailing list