Skip to content

Commit

Permalink
Update Nvidia GPU backend to working state
Browse files Browse the repository at this point in the history
  • Loading branch information
TomTheBear committed Nov 9, 2019
1 parent 2189749 commit 699ba6c
Show file tree
Hide file tree
Showing 21 changed files with 2,297 additions and 1,172 deletions.
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,8 @@ OBJ := $(filter-out $(BUILD_DIR)/loadDataARM.o,$(OBJ))
endif
ifneq ($(NVIDIA_INTERFACE), true)
OBJ := $(filter-out $(BUILD_DIR)/nvmon.o,$(OBJ))
OBJ := $(filter-out $(BUILD_DIR)/topology_gpu.o,$(OBJ))
OBJ := $(filter-out $(BUILD_DIR)/libnvctr.o,$(OBJ))
endif
PERFMONHEADERS = $(patsubst $(SRC_DIR)/includes/%.txt, $(BUILD_DIR)/%.h,$(wildcard $(SRC_DIR)/includes/*.txt))
OBJ_LUA = $(wildcard ./ext/lua/$(COMPILER)/*.o)
Expand Down
14 changes: 7 additions & 7 deletions config.mk
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
COMPILER = GCC#NO SPACE

# Path were to install likwid
PREFIX ?= /usr/local#NO SPACE
PREFIX ?= /apps/likwid/4.3.4#NO SPACE

# Set the default mode for MSR access.
# This can usually be overriden on the commandline.
Expand All @@ -26,6 +26,7 @@ FORTRAN_INTERFACE = false#NO SPACE
INSTRUMENT_BENCH = true#NO SPACE

# Build LIKWID with NVIDIA interface (CUDA, CUPTI)
# For configuring include paths, go to CUDA section
NVIDIA_INTERFACE = true#NO SPACE

#################################################################
Expand Down Expand Up @@ -85,7 +86,7 @@ INSTALL_CHOWN = -g root -o root#NO SPACE
SHARED_LIBRARY = true#NO SPACE

# Build LIKWID with debug flags
DEBUG = false#NO SPACE
DEBUG = true#NO SPACE

# Basic configuration for some internal arrays.
# Maximal number of hardware threads
Expand Down Expand Up @@ -140,12 +141,11 @@ LIKWIDFILTERPATH = $(abspath $(INSTALLED_PREFIX)/share/likwid/filter)
# $HOME/.likwid/groups
LIKWIDGROUPPATH = $(abspath $(INSTALLED_PREFIX)/share/likwid/perfgroups)

# CUDA info
# CUDA / CUPTI build data
# LIKWID requires CUDA and CUPTI to be present only for compilation with
# NVIDIA_INTERFACE=true. At runtime, the CUDA and the CUPTI library have
# to be in the LD_LIBRARY_PATH to dynamically load the libraries.
# Include directory for CUDA headers
CUDAINCLUDE = $(CUDA_HOME)/include
# Library directory for CUDA libs
CUDALIBDIR = $(CUDA_HOME)/lib64
# Include directory for CUPTI headers
CUPTIINCLUDE = $(CUDA_HOME)/extras/CUPTI/include
# Library directory for CUPTI libs
CUPTILIBDIR = $(CUDA_HOME)/extras/CUPTI/lib64
4 changes: 2 additions & 2 deletions make/config_checks.mk
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ endif
endif

ifeq ($(strip $(NVIDIA_INTERFACE)), true)
LIBS+= -lcuda -ldl
#LIBS+= -lcuda -ldl
INCLUDES += -I$(CUDAINCLUDE) -I$(CUPTIINCLUDE)
CPPFLAGS += -L$(CUDALIBDIR) -L$(CUPTILIBDIR)
#CPPFLAGS += -L$(CUDALIBDIR) -L$(CUPTILIBDIR)
endif
Loading

0 comments on commit 699ba6c

Please sign in to comment.