link library of pthread

link library of pthread

Hello,

For some reasons I have to link explicitly the pthread libraries during the compilation (make). This is ok when I produced the CPU version. I'm trying to do the same thing with -mmic to enable the Intel Xeon Phi Coprocessor. However, I've got the following errors:

x86_64-k1om-linux-ld: skipping incompatible /lib64/libpthread.so.0 when searching for /lib64/libpthread.so.0
x86_64-k1om-linux-ld: cannot find /lib64/libpthread.so.0
x86_64-k1om-linux-ld: skipping incompatible /usr/lib64/libpthread_nonshared.a when searching for /usr/lib64/libpthread_nonshared.a
x86_64-k1om-linux-ld: cannot find /usr/lib64/libpthread_nonshared.a

I tried to find some MIC-specific pthread libraries in /opt/intel without having any good results. 

Anyone any idea about which one of pthread library used by MIC?

Thanks a lot for the comments. 

5 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

>>...Anyone any idea about which one of pthread library used by MIC?

I think you need to contact owners of pthread library. Also, it is not clear what C++ compiler do you use.

Presumably, for -mmic linking libpthread (e.g. when icc -parallel or -openmp are set) it would search /opt/intel/mic/filesystem/base/lib64/ (in a default installation).

If you source the environment script, e.g. source /opt/intel/composer_xe_2013/bin/compilervars.sh intel64, then compile with 

icc -mmic -lpthread pthread.c

It should work fine. I can't reproduce any problem. What does your compile line look like?

If it's easier for you to link directly to the pthread library for Intel Xeon Phi coprocessors (versus using just -lpthread), depending on your MPSS version (in this case 2.1.6720-13), you will find the pthread library here: /usr/linux-k1om-4.7/linux-k1om/lib64

Leave a Comment

Please sign in to add a comment. Not a member? Join today