[llvm] [GVN] Share equality propagation for assume and condition (PR #161639)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 2 01:41:56 PDT 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions h,cpp -- llvm/include/llvm/Transforms/Scalar/GVN.h llvm/include/llvm/Transforms/Utils/Local.h llvm/lib/Transforms/Scalar/GVN.cpp llvm/lib/Transforms/Utils/Local.cpp
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Transforms/Utils/Local.cpp b/llvm/lib/Transforms/Utils/Local.cpp
index 4feea7d8e..c21f38709 100644
--- a/llvm/lib/Transforms/Utils/Local.cpp
+++ b/llvm/lib/Transforms/Utils/Local.cpp
@@ -3242,9 +3242,7 @@ unsigned llvm::replaceDominatedUsesWith(Value *From, Value *To,
unsigned llvm::replaceDominatedUsesWith(Value *From, Value *To,
DominatorTree &DT,
const Instruction *I) {
- auto Dominates = [&](const Use &U) {
- return DT.dominates(I, U);
- };
+ auto Dominates = [&](const Use &U) { return DT.dominates(I, U); };
return ::replaceDominatedUsesWith(From, To, Dominates);
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/161639
More information about the llvm-commits
mailing list