Getting started with openMP. install on windows

后端 未结 3 1565
无人共我
无人共我 2021-02-02 11:21

I want to write parallel program in C++ using OpenMP, so I am getting started with OpenMP. On the other words I am a beginner and I need good OpenMP guide telling how to install

3条回答
  •  伪装坚强ぢ
    2021-02-02 12:16

    So here is what I did to finally get OpenMP working on my Windows 10 PC:

    1. Get MinGW - Download and grab what you need to get the basic gcc compiler and the g++ pakage (its really easy to do). You can always run g++ -v to make sure it is up and running
    2. Run mingw-get upgrade --recursive "gcc<4.7.*" "gcc-g++<4.7.*" This is the "Fun" part. Because at this time there was no libgomp library supported in their 4.9.* version my gcc wasn't able to recognize the last support version was 4.7.2 so with this I finally was able to run my openMP

    To compile run g++ -fopenmp myOpenMPFile.cpp -o myOpenMP and it will all work from there

    gcc -fopenmp myOpenMPFile.cpp -o myOpenMP will also work for C code

提交回复
热议问题