[llvm] [NewPM][CodeGen] Refactoring CodeGenPassBuilder (PR #89708)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 22 23:56:18 PDT 2024
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 a9d7ad23fa625e7f52f2641dbb0f90e8ea12bebf daf0f993308f3588d6c83486f6db44efc7ada32a -- llvm/unittests/CodeGen/CodeGenPassBuilderTest.cpp llvm/include/llvm/Passes/CodeGenPassBuilder.h llvm/lib/Target/X86/X86CodeGenPassBuilder.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/include/llvm/Passes/CodeGenPassBuilder.h b/llvm/include/llvm/Passes/CodeGenPassBuilder.h
index 3c122d67ed..1664026789 100644
--- a/llvm/include/llvm/Passes/CodeGenPassBuilder.h
+++ b/llvm/include/llvm/Passes/CodeGenPassBuilder.h
@@ -496,7 +496,8 @@ template <typename Derived, typename TargetMachineT>
template <typename PassT>
void CodeGenPassBuilder<Derived, TargetMachineT>::addPassImpl(PassT &&Pass) {
static_assert((is_module_pass_v<PassT> || is_function_pass_v<PassT> ||
- is_machine_function_pass_v<PassT>)&&"Unexpected pass type!");
+ is_machine_function_pass_v<PassT>) &&
+ "Unexpected pass type!");
constexpr PassType PT = is_module_pass_v<PassT> ? PassType::ModulePass
: is_function_pass_v<PassT>
``````````
</details>
https://github.com/llvm/llvm-project/pull/89708
More information about the llvm-commits
mailing list