Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

OpenMP in Visual Studio 2005 Standard

I have used OpenMP with gcc for writing parallel code. I am now using Visual C++ 2005 and am trying to figure out how to use OpenMP. There is a compiler option in the Properties->C/C++/Language menu but then it complains the library is missing. Is there a 3rd party implementation for OpenMP or am i just configuring Visual C++ incorrectly?

like image 681
DHamrick Avatar asked Dec 09 '22 20:12

DHamrick


1 Answers

After some research I found out that the OpenMP libs and dlls are not included with Visual C++ 2005 or Visual C++ Express Edition 2008. But with a few workarounds you can get it working.

First you need to download the lib files from microsoft which can be found at the Windows SDK for Windows Server 2008 and .NET framework 3.5. After you download it you need to make sure that either vcomp.lib or vcompd.lib is being linked to your program.

Next you need to have the dll which can be found in the Visual C++ Redistributable Packkage. Then make sure that vcomp90.dll is somewhere in your path.

You also need to have the OpenMP compiler option enabled which can be found in the Properties->C/C++/Language menu of Visual C++.

After that you should be able to use OpenMP just fine.

like image 143
DHamrick Avatar answered Dec 16 '22 09:12

DHamrick