1 ; RUN: llc < %s -mtriple=ve-unknown-unknown | FileCheck %s
3 @.str = private unnamed_addr constant [6 x i8] c"a=%d\0A\00", align 1
4 @.str.1 = private unnamed_addr constant [6 x i8] c"b=%d\0A\00", align 1
5 @.str.2 = private unnamed_addr constant [6 x i8] c"c=%d\0A\00", align 1
6 @.str.3 = private unnamed_addr constant [6 x i8] c"d=%u\0A\00", align 1
7 @.str.4 = private unnamed_addr constant [6 x i8] c"e=%u\0A\00", align 1
8 @.str.5 = private unnamed_addr constant [6 x i8] c"f=%u\0A\00", align 1
9 @.str.6 = private unnamed_addr constant [6 x i8] c"g=%f\0A\00", align 1
10 @.str.7 = private unnamed_addr constant [6 x i8] c"h=%p\0A\00", align 1
11 @.str.8 = private unnamed_addr constant [7 x i8] c"i=%ld\0A\00", align 1
12 @.str.9 = private unnamed_addr constant [7 x i8] c"j=%lf\0A\00", align 1
13 @.str.10 = private unnamed_addr constant [7 x i8] c"j=%Lf\0A\00", align 1
15 define i32 @func_vainout(i32, ...) {
16 ; CHECK-LABEL: func_vainout:
17 ; CHECK: ldl.sx %s{{.*}}, 184(, %s9)
18 ; CHECK: ld2b.sx %s{{.*}}, 192(, %s9)
19 ; CHECK: ld1b.sx %s{{.*}}, 200(, %s9)
20 ; CHECK: ldl.sx %s{{.*}}, 208(, %s9)
21 ; CHECK: ld2b.zx %s{{.*}}, 216(, %s9)
22 ; CHECK: ld1b.zx %s{{.*}}, 224(, %s9)
23 ; CHECK: ldu %s{{.*}}, 236(, %s9)
24 ; CHECK: ld %s{{.*}}, 240(, %s9)
25 ; CHECK: ld %s{{.*}}, 248(, %s9)
26 ; CHECK: ld %s{{.*}}, 256(, %s9)
27 ; CHECK: lea %{{.*}}, 279(, %s9)
28 ; CHECK: and %{{.*}}, -16, %s0
29 ; CHECK: lea %{{.*}}, 16(, %s0)
30 ; CHECK: ld %s{{.*}}, 8(, %s0)
31 ; CHECK: ld %s{{.*}}, (, %s0)
32 ; CHECK: ld %s{{.*}}, 16(, %s0)
46 %a = alloca ptr, align 8
47 call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %a)
48 call void @llvm.va_start(ptr nonnull %a)
49 %p0 = va_arg ptr %a, i32
50 %p1 = va_arg ptr %a, i16
51 %p2 = va_arg ptr %a, i8
52 %p3 = va_arg ptr %a, i32
53 %p4 = va_arg ptr %a, i16
54 %p5 = va_arg ptr %a, i8
55 %p6 = va_arg ptr %a, float
56 %p7 = va_arg ptr %a, ptr
57 %p8 = va_arg ptr %a, i64
58 %p9 = va_arg ptr %a, double
59 %p10 = va_arg ptr %a, fp128
60 %p11 = va_arg ptr %a, double
61 call void @llvm.va_end(ptr nonnull %a)
62 call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %a)
63 %pf0 = call i32 (ptr, ...) @printf(ptr @.str, i32 %p0)
64 %p1.s32 = sext i16 %p1 to i32
65 %pf1 = call i32 (ptr, ...) @printf(ptr @.str.1, i32 %p1.s32)
66 %p2.s32 = sext i8 %p2 to i32
67 %pf2 = call i32 (ptr, ...) @printf(ptr @.str.2, i32 %p2.s32)
68 %pf3 = call i32 (ptr, ...) @printf(ptr @.str.3, i32 %p3)
69 %p4.z32 = zext i16 %p4 to i32
70 %pf4 = call i32 (ptr, ...) @printf(ptr @.str.4, i32 %p4.z32)
71 %p5.z32 = zext i8 %p5 to i32
72 %pf5 = call i32 (ptr, ...) @printf(ptr @.str.5, i32 %p5.z32)
73 %pf6 = call i32 (ptr, ...) @printf(ptr @.str.6, float %p6)
74 %pf7 = call i32 (ptr, ...) @printf(ptr @.str.7, ptr %p7)
75 %pf8 = call i32 (ptr, ...) @printf(ptr @.str.8, i64 %p8)
76 %pf9 = call i32 (ptr, ...) @printf(ptr @.str.9, double %p9)
77 %pf10 = call i32 (ptr, ...) @printf(ptr @.str.10, fp128 %p10)
78 %pf11 = call i32 (ptr, ...) @printf(ptr @.str.9, double %p11)
81 declare void @llvm.lifetime.start.p0(i64, ptr nocapture)
82 declare void @llvm.lifetime.end.p0(i64, ptr nocapture)
83 declare void @llvm.va_start(ptr)
84 declare void @llvm.va_end(ptr)
85 declare i32 @printf(ptr nocapture readonly, ...)