1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 2
2 ; RUN: llc < %s -mtriple=s390x-linux-gnu -o - | FileCheck %s
4 define void @foo(i32 %i) nounwind {
6 ; CHECK: # %bb.0: # %entry
7 ; CHECK-NEXT: stmg %r14, %r15, 112(%r15)
8 ; CHECK-NEXT: aghi %r15, -160
9 ; CHECK-NEXT: cije %r2, 7, .LBB0_3
10 ; CHECK-NEXT: # %bb.1: # %entry
11 ; CHECK-NEXT: cijlh %r2, 5, .LBB0_4
12 ; CHECK-NEXT: # %bb.2: # %if.then
13 ; CHECK-NEXT: brasl %r14, bar@PLT
14 ; CHECK-NEXT: lmg %r14, %r15, 272(%r15)
15 ; CHECK-NEXT: jg bar@PLT
16 ; CHECK-NEXT: .LBB0_3: # %if.then2
17 ; CHECK-NEXT: brasl %r14, bar@PLT
18 ; CHECK-NEXT: .LBB0_4: # %if.end3
19 ; CHECK-NEXT: lmg %r14, %r15, 272(%r15)
20 ; CHECK-NEXT: jg bar@PLT
22 switch i32 %i, label %if.end3 [
24 i32 7, label %if.then2
28 tail call void @bar() #0
32 tail call void @bar() #0
36 tail call void @bar() #0
40 define void @foo_tail(i1 %i) nounwind {
41 ; CHECK-LABEL: foo_tail:
42 ; CHECK: # %bb.0: # %entry
43 ; CHECK-NEXT: tmll %r2, 1
44 ; CHECK-NEXT: jge bar@PLT
45 ; CHECK-NEXT: .LBB1_1: # %if.then
46 ; CHECK-NEXT: jg bar@PLT
48 br i1 %i, label %if.then, label %if.else
51 tail call void @bar() #0
55 tail call void @bar() #0
64 attributes #0 = { nomerge }