[llvm-branch-commits] [mlir] [mlir][draft] Consolidate patterns into `RegionBranchOpInterface` patterns (PR #174094)
Matthias Springer via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Thu Jan 1 07:30:46 PST 2026
================
@@ -583,3 +624,283 @@ Region *mlir::getEnclosingRepetitiveRegion(Value value) {
LDBG() << "No enclosing repetitive region found for value";
return nullptr;
}
+
+/// Is a defined before b?
+static bool isDefinedBefore(Value a, Value b) {
----------------
matthias-springer wrote:
I have to measure this... I'm trying to keep this as lightweight as possible. (Even at the expense of potentially returning `false` in cases where `true` would be correct.) This function is called from the canonicalization pattern and computing an analysis (`DominanceInfo`) in there sounds too expensive.
https://github.com/llvm/llvm-project/pull/174094
More information about the llvm-branch-commits
mailing list