mirror of
https://github.com/paboyle/Grid.git
synced 2024-11-10 07:55:35 +00:00
commit
c61ea72949
@ -34,8 +34,6 @@ NAMESPACE_BEGIN(Grid);
|
||||
|
||||
// Move control to configure.ac and Config.h?
|
||||
|
||||
#define ALLOCATION_CACHE
|
||||
#define GRID_ALLOC_ALIGN (2*1024*1024)
|
||||
#define GRID_ALLOC_SMALL_LIMIT (4096)
|
||||
|
||||
/*Pinning pages is costly*/
|
||||
|
@ -361,7 +361,7 @@ inline void acceleratorMemSet(void *base,int value,size_t bytes) { hipMemset(bas
|
||||
//////////////////////////////////////////////
|
||||
// CPU Target - No accelerator just thread instead
|
||||
//////////////////////////////////////////////
|
||||
#define GRID_ALLOC_ALIGN (2*1024*1024) // 2MB aligned
|
||||
|
||||
#if ( (!defined(GRID_SYCL)) && (!defined(GRID_CUDA)) && (!defined(GRID_HIP)) )
|
||||
|
||||
#undef GRID_SIMT
|
||||
|
22
configure.ac
22
configure.ac
@ -491,6 +491,28 @@ AM_CFLAGS="$SIMD_FLAGS $AM_CFLAGS"
|
||||
###### PRECISION ALWAYS DOUBLE
|
||||
AC_DEFINE([GRID_DEFAULT_PRECISION_DOUBLE],[1],[GRID_DEFAULT_PRECISION is DOUBLE] )
|
||||
|
||||
#########################################################
|
||||
###################### GRID ALLOCATOR ALIGNMENT ##
|
||||
#########################################################
|
||||
AC_ARG_ENABLE([alloc-align],[AC_HELP_STRING([--enable-alloc-align=2MB|4k],
|
||||
[Alignment in bytes of GRID Allocator ])],[ac_ALLOC_ALIGN=${enable_alloc_align}],[ac_ALLOC_ALIGN=2MB])
|
||||
case ${ac_ALLOC_ALIGN} in
|
||||
4k)
|
||||
AC_DEFINE([GRID_ALLOC_ALIGN],[(4096)],[GRID_ALLOC_ALIGN]);;
|
||||
2MB)
|
||||
AC_DEFINE([GRID_ALLOC_ALIGN],[(2*1024*1024)],[GRID_ALLOC_ALIGN]);;
|
||||
*);;
|
||||
esac
|
||||
|
||||
AC_ARG_ENABLE([alloc-cache],[AC_HELP_STRING([--enable-alloc-cache ],
|
||||
[Cache a pool of recent "frees" to reuse])],[ac_ALLOC_CACHE=${enable_alloc_cache}],[ac_ALLOC_CACHE=yes])
|
||||
case ${ac_ALLOC_CACHE} in
|
||||
yes)
|
||||
AC_DEFINE([ALLOCATION_CACHE],[1],[ALLOCATION_CACHE]);;
|
||||
*);;
|
||||
esac
|
||||
|
||||
|
||||
#########################################################
|
||||
###################### set GPU device to rank in node ##
|
||||
#########################################################
|
||||
|
Loading…
Reference in New Issue
Block a user