You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The error occures in file pivot_neighb_invindx.cc and it about _mm_prefetch function not found. So I try changing the header of pivot_neighb_invindx.cc like this. It works
Anyone who have the same error like me can try it.
I had to use pip install nmslib --only-binary all (no colon)
But I still got the same compilation problem...
pip install nmslib --only-binary all starts running "setup.py install for nmslib", then errors with error C3861: '_mm_prefetch': identifier not found -- same as before
I am encountering the same error for the nmslib conda-forge recipe that I maintain ( thanks for the awesome library! I am using it in another conda package that I made, and nmslib was not available in the anaconda ecosystem yet so I made the recipe). All of the windows builds error out (for all python 3 versions) but Linux and OSX builds were fine (conda-forge/nmslib-feedstock#6 (comment)).
Activity
searchivarius commentedon Jun 20, 2019
Seems like a similar issue with #394: what is your MS Visual Studio version?
Thank you!
1653091 commentedon Jun 21, 2019
The error occures in file pivot_neighb_invindx.cc and it about _mm_prefetch function not found. So I try changing the header of pivot_neighb_invindx.cc like this. It works

Anyone who have the same error like me can try it.
searchivarius commentedon Jun 21, 2019
Many thanks, I would have to patch & test!
LouisdeBruijn commentedon Jul 11, 2019
any update on this? I am getting an error as well, but no simple fix for it.
barney54321 commentedon Aug 8, 2019
I've also come across this issue on multiple computers, all running Windows 10 and Python 3.7.4
Here's the error from my pip log:
err.txt
searchivarius commentedon Aug 12, 2019
@barney54321 I hope to look into this quite soon (likely after this Wed).
chandansharma02 commentedon Oct 31, 2019
Hi Leonid Boytsov..........Any luck with above?
searchivarius commentedon Oct 31, 2019
We should be soon done with this. We will also be able to provide binaries, albeit they might be a bit slower.
chandansharma02 commentedon Nov 3, 2019
Thank you looking forward for either. I am using windows 10. In case of binaries, speed is less of an issues as of now.
searchivarius commentedon Nov 3, 2019
@chandansharma02 ok, sure, should be done with this today.
searchivarius commentedon Nov 5, 2019
Hi @chandansharma02 could you check if the current binary version works for you? Thank you!
chandansharma02 commentedon Nov 6, 2019
Thank you again. Now I am able to pip install it and able to import the library. Will run the complete code and hope all works.
searchivarius commentedon Nov 6, 2019
Nice, thank you for confirming @chandansharma02
6 remaining items
snosrap commentedon Feb 10, 2020
I had to use
pip install nmslib --only-binary all(no colon)But I still got the same compilation problem...
pip install nmslib --only-binary allstarts running "setup.py install for nmslib", then errors witherror C3861: '_mm_prefetch': identifier not found-- same as beforesearchivarius commentedon Feb 10, 2020
@snosrap which Python version do you have?
snosrap commentedon Feb 10, 2020
searchivarius commentedon Feb 10, 2020
@snosrap unfortunately, we don't have 3.8 yet, 3.7 is the latest.
snosrap commentedon Feb 10, 2020
Ah, that explains it.
Well, I'll be compiling my own using this fix in the meantime. Your windows compilation environment must have access to more header files than mine!
Thanks for looking into this.
searchivarius commentedon Feb 10, 2020
@snosrap yes, the header needs to be fixed too for sure. It's surprising the header set isn't standard accross Windows machines though.
jzthree commentedon Nov 1, 2020
I am encountering the same error for the nmslib conda-forge recipe that I maintain ( thanks for the awesome library! I am using it in another conda package that I made, and nmslib was not available in the anaconda ecosystem yet so I made the recipe). All of the windows builds error out (for all python 3 versions) but Linux and OSX builds were fine (conda-forge/nmslib-feedstock#6 (comment)).
I am not familiar with these headers but it does seem like the fix proposed in this thread (changing mmintrin.h to xmmintrin.h) agrees with Intel's docs that _mm_prefetch is part of xmmintrin.h (https://software.intel.com/sites/landingpage/IntrinsicsGuide/#expand=4391&text=_mm_prefetch).
I also found this useful https://stackoverflow.com/questions/11228855/header-files-for-x86-simd-intrinsics.
searchivarius commentedon Nov 5, 2020
@jzthree yeah, these includes are wrong, I will try to fix them in the upcoming release.
searchivarius commentedon Nov 26, 2020
Hi @jzthree we have updated headers in the develop branch. Could you check if this still causes a trouble? Many thanks!
jzthree commentedon Nov 27, 2020
Great thanks! I can confirm the build problem is gone with the develop branch. The environment I tested was Windows 10 + python 3.8 + vs2017.
searchivarius commentedon Nov 27, 2020
@jzthree awesome, many thanks! we will be rolling out this version quite soon.
searchivarius commentedon Nov 27, 2020
Hi @NancyLi1013 I believe you won't need this patch for NMSLIB any more (once develop merges into master):
https://github.com/microsoft/vcpkg/blob/256d8a497a77f000168fe5a5b7c90a1962fa76ff/ports/nmslib/fix-headers.patch
NancyLi1013 commentedon Dec 1, 2020
Hi @searchivarius
Thanks for your kindly reminder. Of course, we can remove this patch in next release if these changes merged to.