Home | History | Annotate | Download | only in ARM
      1 ; RUN: llc -mtriple arm-eabi -disable-fp-elim -filetype asm -o - %s \
      2 ; RUN:     | FileCheck -check-prefix CHECK-ARM %s
      3 
      4 ; RUN: llc -mtriple thumb-eabi -disable-fp-elim -filetype asm -o - %s \
      5 ; RUN:     | FileCheck -check-prefix CHECK-THUMB %s
      6 
      7 ; RUN: llc -mtriple arm-darwin -disable-fp-elim -filetype asm -o - %s \
      8 ; RUN:     | FileCheck -check-prefix CHECK-DARWIN-ARM %s
      9 
     10 ; RUN: llc -mtriple thumb-darwin -disable-fp-elim -filetype asm -o - %s \
     11 ; RUN:     | FileCheck -check-prefix CHECK-DARWIN-THUMB %s
     12 
     13 declare void @callee(i32)
     14 
     15 define i32 @calleer(i32 %i) {
     16 entry:
     17   %i.addr = alloca i32, align 4
     18   %j = alloca i32, align 4
     19   store i32 %i, i32* %i.addr, align 4
     20   %0 = load i32* %i.addr, align 4
     21   %add = add nsw i32 %0, 1
     22   store i32 %add, i32* %j, align 4
     23   %1 = load i32* %j, align 4
     24   call void @callee(i32 %1)
     25   %2 = load i32* %j, align 4
     26   %add1 = add nsw i32 %2, 1
     27   ret i32 %add1
     28 }
     29 
     30 ; CHECK-ARM: push {r11, lr}
     31 ; CHECK-ARM: mov r11, sp
     32 
     33 ; CHECK-THUMB: push {r4, r6, r7, lr}
     34 ; CHECK-THUMB: add r7, sp, #8
     35 
     36 ; CHECK-DARWIN-ARM: push {r7, lr}
     37 ; CHECK-DARWIN-THUMB: push {r4, r7, lr}
     38 
     39