data_interfaces.doxy 40 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015
  1. /*
  2. * This file is part of the StarPU Handbook.
  3. * Copyright (C) 2009--2011 Universit@'e de Bordeaux 1
  4. * Copyright (C) 2010, 2011, 2012, 2013 Centre National de la Recherche Scientifique
  5. * Copyright (C) 2011, 2012 Institut National de Recherche en Informatique et Automatique
  6. * See the file version.doxy for copying conditions.
  7. */
  8. /*! \defgroup API_Data_Interfaces Data Interfaces
  9. \struct starpu_data_interface_ops
  10. Per-interface data transfer methods.
  11. \ingroup API_Data_Interfaces
  12. \var starpu_data_interface_ops::register_data_handle
  13. Register an existing interface into a data handle.
  14. \var starpu_data_interface_ops::allocate_data_on_node
  15. Allocate data for the interface on a given node.
  16. \var starpu_data_interface_ops::free_data_on_node
  17. Free data of the interface on a given node.
  18. \var starpu_data_interface_ops::copy_methods
  19. ram/cuda/opencl synchronous and asynchronous transfer methods.
  20. \var starpu_data_interface_ops::handle_to_pointer
  21. Return the current pointer (if any) for the handle on the given node.
  22. \var starpu_data_interface_ops::get_size
  23. Return an estimation of the size of data, for performance models.
  24. \var starpu_data_interface_ops::footprint
  25. Return a 32bit footprint which characterizes the data size.
  26. \var starpu_data_interface_ops::compare
  27. Compare the data size of two interfaces.
  28. \var starpu_data_interface_ops::display
  29. Dump the sizes of a handle to a file.
  30. \var starpu_data_interface_ops::interfaceid
  31. An identifier that is unique to each interface.
  32. \var starpu_data_interface_ops::interface_size
  33. The size of the interface data descriptor.
  34. \var starpu_data_interface_ops::is_multiformat
  35. todo
  36. \var starpu_data_interface_ops::get_mf_ops
  37. todo
  38. \var starpu_data_interface_ops::pack_data
  39. Pack the data handle into a contiguous buffer at the address ptr and
  40. set the size of the newly created buffer in count. If ptr is NULL, the
  41. function should not copy the data in the buffer but just set count to
  42. the size of the buffer which would have been allocated. The special
  43. value -1 indicates the size is yet unknown.
  44. \var starpu_data_interface_ops::unpack_data
  45. Unpack the data handle from the contiguous buffer at the address ptr
  46. of size count
  47. \struct starpu_data_copy_methods
  48. Defines the per-interface methods. If the any_to_any method is
  49. provided, it will be used by default if no more specific method is
  50. provided. It can still be useful to provide more specific method in
  51. case of e.g. available particular CUDA or OpenCL support.
  52. \ingroup API_Data_Interfaces
  53. \var starpu_data_copy_methods::ram_to_ram
  54. Define how to copy data from the \p src_interface interface on the \p
  55. src_node CPU node to the \p dst_interface interface on the \p dst_node
  56. CPU node. Return 0 on success.
  57. \var starpu_data_copy_methods::ram_to_cuda
  58. Define how to copy data from the \p src_interface interface on the
  59. \p src_node CPU node to the \p dst_interface interface on the \p dst_node CUDA
  60. node. Return 0 on success.
  61. \var starpu_data_copy_methods::ram_to_opencl
  62. Define how to copy data from the \p src_interface interface on the
  63. \p src_node CPU node to the \p dst_interface interface on the \p dst_node
  64. OpenCL node. Return 0 on success.
  65. \var starpu_data_copy_methods::ram_to_mic
  66. Define how to copy data from the \p src_interface interface on the
  67. \p src_node CPU node to the \p dst_interface interface on the \p dst_node MIC
  68. node. Return 0 on success.
  69. \var starpu_data_copy_methods::cuda_to_ram
  70. Define how to copy data from the \p src_interface interface on the
  71. \p src_node CUDA node to the \p dst_interface interface on the \p dst_node
  72. CPU node. Return 0 on success.
  73. \var starpu_data_copy_methods::cuda_to_cuda
  74. Define how to copy data from the \p src_interface interface on the
  75. \p src_node CUDA node to the \p dst_interface interface on the \p dst_node CUDA
  76. node. Return 0 on success.
  77. \var starpu_data_copy_methods::cuda_to_opencl
  78. Define how to copy data from the \p src_interface interface on the
  79. \p src_node CUDA node to the \p dst_interface interface on the \p dst_node
  80. OpenCL node. Return 0 on success.
  81. \var starpu_data_copy_methods::opencl_to_ram
  82. Define how to copy data from the \p src_interface interface on the
  83. \p src_node OpenCL node to the \p dst_interface interface on the \p dst_node
  84. CPU node. Return 0 on success.
  85. \var starpu_data_copy_methods::opencl_to_cuda
  86. Define how to copy data from the \p src_interface interface on the
  87. \p src_node OpenCL node to the \p dst_interface interface on the \p dst_node
  88. CUDA node. Return 0 on success.
  89. \var starpu_data_copy_methods::opencl_to_opencl
  90. Define how to copy data from the \p src_interface interface on the
  91. \p src_node OpenCL node to the \p dst_interface interface on the \p dst_node
  92. OpenCL node. Return 0 on success.
  93. \var starpu_data_copy_methods::mic_to_ram
  94. Define how to copy data from the \p src_interface interface on the
  95. \p src_node MIC node to the \p dst_interface interface on the \p dst_node CPU
  96. node. Return 0 on success.
  97. \var starpu_data_copy_methods::scc_src_to_sink
  98. Define how to copy data from the \p src_interface interface on the
  99. \p src_node node to the \p dst_interface interface on the \p dst_node node.
  100. Must return 0 if the transfer was actually completed completely
  101. synchronously, or -EAGAIN if at least some transfers are still ongoing
  102. and should be awaited for by the core.
  103. \var starpu_data_copy_methods::scc_sink_to_src
  104. Define how to copy data from the \p src_interface interface on the
  105. \p src_node node to the \p dst_interface interface on the \p dst_node node.
  106. Must return 0 if the transfer was actually completed completely
  107. synchronously, or -EAGAIN if at least some transfers are still ongoing
  108. and should be awaited for by the core.
  109. \var starpu_data_copy_methods::scc_sink_to_sink
  110. Define how to copy data from the \p src_interface interface on the
  111. \p src_node node to the \p dst_interface interface on the \p dst_node node.
  112. Must return 0 if the transfer was actually completed completely
  113. synchronously, or -EAGAIN if at least some transfers are still ongoing
  114. and should be awaited for by the core.
  115. \var starpu_data_copy_methods::ram_to_cuda_async
  116. Define how to copy data from the \p src_interface interface on the
  117. \p src_node CPU node to the \p dst_interface interface on the \p dst_node CUDA
  118. node, using the given stream. Must return 0 if the transfer was
  119. actually completed completely synchronously, or -EAGAIN if at least
  120. some transfers are still ongoing and should be awaited for by the core.
  121. \var starpu_data_copy_methods::cuda_to_ram_async
  122. Define how to copy data from the \p src_interface interface on the
  123. \p src_node CUDA node to the \p dst_interface interface on the \p dst_node CPU
  124. node, using the given stream. Must return 0 if the transfer was
  125. actually completed completely synchronously, or -EAGAIN if at least
  126. some transfers are still ongoing and should be awaited for by the core.
  127. \var starpu_data_copy_methods::cuda_to_cuda_async
  128. Define how to copy data from the \p src_interface interface on the
  129. \p src_node CUDA node to the \p dst_interface interface on the \p dst_node CUDA
  130. node, using the given stream. Must return 0 if the transfer was
  131. actually completed completely synchronously, or -EAGAIN if at least
  132. some transfers are still ongoing and should be awaited for by the core.
  133. \var starpu_data_copy_methods::ram_to_opencl_async
  134. Define how to copy data from the \p src_interface interface on the
  135. \p src_node CPU node to the \p dst_interface interface on the \p dst_node
  136. OpenCL node, by recording in event, a pointer to a cl_event, the event
  137. of the last submitted transfer. Must return 0 if the transfer was
  138. actually completed completely synchronously, or -EAGAIN if at least
  139. some transfers are still ongoing and should be awaited for by the
  140. core.
  141. \var starpu_data_copy_methods::opencl_to_ram_async
  142. Define how to copy data from the \p src_interface interface on the
  143. \p src_node OpenCL node to the \p dst_interface interface on the \p dst_node
  144. CPU node, by recording in event, a pointer to a cl_event, the event of
  145. the last submitted transfer. Must return 0 if the transfer was
  146. actually completed completely synchronously, or -EAGAIN if at least
  147. some transfers are still ongoing and should be awaited for by the
  148. core.
  149. \var starpu_data_copy_methods::opencl_to_opencl_async
  150. Define how to copy data from the \p src_interface interface on the
  151. \p src_node OpenCL node to the \p dst_interface interface on the \p dst_node
  152. OpenCL node, by recording in event, a pointer to a cl_event, the event
  153. of the last submitted transfer. Must return 0 if the transfer was
  154. actually completed completely synchronously, or -EAGAIN if at least
  155. some transfers are still ongoing and should be awaited for by the
  156. core.
  157. \var starpu_data_copy_methods::ram_to_mic_async
  158. Define how to copy data from the \p src_interface interface on the
  159. \p src_node CPU node to the \p dst_interface interface on the \p dst_node
  160. MIC node. Must return 0 if the transfer was actually completed
  161. completely synchronously, or -EAGAIN if at least some transfers are
  162. still ongoing and should be awaited for by the core.
  163. \var starpu_data_copy_methods::mic_to_ram_async
  164. Define how to copy data from the \p src_interface interface on the
  165. \p src_node MIC node to the \p dst_interface interface on the \p dst_node
  166. CPU node. Must return 0 if the transfer was actually completed
  167. completely synchronously, or -EAGAIN if at least some transfers are
  168. still ongoing and should be awaited for by the core.
  169. \var starpu_data_copy_methods::any_to_any
  170. Define how to copy data from the \p src_interface interface on the
  171. \p src_node node to the \p dst_interface interface on the \p dst_node node.
  172. This is meant to be implemented through the starpu_interface_copy()
  173. helper, to which async_data should be passed as such, and will be used
  174. to manage asynchronicity. This must return -EAGAIN if any of the
  175. starpu_interface_copy() calls has returned -EAGAIN (i.e. at least some
  176. transfer is still ongoing), and return 0 otherwise.
  177. \enum starpu_data_interface_id
  178. \ingroup API_Data_Interfaces
  179. Identifier for all predefined StarPU data interfaces
  180. \var starpu_data_interface_id::STARPU_UNKNOWN_INTERFACE_ID
  181. Unknown interface
  182. \var starpu_data_interface_id::STARPU_MATRIX_INTERFACE_ID
  183. Identifier for the matrix data interface
  184. \var starpu_data_interface_id::STARPU_BLOCK_INTERFACE_ID
  185. Identifier for block data interface
  186. \var starpu_data_interface_id::STARPU_VECTOR_INTERFACE_ID
  187. Identifier for the vector data interface
  188. \var starpu_data_interface_id::STARPU_CSR_INTERFACE_ID
  189. Identifier for the csr data interface
  190. \var starpu_data_interface_id::STARPU_BCSR_INTERFACE_ID
  191. Identifier for the bcsr data interface
  192. \var starpu_data_interface_id::STARPU_VARIABLE_INTERFACE_ID
  193. Identifier for the variable data interface
  194. \var starpu_data_interface_id::STARPU_VOID_INTERFACE_ID
  195. Identifier for the void data interface
  196. \var starpu_data_interface_id::STARPU_MULTIFORMAT_INTERFACE_ID
  197. Identifier for the multiformat data interface
  198. \var starpu_data_interface_id::STARPU_COO_INTERFACE_ID
  199. Identifier for the coo data interface
  200. \var starpu_data_interface_id::STARPU_MAX_INTERFACE_ID
  201. Maximum number of data interfaces
  202. @name Registering Data
  203. \ingroup API_Data_Interfaces
  204. There are several ways to register a memory region so that it can be
  205. managed by StarPU. The functions below allow the registration of
  206. vectors, 2D matrices, 3D matrices as well as BCSR and CSR sparse
  207. matrices.
  208. \fn void starpu_void_data_register(starpu_data_handle_t *handle)
  209. \ingroup API_Data_Interfaces
  210. Register a void interface. There is no data really associated
  211. to that interface, but it may be used as a synchronization mechanism.
  212. It also permits to express an abstract piece of data that is managed
  213. by the application internally: this makes it possible to forbid the
  214. concurrent execution of different tasks accessing the same <c>void</c> data
  215. in read-write concurrently.
  216. \fn void starpu_variable_data_register(starpu_data_handle_t *handle, unsigned home_node, uintptr_t ptr, size_t size)
  217. \ingroup API_Data_Interfaces
  218. Register the \p size byte element pointed to by \p ptr, which is
  219. typically a scalar, and initialize \p handle to represent this data item.
  220. Here an example of how to use the function.
  221. \code{.c}
  222. float var;
  223. starpu_data_handle_t var_handle;
  224. starpu_variable_data_register(&var_handle, STARPU_MAIN_RAM, (uintptr_t)&var, sizeof(var));
  225. \endcode
  226. \fn void starpu_vector_data_register(starpu_data_handle_t *handle, unsigned home_node, uintptr_t ptr, uint32_t nx, size_t elemsize)
  227. \ingroup API_Data_Interfaces
  228. Register the \p nx elemsize-byte elements pointed to by \p ptr and initialize \p handle to represent it.
  229. Here an example of how to use the function.
  230. \code{.c}
  231. float vector[NX];
  232. starpu_data_handle_t vector_handle;
  233. starpu_vector_data_register(&vector_handle, STARPU_MAIN_RAM, (uintptr_t)vector, NX, sizeof(vector[0]));
  234. \endcode
  235. \fn void starpu_matrix_data_register(starpu_data_handle_t *handle, unsigned home_node, uintptr_t ptr, uint32_t ld, uint32_t nx, uint32_t ny, size_t elemsize)
  236. \ingroup API_Data_Interfaces
  237. Register the \p nx x \p ny 2D matrix of \p elemsize-byte elements pointed
  238. by \p ptr and initialize \p handle to represent it. \p ld specifies the number
  239. of elements between rows. a value greater than \p nx adds padding, which
  240. can be useful for alignment purposes.
  241. Here an example of how to use the function.
  242. \code{.c}
  243. float *matrix;
  244. starpu_data_handle_t matrix_handle;
  245. matrix = (float*)malloc(width * height * sizeof(float));
  246. starpu_matrix_data_register(&matrix_handle, STARPU_MAIN_RAM, (uintptr_t)matrix, width, width, height, sizeof(float));
  247. \endcode
  248. \fn void starpu_block_data_register(starpu_data_handle_t *handle, unsigned home_node, uintptr_t ptr, uint32_t ldy, uint32_t ldz, uint32_t nx, uint32_t ny, uint32_t nz, size_t elemsize)
  249. \ingroup API_Data_Interfaces
  250. Register the \p nx x \p ny x \p nz 3D matrix of \p elemsize byte elements
  251. pointed by \p ptr and initialize \p handle to represent it. Again, \p ldy and
  252. \p ldz specify the number of elements between rows and between z planes.
  253. Here an example of how to use the function.
  254. \code{.c}
  255. float *block;
  256. starpu_data_handle_t block_handle;
  257. block = (float*)malloc(nx*ny*nz*sizeof(float));
  258. starpu_block_data_register(&block_handle, STARPU_MAIN_RAM, (uintptr_t)block, nx, nx*ny, nx, ny, nz, sizeof(float));
  259. \endcode
  260. \fn void starpu_bcsr_data_register(starpu_data_handle_t *handle, unsigned home_node, uint32_t nnz, uint32_t nrow, uintptr_t nzval, uint32_t *colind, uint32_t *rowptr, uint32_t firstentry, uint32_t r, uint32_t c, size_t elemsize)
  261. \ingroup API_Data_Interfaces
  262. This variant of starpu_data_register() uses the BCSR (Blocked
  263. Compressed Sparse Row Representation) sparse matrix interface.
  264. Register the sparse matrix made of \p nnz non-zero blocks of elements of
  265. size \p elemsize stored in \p nzval and initializes \p handle to represent it.
  266. Blocks have size \p r * \p c. \p nrow is the number of rows (in terms of
  267. blocks), \p colind[i] is the block-column index for block i in \p nzval,
  268. \p rowptr[i] is the block-index (in \p nzval) of the first block of row i.
  269. \p firstentry is the index of the first entry of the given arrays
  270. (usually 0 or 1).
  271. \fn void starpu_csr_data_register(starpu_data_handle_t *handle, unsigned home_node, uint32_t nnz, uint32_t nrow, uintptr_t nzval, uint32_t *colind, uint32_t *rowptr, uint32_t firstentry, size_t elemsize)
  272. \ingroup API_Data_Interfaces
  273. This variant of starpu_data_register() uses the CSR (Compressed
  274. Sparse Row Representation) sparse matrix interface. TODO
  275. \fn void starpu_coo_data_register(starpu_data_handle_t *handleptr, unsigned home_node, uint32_t nx, uint32_t ny, uint32_t n_values, uint32_t *columns, uint32_t *rows, uintptr_t values, size_t elemsize);
  276. \ingroup API_Data_Interfaces
  277. Register the \p nx x \p ny 2D matrix given in the COO format, using the
  278. \p columns, \p rows, \p values arrays, which must have \p n_values elements of
  279. size \p elemsize. Initialize \p handleptr.
  280. \fn void *starpu_data_get_interface_on_node(starpu_data_handle_t handle, unsigned memory_node)
  281. \ingroup API_Data_Interfaces
  282. Return the interface associated with \p handle on \p memory_node.
  283. @name Accessing Data Interfaces
  284. \ingroup API_Data_Interfaces
  285. Each data interface is provided with a set of field access functions.
  286. The ones using a void * parameter aimed to be used in codelet
  287. implementations (see for example the code in \ref
  288. VectorScalingUsingStarPUAPI).
  289. \fn void *starpu_data_handle_to_pointer(starpu_data_handle_t handle, unsigned node)
  290. \ingroup API_Data_Interfaces
  291. Return the pointer associated with \p handle on node \p node or <c>NULL</c>
  292. if handle’s interface does not support this operation or data for this
  293. \p handle is not allocated on that \p node.
  294. \fn void *starpu_data_get_local_ptr(starpu_data_handle_t handle)
  295. \ingroup API_Data_Interfaces
  296. Return the local pointer associated with \p handle or <c>NULL</c> if
  297. \p handle’s interface does not have data allocated locally
  298. \fn enum starpu_data_interface_id starpu_data_get_interface_id(starpu_data_handle_t handle)
  299. \ingroup API_Data_Interfaces
  300. Return the unique identifier of the interface associated with
  301. the given \p handle.
  302. \fn size_t starpu_data_get_size(starpu_data_handle_t handle)
  303. \ingroup API_Data_Interfaces
  304. Return the size of the data associated with \p handle.
  305. \fn int starpu_data_pack(starpu_data_handle_t handle, void **ptr, starpu_ssize_t *count)
  306. \ingroup API_Data_Interfaces
  307. Execute the packing operation of the interface of the data
  308. registered at \p handle (see starpu_data_interface_ops). This
  309. packing operation must allocate a buffer large enough at \p ptr and copy
  310. into the newly allocated buffer the data associated to \p handle. \p count
  311. will be set to the size of the allocated buffer. If \p ptr is NULL, the
  312. function should not copy the data in the buffer but just set \p count to
  313. the size of the buffer which would have been allocated. The special
  314. value -1 indicates the size is yet unknown.
  315. \fn int starpu_data_unpack(starpu_data_handle_t handle, void *ptr, size_t count)
  316. \ingroup API_Data_Interfaces
  317. Unpack in handle the data located at \p ptr of size \p count as
  318. described by the interface of the data. The interface registered at
  319. \p handle must define a unpacking operation (see
  320. starpu_data_interface_ops). The memory at the address \p ptr is freed
  321. after calling the data unpacking operation.
  322. @name Accessing Variable Data Interfaces
  323. \ingroup API_Data_Interfaces
  324. \struct starpu_variable_interface
  325. Variable interface for a single data (not a vector, a matrix, a list, ...)
  326. \ingroup API_Data_Interfaces
  327. \var starpu_variable_interface::id
  328. Identifier of the interface
  329. \var starpu_variable_interface::ptr
  330. local pointer of the variable
  331. \var starpu_variable_interface::dev_handle
  332. device handle of the variable.
  333. \var starpu_variable_interface::offset
  334. offset in the variable
  335. \var starpu_variable_interface::elemsize
  336. size of the variable
  337. \fn size_t starpu_variable_get_elemsize(starpu_data_handle_t handle)
  338. \ingroup API_Data_Interfaces
  339. Return the size of the variable designated by \p handle.
  340. \fn uintptr_t starpu_variable_get_local_ptr(starpu_data_handle_t handle)
  341. \ingroup API_Data_Interfaces
  342. Return a pointer to the variable designated by \p handle.
  343. \def STARPU_VARIABLE_GET_PTR(interface)
  344. \ingroup API_Data_Interfaces
  345. Return a pointer to the variable designated by \p interface.
  346. \def STARPU_VARIABLE_GET_ELEMSIZE(interface)
  347. \ingroup API_Data_Interfaces
  348. Return the size of the variable designated by \p interface.
  349. \def STARPU_VARIABLE_GET_DEV_HANDLE(interface)
  350. \ingroup API_Data_Interfaces
  351. Return a device handle for the variable designated by
  352. \p interface, to be used on OpenCL. The offset documented below has to be
  353. used in addition to this.
  354. \def STARPU_VARIABLE_GET_OFFSET(interface)
  355. \ingroup API_Data_Interfaces
  356. Return the offset in the variable designated by \p interface, to
  357. be used with the device handle.
  358. @name Accessing Vector Data Interfaces
  359. \ingroup API_Data_Interfaces
  360. \struct starpu_vector_interface
  361. Vector interface
  362. \ingroup API_Data_Interfaces
  363. \var starpu_vector_interface::id
  364. Identifier of the interface
  365. \var starpu_vector_interface::ptr
  366. local pointer of the vector
  367. \var starpu_vector_interface::dev_handle
  368. device handle of the vector.
  369. \var starpu_vector_interface::offset
  370. offset in the vector
  371. \var starpu_vector_interface::nx
  372. number of elements on the x-axis of the vector
  373. \var starpu_vector_interface::elemsize
  374. size of the elements of the vector
  375. \fn uint32_t starpu_vector_get_nx(starpu_data_handle_t handle)
  376. \ingroup API_Data_Interfaces
  377. Return the number of elements registered into the array designated by \p handle.
  378. \fn size_t starpu_vector_get_elemsize(starpu_data_handle_t handle)
  379. \ingroup API_Data_Interfaces
  380. Return the size of each element of the array designated by \p handle.
  381. \fn uintptr_t starpu_vector_get_local_ptr(starpu_data_handle_t handle)
  382. \ingroup API_Data_Interfaces
  383. Return the local pointer associated with \p handle.
  384. \def STARPU_VECTOR_GET_PTR(interface)
  385. \ingroup API_Data_Interfaces
  386. Return a pointer to the array designated by \p interface, valid on
  387. CPUs and CUDA only. For OpenCL, the device handle and offset need to
  388. be used instead.
  389. \def STARPU_VECTOR_GET_DEV_HANDLE(interface)
  390. \ingroup API_Data_Interfaces
  391. Return a device handle for the array designated by \p interface,
  392. to be used on OpenCL. the offset documented below has to be used in
  393. addition to this.
  394. \def STARPU_VECTOR_GET_OFFSET(interface)
  395. \ingroup API_Data_Interfaces
  396. Return the offset in the array designated by \p interface, to be
  397. used with the device handle.
  398. \def STARPU_VECTOR_GET_NX(interface)
  399. \ingroup API_Data_Interfaces
  400. Return the number of elements registered into the array
  401. designated by \p interface.
  402. \def STARPU_VECTOR_GET_ELEMSIZE(interface)
  403. \ingroup API_Data_Interfaces
  404. Return the size of each element of the array designated by
  405. \p interface.
  406. @name Accessing Matrix Data Interfaces
  407. \ingroup API_Data_Interfaces
  408. \struct starpu_matrix_interface
  409. Matrix interface for dense matrices
  410. \ingroup API_Data_Interfaces
  411. \var starpu_matrix_interface::id
  412. Identifier of the interface
  413. \var starpu_matrix_interface::ptr
  414. local pointer of the matrix
  415. \var starpu_matrix_interface::dev_handle
  416. device handle of the matrix.
  417. \var starpu_matrix_interface::offset
  418. offset in the matrix
  419. \var starpu_matrix_interface::nx
  420. number of elements on the x-axis of the matrix
  421. \var starpu_matrix_interface::ny
  422. number of elements on the y-axis of the matrix
  423. \var starpu_matrix_interface::ld
  424. number of elements between each row of the matrix. Maybe be equal to
  425. starpu_matrix_interface::nx when there is no padding.
  426. \var starpu_matrix_interface::elemsize
  427. size of the elements of the matrix
  428. \fn uint32_t starpu_matrix_get_nx(starpu_data_handle_t handle)
  429. \ingroup API_Data_Interfaces
  430. Return the number of elements on the x-axis of the matrix
  431. designated by \p handle.
  432. \fn uint32_t starpu_matrix_get_ny(starpu_data_handle_t handle)
  433. \ingroup API_Data_Interfaces
  434. Return the number of elements on the y-axis of the matrix
  435. designated by \p handle.
  436. \fn uint32_t starpu_matrix_get_local_ld(starpu_data_handle_t handle)
  437. \ingroup API_Data_Interfaces
  438. Return the number of elements between each row of the matrix
  439. designated by \p handle. Maybe be equal to nx when there is no padding.
  440. \fn uintptr_t starpu_matrix_get_local_ptr(starpu_data_handle_t handle)
  441. \ingroup API_Data_Interfaces
  442. Return the local pointer associated with \p handle.
  443. \fn size_t starpu_matrix_get_elemsize(starpu_data_handle_t handle)
  444. \ingroup API_Data_Interfaces
  445. Return the size of the elements registered into the matrix
  446. designated by \p handle.
  447. \def STARPU_MATRIX_GET_PTR(interface)
  448. \ingroup API_Data_Interfaces
  449. Return a pointer to the matrix designated by \p interface, valid
  450. on CPUs and CUDA devices only. For OpenCL devices, the device handle
  451. and offset need to be used instead.
  452. \def STARPU_MATRIX_GET_DEV_HANDLE(interface)
  453. \ingroup API_Data_Interfaces
  454. Return a device handle for the matrix designated by \p interface,
  455. to be used on OpenCL. The offset documented below has to be used in
  456. addition to this.
  457. \def STARPU_MATRIX_GET_OFFSET(interface)
  458. \ingroup API_Data_Interfaces
  459. Return the offset in the matrix designated by \p interface, to be
  460. used with the device handle.
  461. \def STARPU_MATRIX_GET_NX(interface)
  462. \ingroup API_Data_Interfaces
  463. Return the number of elements on the x-axis of the matrix
  464. designated by \p interface.
  465. \def STARPU_MATRIX_GET_NY(interface)
  466. \ingroup API_Data_Interfaces
  467. Return the number of elements on the y-axis of the matrix
  468. designated by \p interface.
  469. \def STARPU_MATRIX_GET_LD(interface)
  470. \ingroup API_Data_Interfaces
  471. Return the number of elements between each row of the matrix
  472. designated by \p interface. May be equal to nx when there is no padding.
  473. \def STARPU_MATRIX_GET_ELEMSIZE(interface)
  474. \ingroup API_Data_Interfaces
  475. Return the size of the elements registered into the matrix
  476. designated by \p interface.
  477. @name Accessing Block Data Interfaces
  478. \ingroup API_Data_Interfaces
  479. \struct starpu_block_interface
  480. Block interface for 3D dense blocks
  481. \ingroup API_Data_Interfaces
  482. \var starpu_block_interface::id
  483. identifier of the interface
  484. \var starpu_block_interface::ptr
  485. local pointer of the block
  486. \var starpu_block_interface::dev_handle
  487. device handle of the block.
  488. \var starpu_block_interface::offset
  489. offset in the block.
  490. \var starpu_block_interface::nx
  491. number of elements on the x-axis of the block.
  492. \var starpu_block_interface::ny
  493. number of elements on the y-axis of the block.
  494. \var starpu_block_interface::nz
  495. number of elements on the z-axis of the block.
  496. \var starpu_block_interface::ldy
  497. number of elements between two lines
  498. \var starpu_block_interface::ldz
  499. number of elements between two planes
  500. \var starpu_block_interface::elemsize
  501. size of the elements of the block.
  502. \fn uint32_t starpu_block_get_nx(starpu_data_handle_t handle)
  503. \ingroup API_Data_Interfaces
  504. Return the number of elements on the x-axis of the block
  505. designated by \p handle.
  506. \fn uint32_t starpu_block_get_ny(starpu_data_handle_t handle)
  507. \ingroup API_Data_Interfaces
  508. Return the number of elements on the y-axis of the block
  509. designated by \p handle.
  510. \fn uint32_t starpu_block_get_nz(starpu_data_handle_t handle)
  511. \ingroup API_Data_Interfaces
  512. Return the number of elements on the z-axis of the block
  513. designated by \p handle.
  514. \fn uint32_t starpu_block_get_local_ldy(starpu_data_handle_t handle)
  515. \ingroup API_Data_Interfaces
  516. Return the number of elements between each row of the block
  517. designated by \p handle, in the format of the current memory node.
  518. \fn uint32_t starpu_block_get_local_ldz(starpu_data_handle_t handle)
  519. \ingroup API_Data_Interfaces
  520. Return the number of elements between each z plane of the block
  521. designated by \p handle, in the format of the current memory node.
  522. \fn uintptr_t starpu_block_get_local_ptr(starpu_data_handle_t handle)
  523. \ingroup API_Data_Interfaces
  524. Return the local pointer associated with \p handle.
  525. \fn size_t starpu_block_get_elemsize(starpu_data_handle_t handle)
  526. \ingroup API_Data_Interfaces
  527. Return the size of the elements of the block designated by
  528. \p handle.
  529. \def STARPU_BLOCK_GET_PTR(interface)
  530. \ingroup API_Data_Interfaces
  531. Return a pointer to the block designated by \p interface.
  532. \def STARPU_BLOCK_GET_DEV_HANDLE(interface)
  533. \ingroup API_Data_Interfaces
  534. Return a device handle for the block designated by \p interface,
  535. to be used on OpenCL. The offset document below has to be used in
  536. addition to this.
  537. \def STARPU_BLOCK_GET_OFFSET(interface)
  538. \ingroup API_Data_Interfaces
  539. Return the offset in the block designated by \p interface, to be
  540. used with the device handle.
  541. \def STARPU_BLOCK_GET_NX(interface)
  542. \ingroup API_Data_Interfaces
  543. Return the number of elements on the x-axis of the block
  544. designated by \p interface.
  545. \def STARPU_BLOCK_GET_NY(interface)
  546. \ingroup API_Data_Interfaces
  547. Return the number of elements on the y-axis of the block
  548. designated by \p interface.
  549. \def STARPU_BLOCK_GET_NZ(interface)
  550. \ingroup API_Data_Interfaces
  551. Return the number of elements on the z-axis of the block
  552. designated by \p interface.
  553. \def STARPU_BLOCK_GET_LDY(interface)
  554. \ingroup API_Data_Interfaces
  555. Return the number of elements between each row of the block
  556. designated by \p interface. May be equal to nx when there is no padding.
  557. \def STARPU_BLOCK_GET_LDZ(interface)
  558. \ingroup API_Data_Interfaces
  559. Return the number of elements between each z plane of the block
  560. designated by \p interface. May be equal to nx*ny when there is no
  561. padding.
  562. \def STARPU_BLOCK_GET_ELEMSIZE(interface)
  563. \ingroup API_Data_Interfaces
  564. Return the size of the elements of the block designated by
  565. \p interface.
  566. @name Accessing BCSR Data Interfaces
  567. \ingroup API_Data_Interfaces
  568. \struct starpu_bcsr_interface
  569. BCSR interface for sparse matrices (blocked compressed sparse
  570. row representation)
  571. \ingroup API_Data_Interfaces
  572. \var starpu_bcsr_interface::id
  573. Identifier of the interface
  574. \var starpu_bcsr_interface::nnz
  575. number of non-zero BLOCKS
  576. \var starpu_bcsr_interface::nrow
  577. number of rows (in terms of BLOCKS)
  578. \var starpu_bcsr_interface::nzval
  579. non-zero values
  580. \var starpu_bcsr_interface::colind
  581. position of non-zero entried on the row
  582. \var starpu_bcsr_interface::rowptr
  583. index (in nzval) of the first entry of the row
  584. \var starpu_bcsr_interface::firstentry
  585. k for k-based indexing (0 or 1 usually). Also useful when partitionning the matrix.
  586. \var starpu_bcsr_interface::r
  587. size of the blocks
  588. \var starpu_bcsr_interface::c
  589. size of the blocks
  590. \var starpu_bcsr_interface::elemsize;
  591. size of the elements of the matrix
  592. \fn uint32_t starpu_bcsr_get_nnz(starpu_data_handle_t handle)
  593. \ingroup API_Data_Interfaces
  594. Return the number of non-zero elements in the matrix designated
  595. by \p handle.
  596. \fn uint32_t starpu_bcsr_get_nrow(starpu_data_handle_t handle)
  597. \ingroup API_Data_Interfaces
  598. Return the number of rows (in terms of blocks of size r*c) in
  599. the matrix designated by \p handle.
  600. \fn uint32_t starpu_bcsr_get_firstentry(starpu_data_handle_t handle)
  601. \ingroup API_Data_Interfaces
  602. Return the index at which all arrays (the column indexes, the
  603. row pointers...) of the matrix desginated by \p handle.
  604. \fn uintptr_t starpu_bcsr_get_local_nzval(starpu_data_handle_t handle)
  605. \ingroup API_Data_Interfaces
  606. Return a pointer to the non-zero values of the matrix
  607. designated by \p handle.
  608. \fn uint32_t *starpu_bcsr_get_local_colind(starpu_data_handle_t handle)
  609. \ingroup API_Data_Interfaces
  610. Return a pointer to the column index, which holds the positions
  611. of the non-zero entries in the matrix designated by \p handle.
  612. \fn uint32_t *starpu_bcsr_get_local_rowptr(starpu_data_handle_t handle)
  613. \ingroup API_Data_Interfaces
  614. Return the row pointer array of the matrix designated by
  615. \p handle.
  616. \fn uint32_t starpu_bcsr_get_r(starpu_data_handle_t handle)
  617. \ingroup API_Data_Interfaces
  618. Return the number of rows in a block.
  619. \fn uint32_t starpu_bcsr_get_c(starpu_data_handle_t handle)
  620. \ingroup API_Data_Interfaces
  621. Return the numberof columns in a block.
  622. \fn size_t starpu_bcsr_get_elemsize(starpu_data_handle_t handle)
  623. \ingroup API_Data_Interfaces
  624. Return the size of the elements in the matrix designated by
  625. \p handle.
  626. \def STARPU_BCSR_GET_NNZ(interface)
  627. \ingroup API_Data_Interfaces
  628. Return the number of non-zero values in the matrix designated
  629. by \p interface.
  630. \def STARPU_BCSR_GET_NZVAL(interface)
  631. \ingroup API_Data_Interfaces
  632. Return a pointer to the non-zero values of the matrix
  633. designated by \p interface.
  634. \def STARPU_BCSR_GET_NZVAL_DEV_HANDLE(interface)
  635. \ingroup API_Data_Interfaces
  636. Return a device handle for the array of non-zero values in the
  637. matrix designated by \p interface. The offset documented below has to be
  638. used in addition to this.
  639. \def STARPU_BCSR_GET_COLIND(interface)
  640. \ingroup API_Data_Interfaces
  641. Return a pointer to the column index of the matrix designated
  642. by \p interface.
  643. \def STARPU_BCSR_GET_COLIND_DEV_HANDLE(interface)
  644. \ingroup API_Data_Interfaces
  645. Return a device handle for the column index of the matrix
  646. designated by \p interface. The offset documented below has to be used in
  647. addition to this.
  648. \def STARPU_BCSR_GET_ROWPTR(interface)
  649. \ingroup API_Data_Interfaces
  650. Return a pointer to the row pointer array of the matrix
  651. designated by \p interface.
  652. \def STARPU_BCSR_GET_ROWPTR_DEV_HANDLE(interface)
  653. \ingroup API_Data_Interfaces
  654. Return a device handle for the row pointer array of the matrix
  655. designated by \p interface. The offset documented below has to be used in
  656. addition to this.
  657. \def STARPU_BCSR_GET_OFFSET
  658. \ingroup API_Data_Interfaces
  659. Return the offset in the arrays (coling, rowptr, nzval) of the
  660. matrix designated by \p interface, to be used with the device handles.
  661. @name Accessing CSR Data Interfaces
  662. \ingroup API_Data_Interfaces
  663. \struct starpu_csr_interface
  664. CSR interface for sparse matrices (compressed sparse row representation)
  665. \ingroup API_Data_Interfaces
  666. \var starpu_csr_interface::id
  667. Identifier of the interface
  668. \var starpu_csr_interface::nnz
  669. number of non-zero entries
  670. \var starpu_csr_interface::nrow
  671. number of rows
  672. \var starpu_csr_interface::nzval
  673. non-zero values
  674. \var starpu_csr_interface::colind
  675. position of non-zero entries on the row
  676. \var starpu_csr_interface::rowptr
  677. index (in nzval) of the first entry of the row
  678. \var starpu_csr_interface::firstentry
  679. k for k-based indexing (0 or 1 usually). also useful when partitionning the matrix.
  680. \var starpu_csr_interface::elemsize
  681. size of the elements of the matrix
  682. \fn uint32_t starpu_csr_get_nnz(starpu_data_handle_t handle)
  683. \ingroup API_Data_Interfaces
  684. Return the number of non-zero values in the matrix designated
  685. by \p handle.
  686. \fn uint32_t starpu_csr_get_nrow(starpu_data_handle_t handle)
  687. \ingroup API_Data_Interfaces
  688. Return the size of the row pointer array of the matrix
  689. designated by \p handle.
  690. \fn uint32_t starpu_csr_get_firstentry(starpu_data_handle_t handle)
  691. \ingroup API_Data_Interfaces
  692. Return the index at which all arrays (the column indexes, the
  693. row pointers...) of the matrix designated by \p handle.
  694. \fn uintptr_t starpu_csr_get_local_nzval(starpu_data_handle_t handle)
  695. \ingroup API_Data_Interfaces
  696. Return a local pointer to the non-zero values of the matrix
  697. designated by \p handle.
  698. \fn uint32_t *starpu_csr_get_local_colind(starpu_data_handle_t handle)
  699. \ingroup API_Data_Interfaces
  700. Return a local pointer to the column index of the matrix
  701. designated by \p handle.
  702. \fn uint32_t *starpu_csr_get_local_rowptr(starpu_data_handle_t handle)
  703. \ingroup API_Data_Interfaces
  704. Return a local pointer to the row pointer array of the matrix
  705. designated by \p handle.
  706. \fn size_t starpu_csr_get_elemsize(starpu_data_handle_t handle)
  707. \ingroup API_Data_Interfaces
  708. Return the size of the elements registered into the matrix
  709. designated by \p handle.
  710. \def STARPU_CSR_GET_NNZ(interface)
  711. \ingroup API_Data_Interfaces
  712. Return the number of non-zero values in the matrix designated
  713. by \p interface.
  714. \def STARPU_CSR_GET_NROW(interface)
  715. \ingroup API_Data_Interfaces
  716. Return the size of the row pointer array of the matrix
  717. designated by \p interface.
  718. \def STARPU_CSR_GET_NZVAL(interface)
  719. \ingroup API_Data_Interfaces
  720. Return a pointer to the non-zero values of the matrix
  721. designated by \p interface.
  722. \def STARPU_CSR_GET_NZVAL_DEV_HANDLE(interface)
  723. \ingroup API_Data_Interfaces
  724. Return a device handle for the array of non-zero values in the
  725. matrix designated by \p interface. The offset documented below has to be
  726. used in addition to this.
  727. \def STARPU_CSR_GET_COLIND(interface)
  728. \ingroup API_Data_Interfaces
  729. Return a pointer to the column index of the matrix designated
  730. by \p interface.
  731. \def STARPU_CSR_GET_COLIND_DEV_HANDLE(interface)
  732. \ingroup API_Data_Interfaces
  733. Return a device handle for the column index of the matrix
  734. designated by \p interface. The offset documented below has to be used in
  735. addition to this.
  736. \def STARPU_CSR_GET_ROWPTR(interface)
  737. \ingroup API_Data_Interfaces
  738. Return a pointer to the row pointer array of the matrix
  739. designated by \p interface.
  740. \def STARPU_CSR_GET_ROWPTR_DEV_HANDLE(interface)
  741. \ingroup API_Data_Interfaces
  742. Return a device handle for the row pointer array of the matrix
  743. designated by \p interface. The offset documented below has to be used in
  744. addition to this.
  745. \def STARPU_CSR_GET_OFFSET
  746. \ingroup API_Data_Interfaces
  747. Return the offset in the arrays (colind, rowptr, nzval) of the
  748. matrix designated by \p interface, to be used with the device handles.
  749. \def STARPU_CSR_GET_FIRSTENTRY(interface)
  750. \ingroup API_Data_Interfaces
  751. Return the index at which all arrays (the column indexes, the
  752. row pointers...) of the \p interface start.
  753. \def STARPU_CSR_GET_ELEMSIZE(interface)
  754. \ingroup API_Data_Interfaces
  755. Return the size of the elements registered into the matrix
  756. designated by \p interface.
  757. @name Accessing COO Data Interfaces
  758. \ingroup API_Data_Interfaces
  759. \struct starpu_coo_interface
  760. COO Matrices
  761. \ingroup API_Data_Interfaces
  762. \var starpu_coo_interface::id
  763. identifier of the interface
  764. \var starpu_coo_interface::columns
  765. column array of the matrix
  766. \var starpu_coo_interface::rows
  767. row array of the matrix
  768. \var starpu_coo_interface::values
  769. values of the matrix
  770. \var starpu_coo_interface::nx
  771. number of elements on the x-axis of the matrix
  772. \var starpu_coo_interface::ny
  773. number of elements on the y-axis of the matrix
  774. \var starpu_coo_interface::n_values
  775. number of values registered in the matrix
  776. \var starpu_coo_interface::elemsize
  777. size of the elements of the matrix
  778. \def STARPU_COO_GET_COLUMNS(interface)
  779. \ingroup API_Data_Interfaces
  780. Return a pointer to the column array of the matrix designated
  781. by \p interface.
  782. \def STARPU_COO_GET_COLUMNS_DEV_HANDLE(interface)
  783. \ingroup API_Data_Interfaces
  784. Return a device handle for the column array of the matrix
  785. designated by \p interface, to be used on OpenCL. The offset documented
  786. below has to be used in addition to this.
  787. \def STARPU_COO_GET_ROWS(interface)
  788. \ingroup API_Data_Interfaces
  789. Return a pointer to the rows array of the matrix designated by
  790. \p interface.
  791. \def STARPU_COO_GET_ROWS_DEV_HANDLE(interface)
  792. \ingroup API_Data_Interfaces
  793. Return a device handle for the row array of the matrix
  794. designated by \p interface, to be used on OpenCL. The offset documented
  795. below has to be used in addition to this.
  796. \def STARPU_COO_GET_VALUES(interface)
  797. \ingroup API_Data_Interfaces
  798. Return a pointer to the values array of the matrix designated
  799. by \p interface.
  800. \def STARPU_COO_GET_VALUES_DEV_HANDLE(interface)
  801. \ingroup API_Data_Interfaces
  802. Return a device handle for the value array of the matrix
  803. designated by \p interface, to be used on OpenCL. The offset documented
  804. below has to be used in addition to this.
  805. \def STARPU_COO_GET_OFFSET
  806. \ingroup API_Data_Interfaces
  807. Return the offset in the arrays of the COO matrix designated by
  808. \p interface.
  809. \def STARPU_COO_GET_NX(interface)
  810. \ingroup API_Data_Interfaces
  811. Return the number of elements on the x-axis of the matrix
  812. designated by \p interface.
  813. \def STARPU_COO_GET_NY(interface)
  814. \ingroup API_Data_Interfaces
  815. Return the number of elements on the y-axis of the matrix
  816. designated by \p interface.
  817. \def STARPU_COO_GET_NVALUES(interface)
  818. \ingroup API_Data_Interfaces
  819. Return the number of values registered in the matrix designated
  820. by \p interface.
  821. \def STARPU_COO_GET_ELEMSIZE(interface)
  822. \ingroup API_Data_Interfaces
  823. Return the size of the elements registered into the matrix
  824. designated by \p interface.
  825. @name Defining Interface
  826. \ingroup API_Data_Interfaces
  827. Applications can provide their own interface as shown in \ref
  828. DefiningANewDataInterface.
  829. \fn uintptr_t starpu_malloc_on_node(unsigned dst_node, size_t size)
  830. \ingroup API_Data_Interfaces
  831. Allocate \p size bytes on node \p dst_node. This returns 0 if
  832. allocation failed, the allocation method should then return <c>-ENOMEM</c> as
  833. allocated size.
  834. \fn void starpu_free_on_node(unsigned dst_node, uintptr_t addr, size_t size)
  835. \ingroup API_Data_Interfaces
  836. Free \p addr of \p size bytes on node \p dst_node.
  837. \fn int starpu_interface_copy(uintptr_t src, size_t src_offset, unsigned src_node, uintptr_t dst, size_t dst_offset, unsigned dst_node, size_t size, void *async_data)
  838. \ingroup API_Data_Interfaces
  839. Copy \p size bytes from byte offset \p src_offset of \p src on \p src_node
  840. to byte offset \p dst_offset of \p dst on \p dst_node. This is to be used in
  841. the any_to_any() copy method, which is provided with the async_data to
  842. be passed to starpu_interface_copy(). this returns <c>-EAGAIN</c> if the
  843. transfer is still ongoing, or 0 if the transfer is already completed.
  844. \fn uint32_t starpu_hash_crc32c_be_n(const void *input, size_t n, uint32_t inputcrc)
  845. \ingroup API_Data_Interfaces
  846. Compute the CRC of a byte buffer seeded by the \p inputcrc
  847. <em>current state</em>. The return value should be considered as the new
  848. <em>current state</em> for future CRC computation. This is used for computing
  849. data size footprint.
  850. \fn uint32_t starpu_hash_crc32c_be(uint32_t input, uint32_t inputcrc)
  851. \ingroup API_Data_Interfaces
  852. Compute the CRC of a 32bit number seeded by the \p inputcrc
  853. <em>current state</em>. The return value should be considered as the new
  854. <em>current state</em> for future CRC computation. This is used for computing
  855. data size footprint.
  856. \fn uint32_t starpu_hash_crc32c_string(const char *str, uint32_t inputcrc)
  857. \ingroup API_Data_Interfaces
  858. Compute the CRC of a string seeded by the \p inputcrc <em>current
  859. state</em>. The return value should be considered as the new <em>current
  860. state</em> for future CRC computation. This is used for computing data
  861. size footprint.
  862. \fn int starpu_data_interface_get_next_id(void)
  863. \ingroup API_Data_Interfaces
  864. Return the next available id for a newly created data interface
  865. (\ref DefiningANewDataInterface).
  866. */