Eclipse 3.5 CDT 6.0 IPP 6.1 and Static Lining, Multi-threading, etc. under Linux
Something seems to be serious messed up with the IPP setup for Eclipse. What I'm using:
Eclipse 3.5 Build ID 20100218-1602 with CDT 6 Intel Linux Compiler em64t v11.1-072 SuSe 11.3 64-bit up to date Core2 Quad cpu
Everything seems setup properly with the setup scripts for the Intel compiler and IPP running on login. My app builds properly using using dynamic linking (C/C++ Build->Settings->Link with Dynamic Libraries checked), but multi-threading won't start. Heres the code:
make -k all Building target: MXLib.exe Invoking: Intel Intel 64 C++ Linker icpc -shared-intel -parallel -ipp=common -mkl=parallel -lpthread -o"MXLib.exe" ./src/MXLib.o Finished building target: MXLib.exe
And what I get out:
Ipp init: ippStsNoErr: No error, it's OK Number of cores = 4 Set Num Threads: ippStsNoOperation: No operation has been executed Number of threads = 1
So, obviously multi-threading is not working. I tried using the static threaded libraries but they defy all effort to link through eclipse. No combination of options anywhere will make the linker inside eclipse have anything to do with it. Just checking the use static libraries box brings up:
make -k all Building target: MXLib.exe Invoking: Intel Intel 64 C++ Linker icpc -static -parallel -ipp=common -mkl=parallel -lpthread -o"MXLib.exe" ./src/MXLib.o ld: cannot find -lippvmem64t make: *** [MXLib.exe] Error 1 make: Target `all' not remade because of errors.
Problem is, 'ippvmem64t' doesn't exist. There are 'libippvmemerged64t.a' etc. in the IPP lib folder. Unchecking the use static libraries and adding the libraries manully doesn't work for some reason (Eclipse adding the -l before the library name?).
Anyway, something is definatley messed up, missing from the help docs or I've been drinking too much and it's effecting me during the day. :-)
P.S. I want to do this through the Eclipse interface since this library is for use by non-programmers who do not want to mess with makefiles.
There is a libippvmem64t.so (I'm using the 64-bit version) in /opt/intel/Compiler/11.1/072/ipp/ia32/sharedlib, but that's not what it's complaining about. It's looking for ippvmem64t (without the 'lib' at the begininng). Like I said, dynamic linking works although it doesn't seem to multithread. I think maybe IPP and CDT are out of sync and things are not being set up properly.
Hate to reply to my own post, but I just ran a quick test looping ippsDiv_32f_I() (a multi-threaded IPP function) 10,000 times on 1,000,000 element sized vectors and it is definately running single threaded.