__config 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. // -*- C++ -*-
  2. //===----------------------------------------------------------------------===//
  3. //
  4. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  5. // See https://llvm.org/LICENSE.txt for license information.
  6. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  7. //
  8. //===----------------------------------------------------------------------===//
  9. #ifndef _LIBCPP_EXPERIMENTAL_CONFIG
  10. #define _LIBCPP_EXPERIMENTAL_CONFIG
  11. #include <__config>
  12. #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
  13. # pragma GCC system_header
  14. #endif
  15. #define _LIBCPP_BEGIN_NAMESPACE_EXPERIMENTAL \
  16. namespace std { \
  17. namespace experimental {
  18. #define _LIBCPP_END_NAMESPACE_EXPERIMENTAL \
  19. } \
  20. }
  21. #define _LIBCPP_BEGIN_NAMESPACE_LFTS _LIBCPP_BEGIN_NAMESPACE_EXPERIMENTAL inline namespace fundamentals_v1 {
  22. #define _LIBCPP_END_NAMESPACE_LFTS \
  23. } \
  24. } \
  25. }
  26. #define _LIBCPP_BEGIN_NAMESPACE_LFTS_V2 _LIBCPP_BEGIN_NAMESPACE_EXPERIMENTAL inline namespace fundamentals_v2 {
  27. #define _LIBCPP_END_NAMESPACE_LFTS_V2 \
  28. } \
  29. } \
  30. }
  31. // TODO: support more targets
  32. #if defined(__AVX__)
  33. # define _LIBCPP_NATIVE_SIMD_WIDTH_IN_BYTES 32
  34. #else
  35. # define _LIBCPP_NATIVE_SIMD_WIDTH_IN_BYTES 16
  36. #endif
  37. #endif