blob: a383f778ee5af7224eedd9aae21add85c976efc1 [file] [log] [blame]
Eric Christophercc6b6b92010-05-19 00:22:04 +00001// RUN: %llvmgcc -mssse3 -S -o - %s | llc -mtriple=x86_64-apple-darwin | FileCheck %s
2
3#include <tmmintrin.h>
4
5int main ()
6{
7#if defined( __SSSE3__ )
8
9#define vec_rld_epi16( _a, _i ) ({ vSInt16 _t = _a; _t = _mm_alignr_epi8( _t, _t, _i ); /*return*/ _t; })
10 typedef int16_t vSInt16 __attribute__ ((__vector_size__ (16)));
11
12 short dtbl[] = {1,2,3,4,5,6,7,8};
13 vSInt16 *vdtbl = (vSInt16*) dtbl;
14
15 vSInt16 v0;
16 v0 = *vdtbl;
17 // CHECK: pshufd $57
18 v0 = vec_rld_epi16( v0, 4 );
19
20 return 0;
21#endif
22}