This was pretty hairy to debug, but I tracked it down: In [14]: np.dtype(np.uintp) Out[14]: dtype('uint32')
In [15]: np.dtype(np.uintp) == np.dtype(np.uint32) Out[15]: True In [17]: hash(np.dtype(np.uintp)) Out[17]: 1198097502 In [18]: hash(np.dtype(np.uint32)) Out[18]: -98813048 I encountered the problem when using gpuarray.arange which causes one argument to be set to uintp in the following line elementwise.py:144: arguments.append(ScalarArg(np.uintp, "n")) Can anyone test if this replicates with his numpy (mine is 1.6.1)? Thomas On Fri, Dec 30, 2011 at 9:36 PM, Andreas Kloeckner <li...@informa.tiker.net> wrote: > On Fri, 30 Dec 2011 20:03:44 +0100, Thomas Wiecki <thomas_wie...@brown.edu> > wrote: >> Hi Andreas, >> >> glad to see that you followed up on this issue. I will try to boil it >> down but noticed that when I was investigating the issue back then I >> could not easily reproduce the problem. For some reason the dict >> stored dtype was hashing to something else. Can you easily point me to >> the place where the dict is created? > > Sure. > > - Initial fill in pycuda.compyte.dtype._fill_dtype_registry(). > - Vector types added in pycuda.gpuarray._create_vector_types(). > > Andreas > > PS: Please make sure to keep the list cc'd. _______________________________________________ PyCUDA mailing list PyCUDA@tiker.net http://lists.tiker.net/listinfo/pycuda