Daniel Dunbar | edfac03 | 2012-03-10 01:03:58 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 -emit-llvm %s -o %t -triple=x86_64-apple-darwin10 |
| 2 | // RUN: FileCheck < %t %s |
Eli Friedman | 70cbd2a | 2011-06-15 18:26:32 +0000 | [diff] [blame] | 3 | |
Daniel Dunbar | edfac03 | 2012-03-10 01:03:58 +0000 | [diff] [blame] | 4 | // Make sure this doesn't crash. We used to generate a byval here and wanted to |
| 5 | // verify a valid alignment, but we now realize we can use an i16 and let the |
| 6 | // backend guarantee the alignment. |
Eli Friedman | 70cbd2a | 2011-06-15 18:26:32 +0000 | [diff] [blame] | 7 | |
| 8 | void a(int,int,int,int,int,int,__complex__ char); |
| 9 | void b(__complex__ char *y) { a(0,0,0,0,0,0,*y); } |
| 10 | // CHECK: define void @b |
Chris Lattner | 9cbe4f0 | 2011-07-09 17:41:47 +0000 | [diff] [blame] | 11 | // CHECK: alloca { i8, i8 }*, align 8 |
Daniel Dunbar | edfac03 | 2012-03-10 01:03:58 +0000 | [diff] [blame] | 12 | // CHECK: call void @a(i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i16 {{.*}}) |