Bruno Cardoso Lopes | 3f7eb9a | 2011-08-24 01:35:04 +0000 | [diff] [blame^] | 1 | // RUN: %clang_cc1 %s -O3 -triple=x86_64-apple-darwin -target-feature +avx -emit-llvm -o - | FileCheck %s |
| 2 | |
| 3 | // Don't include mm_malloc.h, it's system specific. |
| 4 | #define __MM_MALLOC_H |
| 5 | |
| 6 | #include <immintrin.h> |
| 7 | |
| 8 | // |
| 9 | // Test LLVM IR codegen of shuffle instructions |
| 10 | // |
| 11 | |
| 12 | __m256 x(__m256 a, __m256 b) { |
| 13 | // Check if the mask is correct |
| 14 | // CHECK: shufflevector{{.*}}<i32 3, i32 2, i32 8, i32 11, i32 7, i32 6, i32 12, i32 15> |
| 15 | return _mm256_shuffle_ps(a, b, 203); |
| 16 | } |