• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# RUN: llc -mtriple=arm-linux-unknown-gnueabi -start-after branch-folder -stop-after branch-folder -o - %s | FileCheck %s
2
3--- |
4  declare void @dummy_use(i32*, i32)
5
6  define void @test_basic() #0 {
7  entry:
8    %mem = alloca i32, i32 10
9    call void @dummy_use(i32* %mem, i32 10)
10    ret void
11  }
12
13  attributes #0 = { "split-stack" }
14...
15---
16name:            test_basic
17tracksRegLiveness: true
18frameInfo:
19  stackSize:       48
20  maxAlignment:    4
21  adjustsStack:    true
22  hasCalls:        true
23stack:
24  - { id: 0, name: mem, offset: -48, size: 40, alignment: 4 }
25  - { id: 1, type: spill-slot, offset: -4, size: 4, alignment: 4,
26      callee-saved-register: '%lr' }
27  - { id: 2, type: spill-slot, offset: -8, size: 4, alignment: 4,
28      callee-saved-register: '%r11' }
29body: |
30  bb.0:
31    successors: %bb.2, %bb.1
32    liveins: %r11, %lr
33
34    %sp = STMDB_UPD %sp, 14, _, %r4, %r5
35    CFI_INSTRUCTION .cfi_def_cfa_offset 8
36    CFI_INSTRUCTION .cfi_offset %r5, -4
37    CFI_INSTRUCTION .cfi_offset %r4, -8
38    %r5 = MOVr %sp, 14, _, _
39    %r4 = MRC 15, 0, 13, 0, 3, 14, _
40    %r4 = LDRi12 %r4, 4, 14, _
41    CMPrr %r4, %r5, 14, _, implicit-def %cpsr
42    Bcc %bb.2, 3, %cpsr
43
44  bb.1:
45    successors: %bb.2
46    liveins: %r11, %lr
47
48    %r4 = MOVi 48, 14, _, _
49    %r5 = MOVi 0, 14, _, _
50    %sp = STMDB_UPD %sp, 14, _, %lr
51    CFI_INSTRUCTION .cfi_def_cfa_offset 12
52    CFI_INSTRUCTION .cfi_offset %lr, -12
53    BL $__morestack, implicit-def %lr, implicit %sp
54    %sp = LDMIA_UPD %sp, 14, _, %lr
55    %sp = LDMIA_UPD %sp, 14, _, %r4, %r5
56    CFI_INSTRUCTION .cfi_def_cfa_offset 0
57    BX_RET 14, _
58
59  bb.2:
60    liveins: %r11, %lr
61
62    %sp = LDMIA_UPD %sp, 14, _, %r4, %r5
63    CFI_INSTRUCTION .cfi_def_cfa_offset 0
64  ; CHECK:      CFI_INSTRUCTION .cfi_same_value %r4
65  ; CHECK-NEXT: CFI_INSTRUCTION .cfi_same_value %r5
66    CFI_INSTRUCTION .cfi_same_value %r4
67    CFI_INSTRUCTION .cfi_same_value %r5
68    %sp = frame-setup STMDB_UPD %sp, 14, _, killed %r11, killed %lr
69    frame-setup CFI_INSTRUCTION .cfi_def_cfa_offset 8
70    frame-setup CFI_INSTRUCTION .cfi_offset %lr, -4
71    frame-setup CFI_INSTRUCTION .cfi_offset %r11, -8
72    %sp = frame-setup SUBri killed %sp, 40, 14, _, _
73    frame-setup CFI_INSTRUCTION .cfi_def_cfa_offset 48
74    %r0 = MOVr %sp, 14, _, _
75    %r1 = MOVi 10, 14, _, _
76    BL @dummy_use, csr_aapcs, implicit-def dead %lr, implicit %sp, implicit %r0, implicit killed %r1, implicit-def %sp
77    %sp = ADDri killed %sp, 40, 14, _, _
78    %sp = LDMIA_UPD %sp, 14, _, %r4, %r5
79    MOVPCLR 14, _
80...
81