1 | /* |
2 | Copyright Charly Chevalier 2015 |
3 | Copyright Joel Falcou 2015 |
4 | Distributed under the Boost Software License, Version 1.0. |
5 | (See accompanying file LICENSE_1_0.txt or copy at |
6 | http://www.boost.org/LICENSE_1_0.txt) |
7 | */ |
8 | |
9 | #ifndef BOOST_PREDEF_HARDWARE_SIMD_PPC_H |
10 | #define BOOST_PREDEF_HARDWARE_SIMD_PPC_H |
11 | |
12 | #include <boost/predef/version_number.h> |
13 | #include <boost/predef/hardware/simd/ppc/versions.h> |
14 | |
15 | /*` |
16 | [heading `BOOST_HW_SIMD_PPC`] |
17 | |
18 | The SIMD extension for PowerPC (*if detected*). |
19 | Version number depends on the most recent detected extension. |
20 | |
21 | [table |
22 | [[__predef_symbol__] [__predef_version__]] |
23 | |
24 | [[`__VECTOR4DOUBLE__`] [__predef_detection__]] |
25 | |
26 | [[`__ALTIVEC__`] [__predef_detection__]] |
27 | [[`__VEC__`] [__predef_detection__]] |
28 | |
29 | [[`__VSX__`] [__predef_detection__]] |
30 | ] |
31 | |
32 | [table |
33 | [[__predef_symbol__] [__predef_version__]] |
34 | |
35 | [[`__VECTOR4DOUBLE__`] [BOOST_HW_SIMD_PPC_QPX_VERSION]] |
36 | |
37 | [[`__ALTIVEC__`] [BOOST_HW_SIMD_PPC_VMX_VERSION]] |
38 | [[`__VEC__`] [BOOST_HW_SIMD_PPC_VMX_VERSION]] |
39 | |
40 | [[`__VSX__`] [BOOST_HW_SIMD_PPC_VSX_VERSION]] |
41 | ] |
42 | |
43 | */ |
44 | |
45 | #define BOOST_HW_SIMD_PPC BOOST_VERSION_NUMBER_NOT_AVAILABLE |
46 | |
47 | #undef BOOST_HW_SIMD_PPC |
48 | #if !defined(BOOST_HW_SIMD_PPC) && defined(__VECTOR4DOUBLE__) |
49 | # define BOOST_HW_SIMD_PPC BOOST_HW_SIMD_PPC_QPX_VERSION |
50 | #endif |
51 | #if !defined(BOOST_HW_SIMD_PPC) && defined(__VSX__) |
52 | # define BOOST_HW_SIMD_PPC BOOST_HW_SIMD_PPC_VSX_VERSION |
53 | #endif |
54 | #if !defined(BOOST_HW_SIMD_PPC) && (defined(__ALTIVEC__) || defined(__VEC__)) |
55 | # define BOOST_HW_SIMD_PPC BOOST_HW_SIMD_PPC_VMX_VERSION |
56 | #endif |
57 | |
58 | #if !defined(BOOST_HW_SIMD_PPC) |
59 | # define BOOST_HW_SIMD_PPC BOOST_VERSION_NUMBER_NOT_AVAILABLE |
60 | #else |
61 | # define BOOST_HW_SIMD_PPC_AVAILABLE |
62 | #endif |
63 | |
64 | #define BOOST_HW_SIMD_PPC_NAME "PPC SIMD" |
65 | |
66 | #endif |
67 | |
68 | #include <boost/predef/detail/test.h> |
69 | BOOST_PREDEF_DECLARE_TEST(BOOST_HW_SIMD_PPC, BOOST_HW_SIMD_PPC_NAME) |
70 | |