Skip to content

Commit 99ee0c1

Browse files
author
Raghuveer Devulapalli
committed
BLD: Conditionally add SVML FP16 objects
1 parent 0a0ac43 commit 99ee0c1

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

‎numpy/_core/meson.build‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1137,6 +1137,12 @@ src_umath = umath_gen_headers + [
11371137
# here. Note that this migration is desirable; we then get the performance
11381138
# benefits for all platforms rather than only for AVX512 on 64-bit Linux, and
11391139
# may be able to avoid the accuracy regressions in SVML.
1140+
1141+
svml_file_suffix = ['d_la', 's_la', 'd_ha', 's_la']
1142+
if CPU_DISPATCH_NAMES.contains('AVX512_SPR')
1143+
svml_file_suffix += ['h_la']
1144+
endif
1145+
11401146
svml_objects = []
11411147
if use_svml
11421148
foreach svml_func : [
@@ -1151,7 +1157,7 @@ if use_svml
11511157
'pow', 'sin', 'sinh', 'tan',
11521158
'tanh'
11531159
]
1154-
foreach svml_sfx : ['d_la', 's_la', 'd_ha', 's_la', 'h_la']
1160+
foreach svml_sfx : svml_file_suffix
11551161
svml_objects += [
11561162
'src/umath/svml/linux/avx512/svml_z0_'+svml_func+'_'+svml_sfx+'.s'
11571163
]

0 commit comments

Comments
 (0)