I want to use AVX intrinsic, like: __m256 factor_min = _mm256_set1_ps(1.329227); but I got the following compile error:
Always_inline function '_mm256_set1_ps' requires target feature 'xsave', but would be inlined into function 'AveragePooling' that is compiled without support for 'xsave'
My environment is:MacOs + Intel Core i7 + xcode8.3 I have seen other discussion about 'xsave'.But still don't know how to fix this compile error.I know nothing about assembly instructions.Is there any easy way to fix this error(maybe just change xode setting?)? Thanks a lot.
I think Intel Core i7 can totally support AVX.
I had this same compilation issue on Xcode 9.2 on a 2017 MacBook Pro - which supports up to AVX2.
I was able to get it to compile by manually configuring the AVX vector extensions, instead of using "Platform Default".
To find out whether your CPU supports AVX, check the output of the following command in a terminal to see if it shows AVX or even AVX2:
sysctl -a | grep machdep.cpu.features
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With