[llvm] [LLVM] Register static pass plugins in LLVMRunPasses C-API (PR #196754)

via llvm-commits llvm-commits at lists.llvm.org
Sat May 9 14:53:53 PDT 2026


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 -- llvm/lib/Passes/PassBuilderBindings.cpp llvm/unittests/Passes/PassBuilderBindings/PassBuilderBindingsTest.cpp --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/llvm/unittests/Passes/PassBuilderBindings/PassBuilderBindingsTest.cpp b/llvm/unittests/Passes/PassBuilderBindings/PassBuilderBindingsTest.cpp
index 3f37d6b0b..b9b904150 100644
--- a/llvm/unittests/Passes/PassBuilderBindings/PassBuilderBindingsTest.cpp
+++ b/llvm/unittests/Passes/PassBuilderBindings/PassBuilderBindingsTest.cpp
@@ -98,8 +98,8 @@ TEST_F(PassBuilderCTest, Function) {
 #ifdef PASSBUILDER_HAS_BYE_PLUGIN
 TEST_F(PassBuilderCTest, StaticPassExtension) {
   LLVMPassBuilderOptionsRef Options = LLVMCreatePassBuilderOptions();
-  if (LLVMErrorRef E = LLVMRunPasses(Module, "function(goodbye)", TM,
-                                     Options)) {
+  if (LLVMErrorRef E =
+          LLVMRunPasses(Module, "function(goodbye)", TM, Options)) {
     char *Msg = LLVMGetErrorMessage(E);
     LLVMDisposePassBuilderOptions(Options);
     FAIL() << "Failed to run statically linked extension pass on module: "

``````````

</details>


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


More information about the llvm-commits mailing list