[llvm] [AArch64] Add getStreamingHazardSize() to AArch64Subtarget (PR #113679)

Hari Limaye via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 25 10:56:47 PDT 2024


================
@@ -126,14 +126,15 @@
 // and the SME unit try to access the same area of memory, including if the
 // access is to an area of the stack. To try to alleviate this we attempt to
 // introduce extra padding into the stack frame between FP and GPR accesses,
-// controlled by the StackHazardSize option. Without changing the layout of the
-// stack frame in the diagram above, a stack object of size StackHazardSize is
-// added between GPR and FPR CSRs. Another is added to the stack objects
-// section, and stack objects are sorted so that FPR > Hazard padding slot >
-// GPRs (where possible). Unfortunately some things are not handled well (VLA
-// area, arguments on the stack, object with both GPR and FPR accesses), but if
-// those are controlled by the user then the entire stack frame becomes GPR at
-// the start/end with FPR in the middle, surrounded by Hazard padding.
+// controlled by the aarch64-stack-hazard-size option. Without changing the
+// layout of the stack frame in the diagram above, a stack object of size
+// aarch64-stack-hazard-size is added between GPR and FPR CSRs. Another is added
+// to the stack objects section, and stack objects are sorted so that FPR >
+// Hazard padding slot > GPRs (where possible). Unfortunately some things are
+// not handled well (VLA area, arguments on the stack, object with both GPR and
----------------
hazzlim wrote:

```suggestion
// not handled well (VLA area, arguments on the stack, objects with both GPR and
```
(Nit) I know this is unchanged from the existing comment, but maybe worth doing while we're here.


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


More information about the llvm-commits mailing list