File: spill-stack-realignment.mir

package info (click to toggle)
llvm-toolchain-14 1%3A14.0.6-12
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,496,180 kB
  • sloc: cpp: 5,593,972; ansic: 986,872; asm: 585,869; python: 184,223; objc: 72,530; lisp: 31,119; f90: 27,793; javascript: 9,780; pascal: 9,762; sh: 9,482; perl: 7,468; ml: 5,432; awk: 3,523; makefile: 2,538; xml: 953; cs: 573; fortran: 567
file content (35 lines) | stat: -rw-r--r-- 1,283 bytes parent folder | download | duplicates (13)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# RUN: llc -mtriple=aarch64-none-linux-gnu -run-pass=prologepilog %s -o - | FileCheck %s

# Ensure references to scavenged stack slots in the CSR area use the
# FP as a base when the stack pointer must be aligned to something
# larger than required by the target. This is necessary because the
# alignment padding area is between the CSR area and the SP, so the SP
# cannot be used to reference the CSR area.
name:            test
tracksRegLiveness: true
frameInfo:
  maxAlignment:    64
# CHECK:      stack:
# CHECK:        id: 0, name: '', type: default, offset: -64, size: 4, alignment: 64
# CHECK-NEXT:     stack-id: default
# CHECK-NEXT:     local-offset: -64
# CHECK:        id: 1, name: '', type: default, offset: -4, size: 4, alignment: 4
# CHECK-NEXT:     stack-id: default
# CHECK-NEXT:     local-offset: -68
stack:
  - { id: 0, size: 4, alignment: 64, local-offset: -64 }
  - { id: 1, size: 4, alignment: 4, local-offset: -68 }

# CHECK: body:
# CHECK:   $sp = ANDXri killed ${{x[0-9]+}}, 7865
# CHECK:   STRSui $s0, $sp, 0
# CHECK:   STRSui $s0, $fp, 7
body:             |
  bb.0.entry:
    liveins: $s0

    STRSui $s0, %stack.0, 0
    STRSui $s0, %stack.1, 0
    ; Force preserve a CSR to create a hole in the CSR stack region.
    $x28 = IMPLICIT_DEF
    RET_ReallyLR