[llvm] [HEXAGON] Utilize new mask instruction (PR #92365)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 29 04:42:29 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 a8e1c3e1239604ac787b6a2d39b5278ddec8aa8a fed67f7151518d35afcacd7a3da61ff2701fcc05 --extensions cpp -- llvm/lib/Target/Hexagon/HexagonMask.cpp llvm/lib/Target/Hexagon/HexagonTargetMachine.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Target/Hexagon/HexagonMask.cpp b/llvm/lib/Target/Hexagon/HexagonMask.cpp
index 6a06efd307..ac9abfa6c1 100644
--- a/llvm/lib/Target/Hexagon/HexagonMask.cpp
+++ b/llvm/lib/Target/Hexagon/HexagonMask.cpp
@@ -90,9 +90,10 @@ bool HexagonMask::runOnMachineFunction(MachineFunction &MF) {
if (!F.hasFnAttribute(Attribute::OptimizeForSize))
return false;
- // The mask instruction available in v66 can be used to generate values in registers using 2 immediates
- // Eg. to form 0x07fffffc in R0, you would write "R0 = mask(#25,#2)"
- // Since it is a single-word instruction, it takes less code size than a constant-extended transfer at Os
+ // The mask instruction available in v66 can be used to generate values in
+ // registers using 2 immediates Eg. to form 0x07fffffc in R0, you would write
+ // "R0 = mask(#25,#2)" Since it is a single-word instruction, it takes less
+ // code size than a constant-extended transfer at Os
replaceConstExtTransferImmWithMask(MF);
return true;
``````````
</details>
https://github.com/llvm/llvm-project/pull/92365
More information about the llvm-commits
mailing list