On Fri, Dec 18, 2009 at 6:59 PM, Andreas Klöckner
Right. You can pack a struct into a string using
Python's struct module, and
since string support the buffer protocol, they can be passed to PyCUDA
So are you saying that if I have a kernel with
__global__ go(test a)
... = a.x;
and call it with
go.prepare("s", ...) # tell PyCuda we're passing in a string buffer
go.prepared_call(grid, struct.pack("i",12345)) # pack integer into
a.x will equal 12345 in the kernel?
I don't get any error messages but I just get garbage values for a.x.