Tanya Lattner | b92ae0e | 2011-04-15 22:42:59 +0000 | [diff] [blame] | 1 | // RUN: %clang_cc1 %s -emit-llvm -o %t |
| 2 | |
Tanya Lattner | b6385e8 | 2011-04-16 01:00:29 +0000 | [diff] [blame] | 3 | typedef __attribute__((ext_vector_type(4))) unsigned char uchar4; |
Tanya Lattner | b6385e8 | 2011-04-16 01:00:29 +0000 | [diff] [blame] | 4 | typedef __attribute__((ext_vector_type(8))) unsigned char uchar8; |
Tanya Lattner | b92ae0e | 2011-04-15 22:42:59 +0000 | [diff] [blame] | 5 | |
| 6 | // OpenCL allows vectors to be initialized by vectors Handle bug in |
| 7 | // VisitInitListExpr for this case below. |
Tanya Lattner | 9934078 | 2011-07-07 00:12:54 +0000 | [diff] [blame] | 8 | void foo( uchar8 x ) |
Tanya Lattner | b92ae0e | 2011-04-15 22:42:59 +0000 | [diff] [blame] | 9 | { |
Tanya Lattner | 9934078 | 2011-07-07 00:12:54 +0000 | [diff] [blame] | 10 | uchar4 val[4] = {{(uchar4){x.lo}}}; |
| 11 | } |