#187: Cannot disable optimisation with Intel compiler using OPTIMISE=no -------------------------+-------------------------------------------------- Reporter: hinder | Owner: Type: enhancement | Status: new Priority: minor | Milestone: Component: Cactus | Version: Keywords: | -------------------------+-------------------------------------------------- Cactus supports a variable OPTIMISE=yes/no to control whether optimisation is performed during compilation. Setting this variable to "yes" (for example, make sim-config OPTIMISE=yes) adds the flags in C_OPTIMISE_FLAGS to CFLAGS so that optimisation is performed. This is the default. Setting OPTIMISE=no does not add the flags. For gcc, this results in an unoptimised configuration as gcc assumes -O0 as the default. The Intel compiler, however, uses -O2 as the default. Hence, setting OPTIMISE=no has no effect on Intel, and -O2 is still used.
The attached patch adds new configuration options C_NO_OPTIMISE_FLAGS, CXX_NO_OPTIMISE_FLAGS, F77_NO_OPTIMISE_FLAGS and F90_NO_OPTIMISE_FLAGS to complement the *_OPTIMISE_FLAGS options. These are added to the flags when OPTIMISE=no is used, and they default to -O0, which for the commonly used gcc and Intel compilers will lead to an unoptimised configuration. I have also included a patch to the documentation.
I have not included the automatically generated configure script; to avoid confusion the committer should probably generate this.
#187: Cannot disable optimisation with Intel compiler using OPTIMISE=no --------------------------+------------------------------------------------- Reporter: hinder | Owner: knarf Type: enhancement | Status: accepted Priority: minor | Milestone: Component: Cactus | Version: Resolution: | Keywords: --------------------------+------------------------------------------------- Changes (by knarf):
* owner: => knarf * status: new => accepted
Comment:
Patch looks good. I still need to test it.
#187: Cannot disable optimisation with Intel compiler using OPTIMISE=no --------------------------+------------------------------------------------- Reporter: hinder | Owner: knarf Type: enhancement | Status: closed Priority: minor | Milestone: Component: Cactus | Version: Resolution: fixed | Keywords: --------------------------+------------------------------------------------- Changes (by knarf):
* status: accepted => closed * resolution: => fixed
trac@lists.einsteintoolkit.org