[llvm] [AVR] Support return address intrinsics (PR #67266)

via llvm-commits llvm-commits at lists.llvm.org
Sun Sep 24 07:05:58 PDT 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 e471cd1d7382b98108f888072cbe016a3afc4558 710fcf356ad494c88610919d8e6236c3aa001d14 -- llvm/lib/Target/AVR/AVRISelLowering.cpp llvm/lib/Target/AVR/AVRISelLowering.h llvm/lib/Target/AVR/AVRMachineFunctionInfo.h
``````````

</details>

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

``````````diff
diff --git a/llvm/lib/Target/AVR/AVRISelLowering.cpp b/llvm/lib/Target/AVR/AVRISelLowering.cpp
index 8b558f32f14c..e253fa0cdd54 100644
--- a/llvm/lib/Target/AVR/AVRISelLowering.cpp
+++ b/llvm/lib/Target/AVR/AVRISelLowering.cpp
@@ -992,8 +992,7 @@ SDValue AVRTargetLowering::LowerINLINEASM(SDValue Op, SelectionDAG &DAG) const {
   return New;
 }
 
-SDValue
-AVRTargetLowering::getReturnAddressFrameIndex(SelectionDAG &DAG) const {
+SDValue AVRTargetLowering::getReturnAddressFrameIndex(SelectionDAG &DAG) const {
   MachineFunction &MF = DAG.getMachineFunction();
   AVRMachineFunctionInfo *FuncInfo = MF.getInfo<AVRMachineFunctionInfo>();
   int ReturnAddrIndex = FuncInfo->getRAIndex();
@@ -1010,7 +1009,8 @@ AVRTargetLowering::getReturnAddressFrameIndex(SelectionDAG &DAG) const {
   return DAG.getFrameIndex(ReturnAddrIndex, getPointerTy(DAG.getDataLayout()));
 }
 
-SDValue AVRTargetLowering::LowerRETURNADDR(SDValue Op, SelectionDAG &DAG) const {
+SDValue AVRTargetLowering::LowerRETURNADDR(SDValue Op,
+                                           SelectionDAG &DAG) const {
   MachineFunction &MF = DAG.getMachineFunction();
   MachineFrameInfo &MFI = MF.getFrameInfo();
   const AVRMachineFunctionInfo *AFI = MF.getInfo<AVRMachineFunctionInfo>();
@@ -1025,7 +1025,8 @@ SDValue AVRTargetLowering::LowerRETURNADDR(SDValue Op, SelectionDAG &DAG) const
   return DAG.getLoad(VT, DL, DAG.getEntryNode(), RetAddrFI,
                      MachinePointerInfo());
 }
-SDValue AVRTargetLowering::LowerADDROFRETURNADDR(SDValue Op, SelectionDAG &DAG) const {
+SDValue AVRTargetLowering::LowerADDROFRETURNADDR(SDValue Op,
+                                                 SelectionDAG &DAG) const {
   DAG.getMachineFunction().getFrameInfo().setReturnAddressIsTaken(true);
   return getReturnAddressFrameIndex(DAG);
 }

``````````

</details>


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


More information about the llvm-commits mailing list