[llvm] [SelectOpt] Add handling for not conditions. (PR #92517)

via llvm-commits llvm-commits at lists.llvm.org
Fri May 17 03:42:53 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 4349ffb3fa268dba180b7c65fdce20a0be60272b 737719f3336a2ad1ee0c0a2ab45a0c24763d894f -- llvm/lib/CodeGen/SelectOptimize.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/llvm/lib/CodeGen/SelectOptimize.cpp b/llvm/lib/CodeGen/SelectOptimize.cpp
index 30befb1a53..b8d0961a96 100644
--- a/llvm/lib/CodeGen/SelectOptimize.cpp
+++ b/llvm/lib/CodeGen/SelectOptimize.cpp
@@ -161,7 +161,8 @@ public:
     void setInverted() {
       assert(!Inverted && "Trying to invert and inverted SelectLike");
       assert(isa<Instruction>(getCondition()) &&
-             cast<Instruction>(getCondition())->getOpcode() == Instruction::Xor);
+             cast<Instruction>(getCondition())->getOpcode() ==
+                 Instruction::Xor);
       Inverted = true;
     }
     bool isInverted() const { return Inverted; }

``````````

</details>


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


More information about the llvm-commits mailing list