Hi everyone,my project was built under microsoft visual studio 2005 (C++). Iused intel c++ compiler to accelerate my program, and the speed boost is about 30% percent. Recently I realized that the computation in my program could be divided into two independent parts, so I put them into two independent threads. After the main thread gets the signal that the two computation threads finished their jobs, it will proceed the final calculation and then the program will exit. Iran my program under windowsXP in a dual-core intel CPU. When the program was run as an execution file, another 50% speed boost was achieved as expected, and the peak CPU cost is about 80%. However when I change the program into a dynamic link library (DLL), and called it from another execution file, the speed was changed back tothelevel of initial single thread program (but after intel c++ optimziation).
Then I changed the project compiler back to visual c++, and compiled the DLL again. I found that the speed was boosted by a ratio of 2. So I am curious that is there any problem with the configuration of intel c++ compilerfor multithreading DLL or there is some tricks about the intel c++ compiler in this situation?
Any help will be highly appreciated!