MCPcopy Create free account
hub / github.com/RedisGraph/RedisGraph / main

Function main

deps/GraphBLAS/Demo/Program/wildtype_demo.c:183–437  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

181"============================================================================\n"
182
183int main (void)
184{
185
186 // start GraphBLAS
187 #if 1
188 GrB_init (GrB_NONBLOCKING) ;
189 #else
190 rmm_wrap_initialize (rmm_wrap_managed, 256 * 1000000L, 256 * 1000000000L) ;
191 GxB_init (GxB_NONBLOCKING_GPU, rmm_wrap_malloc,
192 rmm_wrap_calloc, rmm_wrap_realloc, rmm_wrap_free) ;
193 GxB_set (GxB_GPU_CONTROL, GxB_GPU_ALWAYS) ;
194 #endif
195
196 int nthreads ;
197 GxB_Global_Option_get (GxB_GLOBAL_NTHREADS, &nthreads) ;
198 fprintf (stderr, "wildtype demo: nthreads %d\n", nthreads) ;
199
200 /* alternative method via #defines:
201 fprintf (stderr, LINE2 "SuiteSparse:GraphBLAS Version %d.%d.%d, %s\n" LINE2
202 "%s" LINE "License: %s" LINE "GraphBLAS API Version %d.%d.%d, %s"
203 " (http://graphblas.org)\n%s" LINE2, GxB_IMPLEMENTATION_MAJOR,
204 GxB_IMPLEMENTATION_MINOR, GxB_IMPLEMENTATION_SUB,
205 GxB_IMPLEMENTATION_DATE, GxB_IMPLEMENTATION_ABOUT,
206 GxB_IMPLEMENTATION_LICENSE, GxB_SPEC_MAJOR, GxB_SPEC_MINOR,
207 GxB_SPEC_SUB, GxB_SPEC_DATE, GxB_SPEC_ABOUT) ;
208 */
209
210 char *library ; GxB_Global_Option_get (GxB_LIBRARY_NAME, &library) ;
211 int version [3] ; GxB_Global_Option_get (GxB_LIBRARY_VERSION, version) ;
212 char *date ; GxB_Global_Option_get (GxB_LIBRARY_DATE, &date) ;
213 char *about ; GxB_Global_Option_get (GxB_LIBRARY_ABOUT, &about) ;
214 char *url ; GxB_Global_Option_get (GxB_LIBRARY_URL, &url) ;
215 char *license ; GxB_Global_Option_get (GxB_LIBRARY_LICENSE, &license) ;
216 char *cdate ; GxB_Global_Option_get (GxB_LIBRARY_COMPILE_DATE, &cdate) ;
217 char *ctime ; GxB_Global_Option_get (GxB_LIBRARY_COMPILE_TIME, &ctime) ;
218 int api_ver [3] ; GxB_Global_Option_get (GxB_API_VERSION, api_ver) ;
219 char *api_date ; GxB_Global_Option_get (GxB_API_DATE, &api_date) ;
220 char *api_about ; GxB_Global_Option_get (GxB_API_ABOUT, &api_about) ;
221 char *api_url ; GxB_Global_Option_get (GxB_API_URL, &api_url) ;
222
223 fprintf (stderr, LINE2 "%s Version %d.%d.%d, %s\n" LINE2 "%s"
224 "(%s)\n" LINE "License:\n%s" LINE "GraphBLAS API Version %d.%d.%d, %s"
225 " (%s)\n%s" LINE2,
226 library, version [0], version [1], version [2], date, about, url,
227 license, api_ver [0], api_ver [1], api_ver [2], api_date, api_url,
228 api_about) ;
229 fprintf (stderr, "compiled: %s %s\n", cdate, ctime) ;
230
231 double hyper_switch ;
232 GxB_Global_Option_get (GxB_HYPER_SWITCH, &hyper_switch) ;
233 fprintf (stderr, "hyper switch: %g\n", hyper_switch) ;
234
235 GxB_Format_Value format ;
236 GxB_Global_Option_get (GxB_FORMAT, &format) ;
237 fprintf (stderr, "format: %s\n", (format == GxB_BY_ROW) ? "CSR" : "CSC") ;
238
239 GrB_Mode mode ;
240 GxB_Global_Option_get (GxB_MODE, &mode) ;

Callers

nothing calls this directly

Calls 15

GrB_initFunction · 0.85
rmm_wrap_initializeFunction · 0.85
GxB_initFunction · 0.85
GxB_Global_Option_getFunction · 0.85
GxB_Type_newFunction · 0.85
GxB_Type_sizeFunction · 0.85
GxB_Type_fprintFunction · 0.85
GrB_Matrix_newFunction · 0.85
wildtype_printFunction · 0.85
GrB_transposeFunction · 0.85
GxB_BinaryOp_newFunction · 0.85
GrB_Monoid_new_UDTFunction · 0.85

Tested by

no test coverage detected