summaryrefslogtreecommitdiffstats
path: root/pstl/test/support
diff options
context:
space:
mode:
authorLouis Dionne <ldionne@apple.com>2019-04-10 19:51:40 +0000
committerLouis Dionne <ldionne@apple.com>2019-04-10 19:51:40 +0000
commit3dee12e4a57241e4a53687f4a4e463b581dabf46 (patch)
tree67f01614fe364c0f768a0a5961791c7cd28b2a32 /pstl/test/support
parent0352f201dd3cf9ec83bf527eeef0b464214ff243 (diff)
downloadbcm5719-llvm-3dee12e4a57241e4a53687f4a4e463b581dabf46.tar.gz
bcm5719-llvm-3dee12e4a57241e4a53687f4a4e463b581dabf46.zip
[pstl] Move to single underscore-capital for macros and include guards
Summary: Per the LLVM convention. Reviewers: rodgert Subscribers: jkorous, dexonsmith, jdoerfert, libcxx-commits Tags: #libc Differential Revision: https://reviews.llvm.org/D60521 llvm-svn: 358131
Diffstat (limited to 'pstl/test/support')
-rw-r--r--pstl/test/support/pstl_test_config.h42
-rw-r--r--pstl/test/support/utils.h14
2 files changed, 28 insertions, 28 deletions
diff --git a/pstl/test/support/pstl_test_config.h b/pstl/test/support/pstl_test_config.h
index 10b872498c3..84004921fb5 100644
--- a/pstl/test/support/pstl_test_config.h
+++ b/pstl/test/support/pstl_test_config.h
@@ -7,43 +7,43 @@
//
//===----------------------------------------------------------------------===//
-#ifndef __PSTL_TEST_config_H
-#define __PSTL_TEST_config_H
+#ifndef _PSTL_TEST_config_H
+#define _PSTL_TEST_config_H
#if defined(_MSC_VER) && defined(_DEBUG)
#define _SCL_SECURE_NO_WARNINGS //to prevent the compilation warning. Microsoft STL implementation has specific checking of an iterator range in DEBUG mode for the containers from the standard library.
#endif
-#define __PSTL_ICC_16_17_TEST_REDUCTION_BOOL_TYPE_RELEASE_64_BROKEN \
+#define _PSTL_ICC_16_17_TEST_REDUCTION_BOOL_TYPE_RELEASE_64_BROKEN \
(__x86_64 && !_DEBUG && __INTEL_COMPILER && __INTEL_COMPILER <= 1700 && !__APPLE__)
-#define __PSTL_ICC_16_17_TEST_REDUCTION_RELEASE_BROKEN \
+#define _PSTL_ICC_16_17_TEST_REDUCTION_RELEASE_BROKEN \
(!_DEBUG && __INTEL_COMPILER && \
(__INTEL_COMPILER < 1800 || (__INTEL_COMPILER == 1800 && __INTEL_COMPILER_UPDATE < 1)))
-#define __PSTL_ICC_1800_TEST_MONOTONIC_RELEASE_64_BROKEN \
+#define _PSTL_ICC_1800_TEST_MONOTONIC_RELEASE_64_BROKEN \
(__x86_64 && !_DEBUG && __INTEL_COMPILER && __INTEL_COMPILER == 1800 && __INTEL_COMPILER_UPDATE < 1)
-#define __PSTL_ICC_17_TEST_MAC_RELEASE_32_BROKEN \
+#define _PSTL_ICC_17_TEST_MAC_RELEASE_32_BROKEN \
(__i386__ && !_DEBUG && __INTEL_COMPILER >= 1700 && __INTEL_COMPILER < 1800 && __APPLE__)
-#define __PSTL_ICC_18_VC141_TEST_SIMD_LAMBDA_RELEASE_BROKEN \
+#define _PSTL_ICC_18_VC141_TEST_SIMD_LAMBDA_RELEASE_BROKEN \
(!_DEBUG && __INTEL_COMPILER >= 1800 && __INTEL_COMPILER < 1900 && _MSC_VER == 1910)
-#define __PSTL_ICC_17_VC141_TEST_SIMD_LAMBDA_DEBUG_32_BROKEN \
+#define _PSTL_ICC_17_VC141_TEST_SIMD_LAMBDA_DEBUG_32_BROKEN \
(_M_IX86 && _DEBUG && __INTEL_COMPILER >= 1700 && __INTEL_COMPILER < 1800 && _MSC_VER >= 1900)
-#define __PSTL_ICC_16_VC14_TEST_SIMD_LAMBDA_DEBUG_32_BROKEN \
+#define _PSTL_ICC_16_VC14_TEST_SIMD_LAMBDA_DEBUG_32_BROKEN \
(_M_IX86 && _DEBUG && __INTEL_COMPILER >= 1600 && __INTEL_COMPILER < 1700 && _MSC_VER == 1900)
-#define __PSTL_ICC_16_VC14_TEST_PAR_TBB_RT_RELEASE_64_BROKEN \
- (__PSTL_USE_PAR_POLICIES && ((_M_X64 && _MSC_VER == 1900) || __x86_64) && !_DEBUG && __INTEL_COMPILER < 1700)
-#define __PSTL_ICC_16_17_TEST_64_TIMEOUT (__x86_64 && __INTEL_COMPILER && __INTEL_COMPILER < 1800 && !__APPLE__)
-#define __PSTL_ICC_18_TEST_EARLY_EXIT_MONOTONIC_RELEASE_BROKEN (!_DEBUG && __INTEL_COMPILER && __INTEL_COMPILER == 1800)
-#define __PSTL_CLANG_TEST_BIG_OBJ_DEBUG_32_BROKEN \
- (__i386__ && PSTL_USE_DEBUG && __clang__ && __PSTL_CLANG_VERSION <= 90000)
-#define __PSTL_ICC_16_17_18_TEST_UNIQUE_MASK_RELEASE_BROKEN \
+#define _PSTL_ICC_16_VC14_TEST_PAR_TBB_RT_RELEASE_64_BROKEN \
+ (_PSTL_USE_PAR_POLICIES && ((_M_X64 && _MSC_VER == 1900) || __x86_64) && !_DEBUG && __INTEL_COMPILER < 1700)
+#define _PSTL_ICC_16_17_TEST_64_TIMEOUT (__x86_64 && __INTEL_COMPILER && __INTEL_COMPILER < 1800 && !__APPLE__)
+#define _PSTL_ICC_18_TEST_EARLY_EXIT_MONOTONIC_RELEASE_BROKEN (!_DEBUG && __INTEL_COMPILER && __INTEL_COMPILER == 1800)
+#define _PSTL_CLANG_TEST_BIG_OBJ_DEBUG_32_BROKEN \
+ (__i386__ && PSTL_USE_DEBUG && __clang__ && _PSTL_CLANG_VERSION <= 90000)
+#define _PSTL_ICC_16_17_18_TEST_UNIQUE_MASK_RELEASE_BROKEN \
(!_DEBUG && __INTEL_COMPILER && \
(__INTEL_COMPILER < 1800 || (__INTEL_COMPILER == 1800 && __INTEL_COMPILER_UPDATE < 3)))
-#define __PSTL_ICC_18_TEST_EARLY_EXIT_AVX_RELEASE_BROKEN \
+#define _PSTL_ICC_18_TEST_EARLY_EXIT_AVX_RELEASE_BROKEN \
(!_DEBUG && __INTEL_COMPILER == 1800 && __AVX__ && !__AVX2__ && !__AVX512__)
-#define __PSTL_ICC_19_TEST_IS_PARTITIONED_RELEASE_BROKEN \
+#define _PSTL_ICC_19_TEST_IS_PARTITIONED_RELEASE_BROKEN \
(!PSTL_USE_DEBUG && (__linux__ || __APPLE__) && __INTEL_COMPILER == 1900)
-#define __PSTL_ICL_19_VC14_VC141_TEST_SCAN_RELEASE_BROKEN \
+#define _PSTL_ICL_19_VC14_VC141_TEST_SCAN_RELEASE_BROKEN \
(__INTEL_COMPILER == 1900 && _MSC_VER >= 1900 && _MSC_VER <= 1910)
-#define __PSTL_ICC_19_TEST_SIMD_UDS_WINDOWS_RELEASE_BROKEN (__INTEL_COMPILER == 1900 && _MSC_VER && !_DEBUG)
+#define _PSTL_ICC_19_TEST_SIMD_UDS_WINDOWS_RELEASE_BROKEN (__INTEL_COMPILER == 1900 && _MSC_VER && !_DEBUG)
-#endif /* __PSTL_TEST_config_H */
+#endif /* _PSTL_TEST_config_H */
diff --git a/pstl/test/support/utils.h b/pstl/test/support/utils.h
index e4ef92c2608..e06c5aaa68c 100644
--- a/pstl/test/support/utils.h
+++ b/pstl/test/support/utils.h
@@ -572,7 +572,7 @@ struct Matrix2x2
T a[2][2];
Matrix2x2() : a{{1, 0}, {0, 1}} {}
Matrix2x2(T x, T y) : a{{0, x}, {x, y}} {}
-#if !__PSTL_ICL_19_VC14_VC141_TEST_SCAN_RELEASE_BROKEN
+#if !_PSTL_ICL_19_VC14_VC141_TEST_SCAN_RELEASE_BROKEN
Matrix2x2(const Matrix2x2& m) : a{{m.a[0][0], m.a[0][1]}, {m.a[1][0], m.a[1][1]}} {}
Matrix2x2&
operator=(const Matrix2x2& m)
@@ -607,9 +607,9 @@ multiply_matrix(const Matrix2x2<T>& left, const Matrix2x2<T>& right)
}
// Check that Intel(R) Threading Building Blocks header files are not used when parallel policies are off
-#if !__PSTL_USE_PAR_POLICIES
+#if !_PSTL_USE_PAR_POLICIES
#if defined(TBB_INTERFACE_VERSION)
-#error The parallel backend is used while it should not (__PSTL_USE_PAR_POLICIES==0)
+#error The parallel backend is used while it should not (_PSTL_USE_PAR_POLICIES==0)
#endif
#endif
@@ -658,7 +658,7 @@ struct ReverseAdapter
iterator_type
operator()(Iterator it)
{
-#if __PSTL_CPP14_MAKE_REVERSE_ITERATOR_PRESENT
+#if _PSTL_CPP14_MAKE_REVERSE_ITERATOR_PRESENT
return std::make_reverse_iterator(it);
#else
return iterator_type(it);
@@ -1051,7 +1051,7 @@ invoke_on_all_policies(Op op, T&&... rest)
// Try static execution policies
invoke_on_all_iterator_types()(seq, op, std::forward<T>(rest)...);
invoke_on_all_iterator_types()(unseq, op, std::forward<T>(rest)...);
-#if __PSTL_USE_PAR_POLICIES
+#if _PSTL_USE_PAR_POLICIES
invoke_on_all_iterator_types()(par, op, std::forward<T>(rest)...);
invoke_on_all_iterator_types()(par_unseq, op, std::forward<T>(rest)...);
#endif
@@ -1200,7 +1200,7 @@ transform_reduce_serial(InputIterator first, InputIterator last, T init, BinaryO
static const char*
done()
{
-#if __PSTL_TEST_SUCCESSFUL_KEYWORD
+#if _PSTL_TEST_SUCCESSFUL_KEYWORD
return "done";
#else
return "passed";
@@ -1237,7 +1237,7 @@ template <typename Policy, typename F>
static void
invoke_if(Policy&& p, F f)
{
-#if __PSTL_ICC_16_VC14_TEST_SIMD_LAMBDA_DEBUG_32_BROKEN || __PSTL_ICC_17_VC141_TEST_SIMD_LAMBDA_DEBUG_32_BROKEN
+#if _PSTL_ICC_16_VC14_TEST_SIMD_LAMBDA_DEBUG_32_BROKEN || _PSTL_ICC_17_VC141_TEST_SIMD_LAMBDA_DEBUG_32_BROKEN
__pstl::__internal::invoke_if_not(__pstl::__internal::allow_unsequenced<Policy>(), f);
#else
f();
OpenPOWER on IntegriCloud