forked from DOI-USGS/volcano-ash3d-metreader
-
Notifications
You must be signed in to change notification settings - Fork 4
/
make_nvhpc.inc
34 lines (27 loc) · 1.46 KB
/
make_nvhpc.inc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
###############################################################################
########## Nvidia Fortran Compiler ##########################################
FCHOME = /opt/nvidia/hpc_sdk/Linux_x86_64/24.7/compilers
FC = $(FCHOME)/bin/nvfortran
COMPINC = -I./ -I$(FCHOME)/include
COMPLIBS = -L./ -L$(FCHOME)/lib
LIBS = $(COMPLIBS) $(COMPINC)
# Debugging flags
ifeq ($(RUN), DEBUG)
# consider including -lefence for debugging
FFLAGS = -O0 -g -Wall
#-Wextra -fimplicit-none -Wline-truncation -Wcharacter-truncation -Waliasing -Wimplicit-interface -Wunused-parameter -fwhole-file -fcheck=all -std=f2008 -pedantic -fbacktrace -Wunderflow -ffpe-trap=invalid,zero,overflow -Wuninitialized -Wmaybe-uninitialized -ffpe-summary=all -finit-integer=-2147483647 -finit-real=snan -fno-unsafe-math-optimizations -fsignaling-nans -frounding-math -Wno-surprising
endif
# Profiling flags
ifeq ($(RUN), PROF)
FFLAGS = -g -pg -w -fno-math-errno -funsafe-math-optimizations -fno-trapping-math -fno-signaling-nans -fcx-limited-range -fno-rounding-math
endif
# Production run flags
ifeq ($(RUN), OPT)
FFLAGS = -O4 -fast -Mipa=fast,inline
#FFLAGS = -O3 -w -fno-math-errno -funsafe-math-optimizations -fno-trapping-math -fno-signaling-nans -fcx-limited-range -fno-rounding-math -ftree-vectorize -funroll-loops -finline-functions
endif
# Preprocessing flags
FPPFLAGS = -x f95-cpp-input
# Extra flags
EXFLAGS =
###############################################################################