1
Description: Fix SSE2 and SSE3 runtime test
2
The tests for SSE2 and SSE3 were previously exactly the same as the test
3
for SSE. This patch fix this by using the correct bitmask and correct
4
register after cpuid instruction.
5
Origin: upstream, commit:496993bd58e91ae3c7c3057e76c5d5e891c1f261
6
Author: Nicolas Bourdaud <nicolas.bourdaud@gmail.com>
7
Last-Update: 2012-01-25
13
- Copyright (C) 2011 Nicolas Bourdaud <nicolas.bourdaud@epfl.ch>
14
+ Copyright (C) 2011-2012 Nicolas Bourdaud <nicolas.bourdaud@epfl.ch>
16
This file is part of the rtfilter library
19
int cputest_sse2(void)
21
unsigned int eax, ebx, ecx, edx;
22
- if (__get_cpuid(1, &eax, &ebx, &ecx, &edx) && (edx & bit_SSE))
23
+ if (__get_cpuid(1, &eax, &ebx, &ecx, &edx) && (edx & bit_SSE2))
28
int cputest_sse3(void)
30
unsigned int eax, ebx, ecx, edx;
31
- if (__get_cpuid(1, &eax, &ebx, &ecx, &edx) && (edx & bit_SSE))
32
+ if (__get_cpuid(1, &eax, &ebx, &ecx, &edx) && (ecx & bit_SSE3))