clSPARSE  v0.10.0.0
a software library containing Sparse functions written in OpenCL
clSPARSE-1x.h
Go to the documentation of this file.
1 /* ************************************************************************
2  * Copyright 2015 Advanced Micro Devices, Inc.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  * ************************************************************************ */
16 
22 #pragma once
23 #ifndef _CL_SPARSE_1x_H_
24 #define _CL_SPARSE_1x_H_
25 
26 #include "clSPARSE-xx.h"
27 
28 
31 typedef struct clsparseScalar_
32 {
33  cl_mem value;
40 
43 typedef struct cldenseVector_
44 {
47  cl_mem values;
54 
60 typedef struct clsparseCsrMatrix_
61 {
71  cl_mem values;
72  cl_mem col_indices;
73  cl_mem row_pointer;
89  void* meta;
91 
97 typedef struct clsparseCooMatrix_
98 {
108  cl_mem values;
109  cl_mem col_indices;
110  cl_mem row_indices;
123 
127 typedef struct cldenseMatrix_
128 {
137  cl_mem values;
143 } cldenseMatrix;
144 
145 #endif
clsparseIdx_t off_row_pointer
Definition: clSPARSE-1x.h:83
clsparseIdx_t off_values
Definition: clSPARSE-1x.h:118
cl_mem values
Definition: clSPARSE-1x.h:108
clsparseIdx_t num_cols
Definition: clSPARSE-1x.h:102
clsparseIdx_t num_rows
Definition: clSPARSE-1x.h:101
clsparseIdx_t off_col_indices
Definition: clSPARSE-1x.h:82
clsparseIdx_t off_values
Definition: clSPARSE-1x.h:52
cl_mem values
Definition: clSPARSE-1x.h:71
cldenseMajor
For dense data structures, this enum specifies how multi-dimensional data structures are laid out in ...
Definition: clSPARSE-xx.h:35
clsparseIdx_t off_values
Definition: clSPARSE-1x.h:142
clsparseIdx_t num_cols
Definition: clSPARSE-1x.h:65
cl_mem values
Definition: clSPARSE-1x.h:47
clsparseIdx_t num_cols
Definition: clSPARSE-1x.h:132
clsparseIdx_t off_value
Definition: clSPARSE-1x.h:38
Structure to encapsulate sparse matrix data encoded in CSR form to clSPARSE API.
Definition: clSPARSE-1x.h:60
clsparseIdx_t off_row_indices
Definition: clSPARSE-1x.h:120
cl_mem row_pointer
Definition: clSPARSE-1x.h:73
cl_mem values
Definition: clSPARSE-1x.h:137
cl_mem col_indices
Definition: clSPARSE-1x.h:72
cl_mem col_indices
Definition: clSPARSE-1x.h:109
Structure to encapsulate dense matrix data to clSPARSE API.
Definition: clSPARSE-1x.h:127
clsparseIdx_t num_rows
Definition: clSPARSE-1x.h:64
clsparseIdx_t num_rows
Definition: clSPARSE-1x.h:131
cldenseMajor major
Definition: clSPARSE-1x.h:134
void * meta
Definition: clSPARSE-1x.h:89
clsparseIdx_t num_nonzeros
Definition: clSPARSE-1x.h:66
cl_uint clsparseIdx_t
An abstraction for the size of indices supported by the library. Clients should use this index type w...
Definition: clSPARSE-xx.h:49
Structure to encapsulate sparse matrix data encoded in COO form to clSPARSE API.
Definition: clSPARSE-1x.h:97
clsparseIdx_t num_values
Definition: clSPARSE-1x.h:45
cl_mem value
Definition: clSPARSE-1x.h:33
clsparseIdx_t lead_dim
Definition: clSPARSE-1x.h:133
clSPARSE-xx.h defines public types used by any OpenCL version
cl_mem row_indices
Definition: clSPARSE-1x.h:110
clsparseIdx_t num_nonzeros
Definition: clSPARSE-1x.h:103
Structure to encapsulate dense vector data to clSPARSE API.
Definition: clSPARSE-1x.h:43
Structure to encapsulate scalar data to clSPARSE API.
Definition: clSPARSE-1x.h:31
clsparseIdx_t off_col_indices
Definition: clSPARSE-1x.h:119
clsparseIdx_t off_values
Definition: clSPARSE-1x.h:81