Objet : Developers list for StarPU
Archives de la liste
- From: Jonathan Adamczewski <jadamcze@utas.edu.au>
- To: starpu-devel@lists.gforge.inria.fr
- Subject: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock()
- Date: Sat, 16 Apr 2011 17:44:36 +1000
- 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>
I have been unable to extract a simple test case for this - I'll explain as
best as I can. I'm using svn trunk and using OpenCL only under WinXP.
I have a function that registers an array of variables through a loop like :
starpu_data_handle *data_handles = [allocated chunk of memory];
uintptr_t varsint = (uintptr_t)[address of vars];
for(unsigned int i = 0; i < argnumber; ++i) { // argnumber = 2
starpu_variable_data_register(&data_handles[i], 0, varsint, var_size);
vars += var_size; // var_size = 4
}
These are later added to a task struct:
for(unsigned int i = 0; i < argnumber; ++i) { // argnumber = 2
task->buffers[i].handle = data_handles[i];
task->buffers[i].mode = STARPU_RW;
}
The task is submitted, and the args are set for the cl kernel in the set
OpenCL function:
for(unsigned int i = 0; i < argnumber; ++i) { // argnumber = 2
clSetKernelArg(kernel, i, STARPU_VARIABLE_GET_ELEMSIZE(buffer[i]),
&STARPU_VARIABLE_GET_PTR(buffer[i]));
}
The kernel runs and I attempt to unregister the variables to have their
changed values copied back to the local buffer:
for(unsigned int i = 0; i < argnumber; ++i) { // argnumber = 2
starpu_data_unregister(data_handles[i]);
}
The first variable is unregistered without problem - I see the correct result
in memory.
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.
Suggestions of things to consider or check for would be appreciated, thanks.
Jonathan.
- [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock(), Jonathan Adamczewski, 16/04/2011
- Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock(), Jonathan Adamczewski, 16/04/2011
- <Suite(s) possible(s)>
- Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock(), Samuel Thibault, 27/04/2011
- Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock(), Jonathan Adamczewski, 28/04/2011
- Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock(), Samuel Thibault, 28/04/2011
- Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock(), Jonathan Adamczewski, 28/04/2011
- Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock(), Samuel Thibault, 28/04/2011
- Re: [Starpu-devel] starpu_data_unregister() failing at pthread_spin_unlock(), Jonathan Adamczewski, 28/04/2011
Archives gérées par MHonArc 2.6.19+.