Skip to content

Commit

Permalink
Add Frontier to GNU Make (AMReX-Codes#2879)
Browse files Browse the repository at this point in the history
  • Loading branch information
WeiqunZhang committed Jul 20, 2022
1 parent b673d81 commit 8e40952
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
5 changes: 5 additions & 0 deletions Tools/GNUMake/Make.machines
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,11 @@ ifdef OLCF_ROCM_ROOT
which_site := olcf
which_computer := crusher
endif

ifeq ($(findstring frontier, $(host_name)), frontier)
which_site := olcf
which_computer := frontier
endif
endif

ifeq ($(findstring theta, $(host_name)), theta)
Expand Down
22 changes: 21 additions & 1 deletion Tools/GNUMake/sites/Make.olcf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# For Summit et al. at OLCF
#

OLCF_MACHINES := summit ascent spock crusher
OLCF_MACHINES := summit ascent spock crusher frontier

ifneq ($(which_computer), $(findstring $(which_computer), $(OLCF_MACHINES)))
$(error Unknown OLCF computer, $(which_computer))
Expand Down Expand Up @@ -84,3 +84,23 @@ ifeq ($(which_computer),crusher)
endif
endif
endif

ifeq ($(which_computer),frontier)
ifeq ($(USE_HIP),TRUE)
# MI250X
AMD_ARCH=gfx90a
endif

ifeq ($(USE_MPI),TRUE)
includes += $(shell CC --cray-print-opts=cflags)
ifneq ($(BL_NO_FORT),TRUE)
LIBRARIES += $(shell ftn --cray-print-opts=libs)
else
LIBRARIES += $(shell CC --cray-print-opts=libs)
endif
# for gpu aware mpi
ifeq ($(USE_HIP),TRUE)
LIBRARIES += $(PE_MPICH_GTL_DIR_amd_gfx90a) -lmpi_gtl_hsa
endif
endif
endif

0 comments on commit 8e40952

Please sign in to comment.