Accéder au contenu.
Menu Sympa

starpu-devel - Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock()

Objet : Developers list for StarPU

Archives de la liste

Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock()


Chronologique Discussions 
  • From: Samuel Thibault <samuel.thibault@ens-lyon.org>
  • To: Jonathan Adamczewski <jadamcze@utas.edu.au>
  • Cc: starpu-devel@lists.gforge.inria.fr
  • Subject: Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock()
  • Date: Wed, 27 Apr 2011 18:00:33 +0200
  • List-archive: <http://lists.gforge.inria.fr/pipermail/starpu-devel>
  • List-id: "Developers list. For discussion of new features, code changes, etc." <starpu-devel.lists.gforge.inria.fr>

Hello,

Jonathan Adamczewski, le Sat 16 Apr 2011 09:44:49 +0200, a écrit :
> clSetKernelArg(kernel, i, STARPU_VARIABLE_GET_ELEMSIZE(buffer[i]),
> &STARPU_VARIABLE_GET_PTR(buffer[i]));

Err, this should be

clSetKernelArg(kernel, i, sizeof(cl_mem),
&STARPU_VARIABLE_GET_PTR(buffer[i]));

as what clSetKernelArg expects is not the size of the buffer, but the
size of the pointer. You need to pass

STARPU_VARIABLE_GET_ELEMSIZE(buffer[i]),

separately as another kernel parameter.

> Unregistering the second variable causes an assert to fail in
> _starpu_spin_unlock() - the assert checking the return value of
> pthread_spin_unlock() fails. According to gdb, lock->lock contains the
> value
> 0xfeeefeee, which looks rather suspicious.

Indeed. I guess valgrind is not of much help here.

Samuel





Archives gérées par MHonArc 2.6.19+.

Haut de le page