[llvm] [SelectionDAG] Fix soft-promotion of f16 BUILD_VECTOR for MSA targets (PR #210515)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Jul 18 09:21:36 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 h,cpp -- llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.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/llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp b/llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp
index 79c133508..d0e1552ab 100644
--- a/llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp
@@ -3246,8 +3246,8 @@ SDValue DAGTypeLegalizer::SoftPromoteHalfOp_BUILD_VECTOR(SDNode *N) {
for (unsigned i = 0, e = N->getNumOperands(); i != e; ++i)
Ops[i] = GetSoftPromotedHalf(N->getOperand(i));
- EVT IVT = EVT::getVectorVT(*DAG.getContext(), MVT::i16,
- VT.getVectorElementCount());
+ EVT IVT =
+ EVT::getVectorVT(*DAG.getContext(), MVT::i16, VT.getVectorElementCount());
SDValue Res = DAG.getBuildVector(IVT, dl, Ops);
return DAG.getNode(ISD::BITCAST, dl, VT, Res);
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/210515
More information about the llvm-commits
mailing list