By Ruud on Apr 02, 2009
It is with great pleasure that I announce availability of 41 OpenMP example programs. All these examples are introduced and discussed in the book "Using OpenMP".
The sources are available as a free download under the BSD license. Each source comes with a copy of the license. Please do not remove this.
The zip file that contains everything needed (sources, example make files for various compilers, and a brief user's guide) can be downloaded here.
Although tempting at times to deviate, the core part of each example has not been changed compared to what is shown in the book.
You are encouraged to try out these examples and perhaps use them as a starting point to better understand and possibly further explore OpenMP.
Simplicity was an important goal for this project. For example. each source file constitutes a full working program. Other than a compiler and run time environment that support OpenMP, nothing else is needed to compile and run the program(s).
With the exception of one example, there are no source code comments. Not only are these examples very straightforward, they are also discussed in the above mentioned book.
As a courtesy, each source directory has a straightforward make file called "Makefile". This file can be used to build and run the examples in the specific directory. Before doing so, you need to activate the appropriate include line in file Makefile. There are include files for several compilers on Unix based Operating Systems (Linux, Solaris and Mac OS to be precise). These files have been put together on a best effort basis.
The User's Guide that is bundled with the examples explains the compiler specific include file for "make" in more detail.