Mercurial > hg > sv-dependency-builds
comparison src/fftw-3.3.8/simd-support/kcvi.c @ 167:bd3cc4d1df30
Add FFTW 3.3.8 source, and a Linux build
author | Chris Cannam <cannam@all-day-breakfast.com> |
---|---|
date | Tue, 19 Nov 2019 14:52:55 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
166:cbd6d7e562c7 | 167:bd3cc4d1df30 |
---|---|
1 /* | |
2 * Copyright (c) 2003, 2007-11 Matteo Frigo | |
3 * Copyright (c) 2003, 2007-11 Massachusetts Institute of Technology | |
4 * Copyright (c) 2012-2013 Romain Dolbeau | |
5 * | |
6 * Permission is hereby granted, free of charge, to any person obtaining a copy | |
7 * of this software and associated documentation files (the "Software"), to deal | |
8 * in the Software without restriction, including without limitation the rights | |
9 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
10 * copies of the Software, and to permit persons to whom the Software is | |
11 * furnished to do so, subject to the following conditions: | |
12 * | |
13 * The above copyright notice and this permission notice shall be included in | |
14 * all copies or substantial portions of the Software. | |
15 * | |
16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
17 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | |
19 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
20 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | |
21 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | |
22 * THE SOFTWARE. | |
23 * | |
24 */ | |
25 | |
26 #include "kernel/ifftw.h" | |
27 | |
28 #if HAVE_KCVI | |
29 | |
30 #if defined(__x86_64__) || defined(_M_X64) || defined(_M_AMD64) | |
31 | |
32 #include "amd64-cpuid.h" | |
33 | |
34 int X(have_simd_kcvi)(void) | |
35 { | |
36 static int init = 0, res; | |
37 if (!init) { | |
38 res = 1; | |
39 init = 1; | |
40 } | |
41 return res; | |
42 } | |
43 | |
44 #else /* 32-bit code */ | |
45 | |
46 #error "KCvi is 64 bits only" | |
47 | |
48 #endif | |
49 | |
50 #endif |