|
ROCK
1.11.5
Relativistic Oscillator Calculation Kit
|
Read the detailed description! More...
#include <crock.h>
Data Fields | |
| void(* | free )(struct cr_cache *self) |
Read the detailed description!
To avoid re-allocate NUMA or GPU memory in every iteration, the memory buffers are stored in cache structures. The typical signature of a function making use of caches is
The user defines a pointer to the structure, and invoke the func() with
Notes:
func(..., NULL) i.e. pp_cache == NULL then no cache is assumed (e.g. for a diagnostic step with fewer electrons).ptr_cache == NULL then a new cache will be allocated.dim_* and the same parallelization setup (e.g. number of threads), as they are determining the size of memory.func_1(..., ptr_cache_1) and func_2(..., ptr_cache_2). Accelerated functions have *_gpu() (using device pointers) and *_offload() (using host pointers) variants, Mixing caches between them is also not supported. | void(* cr_cache::free) (struct cr_cache *self) |