Skip to content

Commit

Permalink
GNU Make: Remove old machines like summit and cori
Browse files Browse the repository at this point in the history
  • Loading branch information
WeiqunZhang committed Jan 27, 2025
1 parent 4b34f9c commit 83fb61b
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 157 deletions.
25 changes: 0 additions & 25 deletions Tools/GNUMake/Make.machines
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,6 @@ host_name_short := $(shell hostname -s)
# MACHINES supported

ifdef NERSC_HOST
ifeq ($(findstring cgpu, $(host_name)), cgpu)
which_site := nersc
which_computer := cgpu
else
ifeq ($(NERSC_HOST), cori)
which_site := nersc
which_computer := cori
else
ifeq ($(NERSC_HOST), perlmutter)
which_site := nersc
which_computer := perlmutter
Expand All @@ -45,24 +37,7 @@ endif
endif
endif

ifdef OLCF_MODULEPATH_ROOT
ifeq ($(findstring summit, $(host_name)), summit)
which_site := olcf
which_computer := summit
endif

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

ifeq ($(LMOD_SITE_NAME),OLCF)
ifeq ($(findstring spock, $(host_name)), spock)
which_site := olcf
which_computer := spock
endif

ifeq ($(findstring crusher, $(host_name)), crusher)
which_site := olcf
which_computer := crusher
Expand Down
80 changes: 1 addition & 79 deletions Tools/GNUMake/sites/Make.nersc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# For NERSC machines: Cori and corigpu
#

NERSC_MACHINES := cori cgpu perlmutter
NERSC_MACHINES := perlmutter

ifneq ($(which_computer),$(filter $(which_computer), ${NERSC_MACHINES}))
$(error Unknown NERSC computer, $(which_computer))
Expand Down Expand Up @@ -119,81 +119,3 @@ ifeq ($(which_computer),$(filter $(which_computer),perlmutter))
endif

endif

ifeq ($(which_computer),$(filter $(which_computer),cori))

ifdef PE_ENV
ifneq ($(USE_CUDA),TRUE)
lowercase_peenv := $(shell echo $(PE_ENV) | tr A-Z a-z)
ifneq ($(lowercase_peenv),$(lowercase_comp))
has_compiler_mismatch = COMP=$(COMP) does not match PrgEnv-$(lowercase_peenv)
endif
endif
endif

ifeq ($(USE_MPI),TRUE)
ifeq ($(USE_CUDA),TRUE)
$(error USE_CUDA is not allowed on the cori login nodes, please build from a cgpu node))
else
CC = cc
CXX = CC
FC = ftn
F90 = ftn
LIBRARIES += -lmpichf90
endif
endif

ifeq ($(USE_SENSEI_INSITU),TRUE)
CXXFLAGS += -fPIC -dynamic
LIBRARIES += -ldl
endif

endif

ifeq ($(which_computer),$(filter $(which_computer),cgpu))

ifeq ($(USE_MPI),TRUE)

CC = mpicc
CXX = mpic++
FC = mpif90
F90 = mpif90

ifneq ($(LINK_WITH_FORTRAN_COMPILER),TRUE)
ifneq ($(findstring mvapich,$(shell mpif90 -show 2>&1 | tr A-Z a-z)),)
cori_mvapich_link_flags := $(shell mpif90 -link_info)
LIBRARIES += --compiler-options '-fPIC' $(wordlist 2,1024,$(filter-out -m64,$(filter-out -fPIC,$(cori_mvapich_link_flags))))
else ifneq ($(findstring Open MPI, $(shell mpif90 -showme:version 2>&1)),)
cori_openmpi_link_flags := $(shell mpif90 -showme:link)
LIBRARIES += $(cori_openmpi_link_flags)
endif
endif

endif

ifeq ($(USE_CUDA),TRUE)

FIX_NVCC_PTHREAD=TRUE

ifneq ($(CUDA_ROOT),)
SYSTEM_CUDA_PATH := $(CUDA_ROOT)
COMPILE_CUDA_PATH := $(CUDA_ROOT)
else ifneq ($(CUDA_HOME),)
SYSTEM_CUDA_PATH := $(CUDA_HOME)
COMPILE_CUDA_PATH := $(CUDA_HOME)
endif

ifeq ($(findstring :dgx, $(LOADEDMODULES)), :dgx)
CUDA_ARCH = 80
else
CUDA_ARCH = 70
endif

endif

ifeq ($(USE_SENSEI_INSITU),TRUE)
CXXFLAGS += -fPIC -dynamic
LIBRARIES += -ldl
endif

endif
54 changes: 1 addition & 53 deletions Tools/GNUMake/sites/Make.olcf
Original file line number Diff line number Diff line change
Expand Up @@ -2,64 +2,12 @@
# For Summit et al. at OLCF
#

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

ifneq ($(which_computer), $(findstring $(which_computer), $(OLCF_MACHINES)))
$(error Unknown OLCF computer, $(which_computer))
endif

ifeq ($(which_computer),$(filter $(which_computer),summit ascent))

ifeq ($(USE_MPI),TRUE)

CC := mpicc
CXX := mpicxx
FC := mpif90
F90 := mpif90

LIBRARIES += -lmpi_ibm_mpifh -lmpi_ibm

endif

ifeq ($(lowercase_comp),gnu)
override XTRALIBS := -lgfortran
endif

ifeq ($(lowercase_comp),ibm)
override XTRALIBS += -L$(OLCF_XLF_ROOT)/lib -L$(OLCF_XLC_ROOT)/lib
endif

SYSTEM_CUDA_PATH=$(OLCF_CUDA_ROOT)

SYSTEM_NVML_PATH=$(OLCF_CUDA_ROOT)/lib64/stubs

# Specify that we want to build for Volta

CUDA_ARCH = 70
COMPILE_CUDA_PATH = $(OLCF_CUDA_ROOT)

endif

ifeq ($(which_computer),spock)
ifeq ($(USE_HIP),TRUE)
# MI100
AMD_ARCH=gfx908
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_gfx908) -lmpi_gtl_hsa
endif
endif
endif

ifeq ($(which_computer),crusher)
ifeq ($(USE_HIP),TRUE)
# MI250X
Expand Down

0 comments on commit 83fb61b

Please sign in to comment.