[Mlir-commits] [mlir] [mlir][acc] Introduce ACCImplicitDeclare pass for globals handling (PR #169720)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Wed Nov 26 13:09:05 PST 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 cpp,h -- mlir/lib/Dialect/OpenACC/Transforms/ACCImplicitDeclare.cpp mlir/include/mlir/Dialect/OpenACC/OpenACC.h --diff_from_common_commit
``````````

: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/mlir/lib/Dialect/OpenACC/Transforms/ACCImplicitDeclare.cpp b/mlir/lib/Dialect/OpenACC/Transforms/ACCImplicitDeclare.cpp
index 67d88a853..766f690e2 100644
--- a/mlir/lib/Dialect/OpenACC/Transforms/ACCImplicitDeclare.cpp
+++ b/mlir/lib/Dialect/OpenACC/Transforms/ACCImplicitDeclare.cpp
@@ -242,8 +242,7 @@ bool isValidForAccDeclare(Operation *globalOp) {
 /// 2. The only symbol use is the recipe's own symbol definition
 template <typename RecipeOpT>
 static bool hasRelevantRecipeUse(RecipeOpT &recipeOp, ModuleOp &mod) {
-  std::optional<SymbolTable::UseRange> symbolUses =
-      recipeOp.getSymbolUses(mod);
+  std::optional<SymbolTable::UseRange> symbolUses = recipeOp.getSymbolUses(mod);
 
   // No recipe symbol uses.
   if (!symbolUses.has_value() || symbolUses->empty())

``````````

</details>


https://github.com/llvm/llvm-project/pull/169720


More information about the Mlir-commits mailing list