[llvm] [AArch64] Add check that prologue insertion doesn't clobber live regs. (PR #71826)

via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 9 08:54:12 PST 2023


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 7360d5d30fe75ee86696d1e9a8a62cb74b47254a 4321e9f2b9a18f4b117ad8859a429cb4901a2850 -- llvm/lib/Target/AArch64/AArch64FrameLowering.cpp
``````````

</details>

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

``````````diff
diff --git a/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp b/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp
index 87efb60b6ebb..816061dd32df 100644
--- a/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp
+++ b/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp
@@ -1420,7 +1420,8 @@ void AArch64FrameLowering::emitPrologue(MachineFunction &MF,
   // Collect live register from the end of MBB up to the start of the existing
   // frame setup instructions.
   MachineBasicBlock::iterator NonFrameStart = MBB.begin();
-  while (NonFrameStart != End && NonFrameStart->getFlag(MachineInstr::FrameSetup))
+  while (NonFrameStart != End &&
+         NonFrameStart->getFlag(MachineInstr::FrameSetup))
     ++NonFrameStart;
   LivePhysRegs LiveRegs(*TRI);
   if (NonFrameStart != MBB.end()) {

``````````

</details>


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


More information about the llvm-commits mailing list