Files
eepp/include/eepp/core/simd.hpp
Martín Lucas Golini 1a3aeb31e0 Added SIMD to String::isAscii, check if this builds in every platform or I have to revert.
Fixed emscripten 3 and 4 build issues (i had 2 mains defined 🤦).
2025-01-29 00:32:16 -03:00

26 lines
548 B
C++

#pragma once
#include <eepp/config.hpp>
#if EE_PLATFORM != EE_PLATFORM_EMSCRIPTEN
#if __has_include( <simd>) && __cplusplus >= 202002L
#include <simd> // C++23 std::simd
#define USE_STD_SIMD
#elif __has_include( <experimental/simd>)
#include <experimental/simd> // Parallelism TS v2
#define USE_EXPERIMENTAL_SIMD
#endif
#ifdef USE_STD_SIMD
namespace simd = std;
#elif defined( USE_EXPERIMENTAL_SIMD )
namespace simd = std::experimental;
#endif
#if defined( USE_STD_SIMD ) || defined( USE_EXPERIMENTAL_SIMD )
#define EE_STD_SIMD
#endif
#endif