Exemplo n.º 1
0
int sse4a(){
	__ma128f v;
	double d[2];
	d[0] = -1.;
	d[1] = -2.;
	v.d64[0] = 0.;
	v.d64[1] = 1.;
	_mm_stream_sd(&d[0], v.d);
	for (int i = 0;i < 2; i++){
		if (v.d64[i] != d[i]){
			printf("Wrong result:\n");
			for (int i = 0;i < 2; i++){
				printf("Correct: %f result: %f\n", d[i], v.d64[i]);
			}
			return -1;
		}
	}
	return 0;
}
Exemplo n.º 2
0
void test_mm_stream_sd(double *p, __m128d a) {
  // CHECK-LABEL: test_mm_stream_sd
  // CHECK: call void @llvm.x86.sse4a.movnt.sd(i8* %{{[^,]+}}, <2 x double> %{{[^,]+}})
  _mm_stream_sd(p, a);
}
Exemplo n.º 3
0
static void 
sse4a_test_movntsd (double *out, double *in)
{
  __m128d in_v2df = _mm_load_sd (in);
  _mm_stream_sd (out, in_v2df);
}