It is a pain that each and every library has to downloaded and installed
and configured but it is a necessary evil in most cases. If we had each
and every tool in our computer then we would have no space and our
systems would be slow as there are other tools which we don't know
about. For those who are using:
The standard compiler for Windows comes from Microsoft Visual C/C++ compiler from Visual Studio. Unfortunately its OpenMP support is a bit outdated. To use it simply Start a project in Visual studio.
If you are using gcc as the compiler then you have done it already. All there is to do is create a c/c++ code and while compiling the program simply use the following statement
where c_code.cpp is the source code and c_obj is the object /exe file to run
- Windows
The standard compiler for Windows comes from Microsoft Visual C/C++ compiler from Visual Studio. Unfortunately its OpenMP support is a bit outdated. To use it simply Start a project in Visual studio.
- Start a new Project
- Select a Win 32 console project
- Set name and path
- Select an empty project in the next panel
- Drag and drop source file into solution explorer
- Goto Project properties -->configuration properties/C.C++/language
- Activate the openMP tab
- Linux
If you are using gcc as the compiler then you have done it already. All there is to do is create a c/c++ code and while compiling the program simply use the following statement
gcc -fopenmp c_code.cpp -o c_obj
No comments:
Post a Comment