瀏覽代碼

doc: be more explicit on how to initialise a codelet

Nathalie Furmento 12 年之前
父節點
當前提交
db28916999
共有 2 個文件被更改,包括 3 次插入1 次删除
  1. 1 0
      doc/chapters/api.texi
  2. 2 1
      doc/chapters/basic-examples.texi

+ 1 - 0
doc/chapters/api.texi

@@ -1933,6 +1933,7 @@ Define the name of the codelet. This can be useful for debugging purposes.
 @end deftp
 
 @deftypefun void starpu_codelet_init ({struct starpu_codelet} *@var{cl})
+@anchor{starpu_codelet_init}
 Initialize @var{cl} with default values. Codelets should preferably be
 initialized statically as shown in @ref{Defining a Codelet}. However
 such a initialisation is not always possible, e.g. when using C++.

+ 2 - 1
doc/chapters/basic-examples.texi

@@ -140,7 +140,8 @@ struct starpu_codelet cl =
 A codelet is a structure that represents a computational kernel. Such a codelet
 may contain an implementation of the same kernel on different architectures
 (e.g. CUDA, x86, ...). For compatibility, make sure that the whole
-structure is initialized to zero, either by using memset, or by letting the
+structure is properly initialized to zero, either by using the
+function starpu_codelet_init (@pxref{starpu_codelet_init}), or by letting the
 compiler implicitly do it as examplified above.
 
 The @code{nbuffers} field specifies the number of data buffers that are