Skip to content

Commit 27e5cc9

Browse files
author
Raghuveer Devulapalli
committed
Explicitly initialize with zmm_vector<uint64_t> for arg methods on macOS
1 parent 2de6948 commit 27e5cc9

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/avx512-common-argsort.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,17 @@
1212
#include <stdio.h>
1313
#include <vector>
1414

15+
/* Workaround for NumPy failed build on macOS x86_64: implicit instantiation of
16+
* undefined template 'zmm_vector<unsigned long>'*/
17+
#ifdef __APPLE__
18+
using argtype = typename std::conditional<sizeof(arrsize_t) == sizeof(int32_t),
19+
ymm_vector<uint32_t>,
20+
zmm_vector<uint64_t>>::type;
21+
#else
1522
using argtype = typename std::conditional<sizeof(arrsize_t) == sizeof(int32_t),
1623
ymm_vector<arrsize_t>,
1724
zmm_vector<arrsize_t>>::type;
25+
#endif
1826
using argreg_t = typename argtype::reg_t;
1927

2028
/*

0 commit comments

Comments
 (0)