Skip to content

Commit

Permalink
Added documentation for openmp parameter.
Browse files Browse the repository at this point in the history
  • Loading branch information
hiker committed Nov 8, 2024
1 parent df5f63a commit 788e75a
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 3 deletions.
12 changes: 12 additions & 0 deletions Documentation/source/site-specific-config.rst
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,18 @@ rsync, ar, ...).
tool_box = ToolBox()
default_c_compiler = tool_box.get_tool(Category.C_COMPILER)
There is special handling for compilers and linkers: the build
configuration stores the information if an MPI and/or OpenMP build
is requested. So when a default tool is requested by the ToolBox
from the ToolRepository (i.e. when the user has not added specific
compilers or linkers), this information is taken into account, and
only a compiler that will fulfil the requirements is returned. For
example, if you have `gfortran` and `mpif90-gfortran` defined in this
order in the ToolRepository, and request the default compiler for an
MPI build, the `mpif90-gfortran` instance is returned, not `gfortran`.
On the other hand, if no MPI is requested, an MPI-enabled compiler
might be returned, which does not affect the final result, since
an MPI compiler just adds include- and library-paths.

TODO
====
Expand Down
10 changes: 7 additions & 3 deletions source/fab/build_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,13 @@ def __init__(self, project_label: str,
created from this name, with spaces replaced by underscores.
:param tool_box: The ToolBox with all tools to use in the build.
:param mpi: whether the project uses MPI or not. This is used to
pick a default compiler (if not explicitly set in the ToolBox),
and controls PSyclone parameters.
:param openmp: whether the project should use OpenMP or not.
pick a default compiler (if none is explicitly set in the
ToolBox), and controls PSyclone parameters.
:param openmp: as with `mpi`, this controls whether the project is
using OpenMP or not. This is used to pick a default compiler
(if none is explicitly set in the ToolBox). The compiler-specific
flag to enable OpenMP will automatically be added when compiling
and linking.
:param multiprocessing:
An option to disable multiprocessing to aid debugging.
:param n_procs:
Expand Down

0 comments on commit 788e75a

Please sign in to comment.