aboutsummaryrefslogtreecommitdiffstats
path: root/src/build-data/buildh.in
diff options
context:
space:
mode:
Diffstat (limited to 'src/build-data/buildh.in')
-rw-r--r--src/build-data/buildh.in46
1 files changed, 46 insertions, 0 deletions
diff --git a/src/build-data/buildh.in b/src/build-data/buildh.in
index 56b70e060..0702d1416 100644
--- a/src/build-data/buildh.in
+++ b/src/build-data/buildh.in
@@ -264,6 +264,52 @@ Each read generates 32 bits of output
#define BOTAN_NOEXCEPT noexcept
#endif
+#if !defined(BOTAN_PARALLEL_FOR)
+
+#if defined(BOTAN_TARGET_HAS_CILKPLUS)
+ #define BOTAN_PARALLEL_FOR _Cilk_for
+#elif defined(BOTAN_TARGET_HAS_OPENMP)
+ #define BOTAN_PARALLEL_FOR _Pragma("omp parallel for") for
+#else
+ #define BOTAN_PARALLEL_FOR for
+#endif
+
+#endif
+
+#if !defined(BOTAN_PARALLEL_SIMD_FOR)
+
+#if defined(BOTAN_TARGET_HAS_CILKPLUS)
+ #define BOTAN_PARALLEL_SIMD_FOR _Pragma("simd") for
+#elif defined(BOTAN_TARGET_HAS_OPENMP)
+ #define BOTAN_PARALLEL_SIMD_FOR _Pragma("omp simd") for
+#elif defined(BOTAN_TARGET_COMPILER_IS_GCC)
+ #define BOTAN_PARALLEL_FOR _Pragma("GCC ivdep") for
+#else
+ #define BOTAN_PARALLEL_SIMD_FOR for
+#endif
+
+#endif
+
+#if !defined(BOTAN_PARALLEL_SPAWN)
+
+#if defined(BOTAN_TARGET_HAS_CILKPLUS)
+ #define BOTAN_PARALLEL_SPAWN _Cilk_spawn
+#else
+ #define BOTAN_PARALLEL_SPAWN
+#endif
+
+#endif
+
+#if !defined(BOTAN_PARALLEL_SYNC)
+
+#if defined(BOTAN_TARGET_HAS_CILKPLUS)
+ #define BOTAN_PARALLEL_SYNC _Cilk_sync
+#else
+ #define BOTAN_PARALLEL_SYNC BOTAN_FORCE_SEMICOLON
+#endif
+
+#endif
+
/*
* Module availability definitions
*/