8000 ENH: Refactor comparison operations SIMD kernels using C++ · numpy/numpy@b70cda0 · GitHub
[go: up one dir, main page]

Skip to content

Commit b70cda0

Browse files
committed
ENH: Refactor comparison operations SIMD kernels using C++
To eliminate C template sources and enable support for sizeless SIMD extensions.
1 parent 82d7a3c commit b70cda0

File tree

4 files changed

+500
-457
lines changed

4 files changed

+500
-457
lines changed

numpy/_core/meson.build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -851,7 +851,7 @@ foreach gen_mtargets : [
851851
],
852852
[
853853
'loops_comparison.dispatch.h',
854-
src_file.process('src/umath/loops_comparison.dispatch.c.src'),
854+
'src/umath/loops_comparison.dispatch.cpp',
855855
[
856856
AVX512_SKX, AVX512F, AVX2, SSE42, SSE2,
857857
VSX3, VSX2,

numpy/_core/src/umath/loops.h.src

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@
1010
#define NPY_NO_EXPORT NPY_VISIBILITY_HIDDEN
1111
#endif
1212

13+
#ifdef __cplusplus
14+
extern "C" {
15+
#endif
1316
/*
1417
*****************************************************************************
1518
** BOOLEAN LOOPS **
@@ -876,4 +879,7 @@ PyUFunc_OOO_O(char **args, npy_intp const *dimensions, npy_intp const *steps, vo
876879
*****************************************************************************
877880
*/
878881

882+
#ifdef __cplusplus
883+
}
884+
#endif
879885
#endif

0 commit comments

Comments
 (0)
0