[llvm-branch-commits] [llvm] [AArch64] Prepare for split ZPR and PPR area allocation (NFCI) (PR #142391)

Benjamin Maxwell via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Jul 10 08:58:18 PDT 2025


================
@@ -4694,12 +4790,8 @@ void AArch64FrameLowering::processFunctionBeforeFrameFinalized(
   assert(getStackGrowthDirection() == TargetFrameLowering::StackGrowsDown &&
          "Upwards growing stack unsupported");
 
-  int MinCSFrameIndex, MaxCSFrameIndex;
-  int64_t SVEStackSize =
-      assignSVEStackObjectOffsets(MFI, MinCSFrameIndex, MaxCSFrameIndex);
-
-  AFI->setStackSizeSVE(alignTo(SVEStackSize, 16U));
-  AFI->setMinMaxSVECSFrameIndex(MinCSFrameIndex, MaxCSFrameIndex);
+  auto [ZPRStackSize, PPRStackSize] = assignSVEStackObjectOffsets(MF);
----------------
MacDue wrote:

I've removed both `assignSVEStackObjectOffsets` and `estimateSVEStackObjectOffsets` in favor of:
```c++
determineSVEStackSizes(MF, AssignObjectOffsets::Yes);

auto [ZPRStackSize, PPRStackSize] = determineSVEStackSizes(MF, AssignObjectOffsets::No);
```

(gone with the Yes/No enum pattern as I find it a little nicer than bools that always need comments). 


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


More information about the llvm-branch-commits mailing list