Neko  0.9.99
A portable framework for high-order spectral element flow simulations
gs.hip File Reference
#include <hip/hip_runtime.h>
#include <climits>
#include <cstdio>
#include <device/device_config.h>
#include <device/hip/check.h>
#include "gs_kernels.h"
Include dependency graph for gs.hip:

Go to the source code of this file.

Macros

#define GS_OP_ADD   1
 
#define GS_OP_MUL   2
 
#define GS_OP_MIN   3
 
#define GS_OP_MAX   4
 

Functions

void hip_gather_kernel (void *v, int *m, int *o, void *dg, void *u, int *n, void *gd, int *nb, void *b, void *bo, int *op, hipStream_t stream)
 
void hip_scatter_kernel (void *v, int *m, void *dg, void *u, int *n, void *gd, int *nb, void *b, void *bo, hipStream_t stream)
 
void hip_gs_pack (void *u_d, void *buf_d, void *dof_d, int offset, int n, hipStream_t stream)
 
void hip_gs_unpack (real *u_d, int op, real *buf_d, int *dof_d, int offset, int n, hipStream_t stream)
 

Macro Definition Documentation

◆ GS_OP_ADD

#define GS_OP_ADD   1

Definition at line 42 of file gs.hip.

◆ GS_OP_MAX

#define GS_OP_MAX   4

Definition at line 45 of file gs.hip.

◆ GS_OP_MIN

#define GS_OP_MIN   3

Definition at line 44 of file gs.hip.

◆ GS_OP_MUL

#define GS_OP_MUL   2

Definition at line 43 of file gs.hip.

Function Documentation

◆ hip_gather_kernel()

void hip_gather_kernel ( void *  v,
int *  m,
int *  o,
void *  dg,
void *  u,
int *  n,
void *  gd,
int *  nb,
void *  b,
void *  bo,
int *  op,
hipStream_t  stream 
)

Fortran wrapper for device gather kernels

Definition at line 52 of file gs.hip.

◆ hip_gs_pack()

void hip_gs_pack ( void *  u_d,
void *  buf_d,
void *  dof_d,
int  offset,
int  n,
hipStream_t  stream 
)

Pack send buffer on device

Definition at line 122 of file gs.hip.

◆ hip_gs_unpack()

void hip_gs_unpack ( real u_d,
int  op,
real buf_d,
int *  dof_d,
int  offset,
int  n,
hipStream_t  stream 
)

Unpack receive buffer on device

Definition at line 146 of file gs.hip.

◆ hip_scatter_kernel()

void hip_scatter_kernel ( void *  v,
int *  m,
void *  dg,
void *  u,
int *  n,
void *  gd,
int *  nb,
void *  b,
void *  bo,
hipStream_t  stream 
)

Fortran wrapper for device scatter kernel

Definition at line 101 of file gs.hip.