File tree Expand file tree Collapse file tree 3 files changed +8
-7
lines changed Expand file tree Collapse file tree 3 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,8 @@ static int check_cpu_feature_support(std::string_view cpufeature)
10
10
const char *disable_avx512 = std::getenv (" XSS_DISABLE_AVX512" );
11
11
12
12
if ((cpufeature == " avx512_spr" ) && (!disable_avx512))
13
- #if defined(__FLT16_MAX__) && !defined(__INTEL_LLVM_COMPILER)
13
+ #if defined(__FLT16_MAX__) && !defined(__INTEL_LLVM_COMPILER) \
14
+ && __clang_major__ >= 18
14
15
return __builtin_cpu_supports (" avx512f" )
15
16
&& __builtin_cpu_supports (" avx512fp16" )
16
17
&& __builtin_cpu_supports (" avx512vbmi2" );
Original file line number Diff line number Diff line change @@ -406,10 +406,10 @@ struct avx2_vector<uint64_t> {
406
406
};
407
407
408
408
/*
409
- * workaround on 64-bit macOS which defines size_t as unsigned long and defines
410
- * uint64_t as unsigned long long, both of which are 8 bytes
409
+ * workaround on 64-bit macOS and OpenBSD which both define size_t as unsigned
410
+ * long and define uint64_t as unsigned long long, both of which are 8 bytes
411
411
*/
412
- #if defined(__APPLE__) && defined(__x86_64__)
412
+ #if ( defined(__APPLE__) || defined(__OpenBSD__) ) && defined(__x86_64__)
413
413
static_assert (sizeof (size_t ) == sizeof (uint64_t ),
414
414
" Size of size_t and uint64_t are not the same" );
415
415
template <>
Original file line number Diff line number Diff line change @@ -960,10 +960,10 @@ struct zmm_vector<uint64_t> {
960
960
};
961
961
962
962
/*
963
- * workaround on 64-bit macOS which defines size_t as unsigned long and defines
964
- * uint64_t as unsigned long long, both of which are 8 bytes
963
+ * workaround on 64-bit macOS and OpenBSD which both define size_t as unsigned
964
+ * long and define uint64_t as unsigned long long, both of which are 8 bytes
965
965
*/
966
- #if defined(__APPLE__) && defined(__x86_64__)
966
+ #if ( defined(__APPLE__) || defined(__OpenBSD__) ) && defined(__x86_64__)
967
967
static_assert (sizeof (size_t ) == sizeof (uint64_t ),
968
968
" Size of size_t and uint64_t are not the same" );
969
969
template <>
You can’t perform that action at this time.
0 commit comments