[WebAssembly] Don't perform the returned-argument optimization on constants.
[oota-llvm.git] / test / CodeGen / ARM / 2010-03-18-ldm-rtrn.ll
1 ; RUN: llc < %s -mtriple=armv4-unknown-eabi | FileCheck %s -check-prefix=V4
2 ; RUN: llc < %s -mtriple=armv5-unknown-eabi | FileCheck %s
3 ; RUN: llc < %s -mtriple=armv6-unknown-eabi | FileCheck %s
4
5 define i32 @bar(i32 %a) nounwind {
6 entry:
7   %0 = tail call i32 @foo(i32 %a) nounwind ; <i32> [#uses=1]
8   %1 = add nsw i32 %0, 3                          ; <i32> [#uses=1]
9 ; CHECK: pop {r11, pc}
10 ; V4: pop
11 ; V4-NEXT: mov pc, lr
12   ret i32 %1
13 }
14
15 declare i32 @foo(i32)