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

Skip to content

Commit 385f78d

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 8f7945b commit 385f78d

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
@@ -850,7 +850,7 @@ foreach gen_mtargets : [
850850
],
851851
[
852852
'loops_comparison.dispatch.h',
853-
src_file.process('src/umath/loops_comparison.dispatch.c.src'),
853+
'src/umath/loops_comparison.dispatch.cpp',
854854
[
855855
AVX512_SKX, AVX512F, AVX2, SSE42, SSE2,
856856
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