blob: 21c92dbc9098b5bbfd85dd7f813298a48d0b3085 [file] [log] [blame]
Matt Arsenaulte935f052016-06-18 05:15:53 +00001; RUN: llc -O0 -march=amdgcn -verify-machineinstrs < %s | FileCheck %s
2
3; Test that the alignment of kernel arguments does not impact the
4; alignment of the stack
5
6; CHECK-LABEL: {{^}}no_args:
7; CHECK: ScratchSize: 8{{$}}
8define void @no_args() {
9 %alloca = alloca i8
10 store volatile i8 0, i8* %alloca
11 ret void
12}
13
14; CHECK-LABEL: {{^}}force_align32:
15; CHECK: ScratchSize: 8{{$}}
16define void @force_align32(<8 x i32>) {
17 %alloca = alloca i8
18 store volatile i8 0, i8* %alloca
19 ret void
20}
21
22; CHECK-LABEL: {{^}}force_align64:
23; CHECK: ScratchSize: 8{{$}}
24define void @force_align64(<16 x i32>) {
25 %alloca = alloca i8
26 store volatile i8 0, i8* %alloca
27 ret void
28}
29
30; CHECK-LABEL: {{^}}force_align128:
31; CHECK: ScratchSize: 8{{$}}
32define void @force_align128(<32 x i32>) {
33 %alloca = alloca i8
34 store volatile i8 0, i8* %alloca
35 ret void
36}
37
38; CHECK-LABEL: {{^}}force_align256:
39; CHECK: ScratchSize: 8{{$}}
40define void @force_align256(<64 x i32>) {
41 %alloca = alloca i8
42 store volatile i8 0, i8* %alloca
43 ret void
44}