3e6fee4751
The compiler is able to optimize away most of the instructions that we test, which results in checking only the compiler support for intrinsics, and not the assembler capability to translate SSSE3 and AVX2 instructions from assembler into the actual binary code. This commit forces the compiler to actually emit instructions in the assembler, which then tests binutils capability to translate those into binary code.
20 lines
466 B
C++
20 lines
466 B
C++
/*
|
|
* Copyright Andrey Semashev 2007 - 2015.
|
|
* Distributed under the Boost Software License, Version 1.0.
|
|
* (See accompanying file LICENSE_1_0.txt or copy at
|
|
* http://www.boost.org/LICENSE_1_0.txt)
|
|
*/
|
|
|
|
#include <tmmintrin.h>
|
|
|
|
void pretend_used(__m128i*);
|
|
|
|
int main(int, char*[])
|
|
{
|
|
__m128i mm = _mm_setzero_si128();
|
|
pretend_used(&mm);
|
|
mm = _mm_shuffle_epi8(_mm_alignr_epi8(mm, mm, 10), mm);
|
|
pretend_used(&mm);
|
|
return 0;
|
|
}
|