1 /* ========================================================================== */
2 /* === Include/cholmod_gpu_kernels.h ======================================== */
3 /* ========================================================================== */
4 
5 /* -----------------------------------------------------------------------------
6  * CHOLMOD/Include/cholmod_gpu_kernels.h.
7  * Copyright (C) 2014, Timothy A. Davis
8  * http://www.suitesparse.com
9  * -------------------------------------------------------------------------- */
10 
11 /* -----------------------------------------------------------------------------
12  * CUDA kernel support routines for CHOLMOD
13  * -------------------------------------------------------------------------- */
14 
15 #ifndef CHOLMODGPUKERNELS_H
16 #define CHOLMODGPUKERNELS_H
17 
18 /* make it easy for C++ programs to include CHOLMOD */
19 #ifdef __cplusplus
20 extern "C" {
21 #endif
22 
23 #include "SuiteSparse_config.h"
24 
25 int createMapOnDevice ( Int *d_Map, Int *d_Ls, Int psi, Int nsrow );
26 
27 int createRelativeMapOnDevice ( Int *d_Map, Int *d_Ls, Int *d_RelativeMap,
28                            Int pdi1, Int ndrow, cudaStream_t astream );
29 
30 int addUpateOnDevice ( double *d_A, double *devPtrC, Int *d_RelativeMap,
31     Int ndrow1, Int ndrow2, Int nsrow, cudaStream_t astream );
32 
33 int addComplexUpateOnDevice ( double *d_A, double *devPtrC, Int *d_RelativeMap,
34     Int ndrow1, Int ndrow2, Int nsrow, cudaStream_t astream );
35 
36 int sumAOnDevice ( double *a1, double *a2, const double alpha, int nsrow,
37     int nscol );
38 
39 int sumComplexAOnDevice ( double *a1, double *a2, const double alpha,
40     int nsrow, int nscol );
41 
42 #ifdef __cplusplus
43 }
44 #endif
45 
46 #endif
47