Browse Source

merge trunk

Samuel Thibault 12 years ago
parent
commit
dfa83c73e9
2 changed files with 12 additions and 0 deletions
  1. 4 0
      ChangeLog
  2. 8 0
      doc/chapters/api.texi

+ 4 - 0
ChangeLog

@@ -29,6 +29,10 @@ New features:
 	  allocate data correctly, and to submit the matching receive of
 	  allocate data correctly, and to submit the matching receive of
 	  the envelope.
 	  the envelope.
 
 
+Small features:
+  * Add cl_arg_free field to enable automatic free(cl_arg) on task
+    destroy.
+
 StarPU 1.1.0 (svn revision xxxx)
 StarPU 1.1.0 (svn revision xxxx)
 ==============================================
 ==============================================
 
 

+ 8 - 0
doc/chapters/api.texi

@@ -2172,6 +2172,14 @@ this case, the argument given to the codelet is therefore not the
 This field is ignored for CPU, CUDA and OpenCL codelets, where the
 This field is ignored for CPU, CUDA and OpenCL codelets, where the
 @code{cl_arg} pointer is given as such.
 @code{cl_arg} pointer is given as such.
 
 
+@item @code{unsigned cl_arg_free} (optional)
+In case @code{cl_arg} was allocated by the application through @code{malloc},
+setting @code{cl_arg_free} to 1 makes StarPU automatically call
+@code{free(cl_arg)} when destroying the task. This saves the user from
+defining a callback just for that. This is mostly useful when targetting MIC or
+SCC, where the codelet does not execute in the same memory space as the main
+thread.
+
 @item @code{void (*callback_func)(void *)} (optional) (default: @code{NULL})
 @item @code{void (*callback_func)(void *)} (optional) (default: @code{NULL})
 This is a function pointer of prototype @code{void (*f)(void *)} which
 This is a function pointer of prototype @code{void (*f)(void *)} which
 specifies a possible callback. If this pointer is non-null, the callback
 specifies a possible callback. If this pointer is non-null, the callback