Skip to content

Commit 2983386

Browse files
author
Raghuveer Devulapalli
committed
Revert back to NPY_SIMD_FMA3
1 parent c535a4a commit 2983386

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

numpy/_core/src/umath/loops_trigonometric.dispatch.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ namespace hn = hwy::HWY_NAMESPACE;
3030
* elements or when there's no native FUSED support instead of fallback to libc
3131
*/
3232

33-
#if HWY_NATIVE_FMA // native support
33+
#if NPY_SIMD_FMA3 // native support
3434
typedef enum
3535
{
3636
SIMD_COMPUTE_SIN,
@@ -192,7 +192,7 @@ simd_sincos_f32(const float *src, npy_intp ssrc, float *dst, npy_intp sdst,
192192
npyv_cleanup();
193193
}
194194
}
195-
#endif // HWY_NATIVE_FMA
195+
#endif // NPY_SIMD_FMA3
196196

197197
/* Disable SIMD code sin/cos f64 and revert to libm: see
198198
* https://mail.python.org/archives/list/[email protected]/thread/C6EYZZSR4EWGVKHAZXLE7IBILRMNVK7L/
@@ -213,7 +213,7 @@ DISPATCH_DOUBLE_FUNC(cos)
213213
NPY_NO_EXPORT void NPY_CPU_DISPATCH_CURFX(FLOAT_sin)
214214
(char **args, npy_intp const *dimensions, npy_intp const *steps, void *NPY_UNUSED(data))
215215
{
216-
#if HWY_NATIVE_FMA
216+
#if NPY_SIMD_FMA3
217217
const npy_float *src = (npy_float*)args[0];
218218
npy_float *dst = (npy_float*)args[1];
219219

@@ -242,7 +242,7 @@ NPY_NO_EXPORT void NPY_CPU_DISPATCH_CURFX(FLOAT_sin)
242242
NPY_NO_EXPORT void NPY_CPU_DISPATCH_CURFX(FLOAT_cos)
243243
(char **args, npy_intp const *dimensions, npy_intp const *steps, void *NPY_UNUSED(data))
244244
{
245-
#if HWY_NATIVE_FMA
245+
#if NPY_SIMD_FMA3
246246
const npy_float *src = (npy_float*)args[0];
247247
npy_float *dst = (npy_float*)args[1];
248248

0 commit comments

Comments
 (0)