Intellisense is not 100% compatible with CLang, sometimes it shows bogus errors that actually do not exist.chrisw wrote: ↑Tue Apr 11, 2023 8:07 pmimmintrin.h declared more often helped.chrisw wrote: ↑Tue Apr 11, 2023 7:34 pmAhh! That's where it was hiding. 100 new warnings and one successful compile later, and crash. Well, it's a start, probably too much to hope for instant success ...Bo Persson wrote: ↑Tue Apr 11, 2023 6:56 pmCheck your Project Properties. In the Platform Toolset drop down box you should have LLVM as an alternative.
some intrinsics it seems unable to find, eg:
_mm_srli_si128
You can also try to explicitly add the CLang intrinsic headers to your source like:
Code: Select all
#ifdef __clang__
#include <popcntintrin.h>
#include <lzcntintrin.h>
#include <bmi2intrin.h>
#include <immintrin.h>
#include <avxintrin.h>
#include <avx2intrin.h>
#endif
It seems you are using an AMD 7950X (Zen4), in this case it would be better to install LLVM 16 because it can generate and optimize code for the Zen4 with "-march=znver4"
If you want to try this, you also have to add the manifest file I showed earlier, and you have to change the LLVM version under the advanced project settings to 16.
Alternatively you can try to compile with "-march=x86-64-v4", this will include AVX-512 too.