Skip to content

Commit

Permalink
Improved support for ifx compiler. (#93)
Browse files Browse the repository at this point in the history
  • Loading branch information
p-costa authored Oct 29, 2023
1 parent eb4f0ba commit d62268a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 12 deletions.
3 changes: 3 additions & 0 deletions configs/compilers.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ endif
ifeq ($(strip $(FCOMP)),INTEL)
FC = mpiifort
endif
ifeq ($(strip $(FCOMP)),INTEL_IFX)
FC = mpiifx
endif
ifeq ($(strip $(FCOMP)),NVIDIA)
FC = mpifort
endif
Expand Down
18 changes: 6 additions & 12 deletions configs/flags.mk
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ifeq ($(strip $(FCOMP)),GNU)
FFLAGS_MOD_DIR := -J
endif
ifeq ($(strip $(FCOMP)),INTEL)
ifeq ($(findstring INTEL,$(strip $(FCOMP))),INTEL)
FFLAGS_MOD_DIR := -module
endif
ifeq ($(strip $(FCOMP)),NVIDIA)
Expand All @@ -19,7 +19,7 @@ ifeq ($(strip $(FFLAGS_DEBUG)),1)
ifeq ($(strip $(FCOMP)),GNU)
override FFLAGS += -O0 -g -fbacktrace -Wall -Wextra -pedantic -fcheck=all -finit-real=snan -ffpe-trap=invalid -std=f2018
endif
ifeq ($(strip $(FCOMP)),INTEL)
ifeq ($(findstring INTEL,$(strip $(FCOMP))),INTEL)
override FFLAGS += -O0 -g -traceback -fpe0 -stand f18
endif
ifeq ($(strip $(FCOMP)),NVIDIA)
Expand All @@ -36,7 +36,7 @@ ifeq ($(strip $(FFLAGS_DEBUG_MAX)),1)
ifeq ($(strip $(FCOMP)),GNU)
override FFLAGS += -O0 -g -fbacktrace -Wall -Wextra -Wimplicit-interface -Wno-unused-function -fPIC -fcheck=all -ffpe-trap=invalid,zero,overflow -finit-real=snan -finit-integer=-99999999 -std=f2018
endif
ifeq ($(strip $(FCOMP)),INTEL)
ifeq ($(findstring INTEL,$(strip $(FCOMP))),INTEL)
override FFLAGS += -O0 -warn all -g -traceback -fpe0 -stand f18
endif
ifeq ($(strip $(FCOMP)),NVIDIA)
Expand All @@ -53,7 +53,7 @@ ifeq ($(strip $(FFLAGS_OPT)),1)
ifeq ($(strip $(FCOMP)),GNU)
override FFLAGS += -O3
endif
ifeq ($(strip $(FCOMP)),INTEL)
ifeq ($(findstring INTEL,$(strip $(FCOMP))),INTEL)
override FFLAGS += -O3
endif
ifeq ($(strip $(FCOMP)),NVIDIA)
Expand All @@ -70,7 +70,7 @@ ifeq ($(strip $(FFLAGS_OPT_MAX)),1)
ifeq ($(strip $(FCOMP)),GNU)
override FFLAGS += -Ofast -march=native
endif
ifeq ($(strip $(FCOMP)),INTEL)
ifeq ($(findstring INTEL,$(strip $(FCOMP))),INTEL)
override FFLAGS += -fast -xHost
endif
ifeq ($(strip $(FCOMP)),NVIDIA)
Expand Down Expand Up @@ -133,7 +133,7 @@ endif
ifeq ($(strip $(OPENMP)),1)
ifeq ($(strip $(FCOMP)),GNU)
override FFLAGS += -fopenmp
else ifeq ($(strip $(FCOMP)),INTEL)
else ifeq ($(findstring INTEL,$(strip $(FCOMP))),INTEL)
override FFLAGS += -qopenmp
else ifeq ($(strip $(FCOMP)),NVIDIA)
override FFLAGS += -mp
Expand All @@ -143,9 +143,3 @@ else
override FFLAGS += -fopenmp
endif
endif

ifeq ($(strip $(FCOMP)),INTEL)
ifeq ($(strip $(INTEL_IFX)),1)
override FFLAGS += -fc=ifx
endif
endif

0 comments on commit d62268a

Please sign in to comment.