build: switch allocator option to oneTBB tbbmalloc
(cherry picked from commit e29ca2dca9)
This commit is contained in:
@@ -10,6 +10,20 @@ filein = -I/usr/include/ -I${MKLROOT}/include
|
|||||||
## Added -lifcore for Intel Fortran runtime and -limf for Intel math library
|
## Added -lifcore for Intel Fortran runtime and -limf for Intel math library
|
||||||
LDLIBS = -L${MKLROOT}/lib -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lifcore -limf -lpthread -lm -ldl -liomp5
|
LDLIBS = -L${MKLROOT}/lib -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lifcore -limf -lpthread -lm -ldl -liomp5
|
||||||
|
|
||||||
|
## Memory allocator switch
|
||||||
|
## 1 (default) : link Intel oneTBB allocator (libtbbmalloc)
|
||||||
|
## 0 : use system default allocator (ptmalloc)
|
||||||
|
USE_TBBMALLOC ?= 1
|
||||||
|
TBBMALLOC_SO ?= /home/intel/oneapi/2025.3/lib/libtbbmalloc.so
|
||||||
|
ifneq ($(wildcard $(TBBMALLOC_SO)),)
|
||||||
|
TBBMALLOC_LIBS = -Wl,--no-as-needed $(TBBMALLOC_SO) -Wl,--as-needed
|
||||||
|
else
|
||||||
|
TBBMALLOC_LIBS = -Wl,--no-as-needed -ltbbmalloc -Wl,--as-needed
|
||||||
|
endif
|
||||||
|
ifeq ($(USE_TBBMALLOC),1)
|
||||||
|
LDLIBS := $(TBBMALLOC_LIBS) $(LDLIBS)
|
||||||
|
endif
|
||||||
|
|
||||||
## PGO build mode switch (ABE only; TwoPunctureABE always uses opt flags)
|
## PGO build mode switch (ABE only; TwoPunctureABE always uses opt flags)
|
||||||
## opt : (default) maximum performance with PGO profile-guided optimization
|
## opt : (default) maximum performance with PGO profile-guided optimization
|
||||||
## instrument : PGO Phase 1 instrumentation to collect fresh profile data
|
## instrument : PGO Phase 1 instrumentation to collect fresh profile data
|
||||||
|
|||||||
Reference in New Issue
Block a user