routines for using GPU devices
More...
#include <stddef.h>
#include "core/ppm_visibility.h"
Go to the source code of this file.
◆ XT_GPU_INSTR_POP
◆ XT_GPU_INSTR_PUSH
#define XT_GPU_INSTR_PUSH |
( |
| arg | ) |
|
◆ xt_memtype
Enumerator |
---|
XT_MEMTYPE_HOST | |
XT_MEMTYPE_DEVICE | |
XT_MEMTYPE_COUNT | |
Definition at line 68 of file xt_gpu.h.
◆ xt_gpu_free()
frees memory that was previously allocated using xt_gpu_malloc
- Parameters
-
[in] | ptr | pointer to be freed |
[in] | memtype | type memory associated to ptr |
Definition at line 187 of file xt_gpu.c.
◆ xt_gpu_get_memtype()
enum xt_memtype xt_gpu_get_memtype |
( |
const void * | ptr | ) |
|
determines the type of memory associated with the provided pointer
- Parameters
-
[in] | ptr | pointer to be checked |
- Returns
- type of memory associated to ptr
Definition at line 197 of file xt_gpu.c.
◆ xt_gpu_init()
initialises xt_gpu
Definition at line 126 of file xt_gpu.c.
◆ xt_gpu_instr_pop()
◆ xt_gpu_instr_push()
◆ xt_gpu_malloc()
allocates memory of the specified type
- Parameters
-
[in] | alloc_size | number of bytes to be allocated |
[in] | memtype | type of memory to be allocated |
- Returns
- allocated memory of specified size and memory type
NULL, if allocation failed
Definition at line 183 of file xt_gpu.c.
◆ xt_gpu_memcpy()
copies memory from src to dst
- Parameters
-
[in] | dst | pointer to destination memory |
[in] | src | pointer to source memory |
[in] | buffer_size | number of bytes to be copied |
[in] | dst_memtype | type of destination memory |
[in] | src_memtype | type of source memory |
Definition at line 191 of file xt_gpu.c.