summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Kroeker <martin@ruby.chemie.uni-freiburg.de>2021-09-04 18:26:59 +0200
committerGitHub <noreply@github.com>2021-09-04 18:26:59 +0200
commitaf19cda65aef4d033ae33213013c88b0a99f9da2 (patch)
treea233527101cda920e1e0ff956615d5dc603610fd
parenta3e80069fb10c830e4de6746e2c9bd27cd4603a9 (diff)
downloadopenblas-af19cda65aef4d033ae33213013c88b0a99f9da2.tar.gz
openblas-af19cda65aef4d033ae33213013c88b0a99f9da2.tar.bz2
openblas-af19cda65aef4d033ae33213013c88b0a99f9da2.zip
Add "recursive" option for IBM xlf compiler (#3359)
* Add correct "recursive" option for xlf (from reference-lapack issue 606)
-rw-r--r--Makefile.power12
-rw-r--r--cmake/fc.cmake2
2 files changed, 13 insertions, 1 deletions
diff --git a/Makefile.power b/Makefile.power
index 946f55232..4e7478213 100644
--- a/Makefile.power
+++ b/Makefile.power
@@ -12,9 +12,13 @@ endif
ifeq ($(CORE), POWER10)
ifneq ($(C_COMPILER), PGI)
CCOMMON_OPT += -Ofast -mcpu=power10 -mtune=power10 -mvsx -fno-fast-math
+ifeq ($(F_COMPILER, IBM)
+FCOMMON_OPT += -O2 -qrecur -qnosave
+else
FCOMMON_OPT += -O2 -frecursive -mcpu=power10 -mtune=power10 -fno-fast-math
endif
endif
+endif
ifeq ($(CORE), POWER9)
ifneq ($(C_COMPILER), PGI)
@@ -33,7 +37,11 @@ else
CCOMMON_OPT += -fast -Mvect=simd -Mcache_align
endif
ifneq ($(F_COMPILER), PGI)
+ifeq ($(F_COMPILER), IBM)
+FCOMMON_OPT += -O2 -qrecur -qnosave
+else
FCOMMON_OPT += -O2 -frecursive -fno-fast-math
+endif
ifeq ($(C_COMPILER), GCC)
ifneq ($(GCCVERSIONGT4), 1)
$(warning your compiler is too old to fully support POWER9, getting a newer version of gcc is recommended)
@@ -57,7 +65,11 @@ CCOMMON_OPT += -fast -Mvect=simd -Mcache_align
endif
ifneq ($(F_COMPILER), PGI)
ifeq ($(OSNAME), AIX)
+ifeq ($(F_COMPILER), IBM)
+FCOMMON_OPT += -O2 -qrecur -qnosave
+else
FCOMMON_OPT += -O1 -frecursive -mcpu=power8 -mtune=power8 -fno-fast-math
+endif
else
FCOMMON_OPT += -O2 -frecursive -mcpu=power8 -mtune=power8 -fno-fast-math
endif
diff --git a/cmake/fc.cmake b/cmake/fc.cmake
index 631664569..f7aa4c5c9 100644
--- a/cmake/fc.cmake
+++ b/cmake/fc.cmake
@@ -104,7 +104,7 @@ endif ()
if (${F_COMPILER} STREQUAL "IBM")
set(CCOMMON_OPT "${CCOMMON_OPT} -DF_INTERFACE_IBM")
- # FCOMMON_OPT += -qarch=440
+ set(FCOMMON_OPT "${FCOMMON_OPT} -qrecur")
if (BINARY64)
set(FCOMMON_OPT "${FCOMMON_OPT} -q64")
if (INTERFACE64)