[llvm] [PowerPC] Fix saving of Link Register when using ROP Protect (PR #123101)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 15 10:35:51 PST 2025
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 1c5f87486aabd0eed2b41d32fc499700e4471f11 78781de649359aa6b23ae98c6577a6dfb534321a --extensions cpp -- llvm/lib/Target/PowerPC/PPCFrameLowering.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp b/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp
index 26deeaeab0..68e49e3929 100644
--- a/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp
+++ b/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp
@@ -1102,8 +1102,8 @@ void PPCFrameLowering::emitPrologue(MachineFunction &MF,
}
// Save the LR now.
- if (!HasSTUX && MustSaveLR && !HasFastMFLR && isInt<16>(FrameSize + LROffset)
- && !HasROPProtect)
+ if (!HasSTUX && MustSaveLR && !HasFastMFLR &&
+ isInt<16>(FrameSize + LROffset) && !HasROPProtect)
SaveLR(LROffset + FrameSize);
// Add Call Frame Information for the instructions we generated above.
``````````
</details>
https://github.com/llvm/llvm-project/pull/123101
More information about the llvm-commits
mailing list