[PyCUDA] printf
Bergtholdt, Martin
martin.bergtholdt at philips.com
Fri Mar 25 11:07:42 PDT 2011
Tesla 2070C
From: Bryan Catanzaro [mailto:bryan.catanzaro at gmail.com]
Sent: 25 March 2011 19:07
To: Bergtholdt, Martin
Cc: pycuda at tiker.net
Subject: Re: [PyCUDA] printf
What device are you running this on?
- bryan
On Mar 25, 2011, at 11:05 AM, "Bergtholdt, Martin" <martin.bergtholdt at philips.com<mailto:martin.bergtholdt at philips.com>> wrote:
Hi,
I'm trying to run the printf example in the wiki:
>>> import pycuda.driver as cuda
>>> import pycuda.autoinit
>>> from pycuda.compiler import SourceModule
>>>
>>> mod = SourceModule("""
... #include <stdio.h>
...
... __global__ void say_hi()
... {
... printf("I am %d.%d\\n", threadIdx.x, threadIdx.y);
... }
... """)
>>>
>>> func = mod.get_function("say_hi")
>>> func(block=(4,4,1))
>>>
Everything works fine, but I do not get any output on the last line. Any ideas what can go wrong here?
Cuda 3.2
Windows-7
pycuda.VERSION (2011, 1)
MSVC 9.0 2008 (32-bit)
________________________________
The information contained in this message may be confidential and legally protected under applicable law. The message is intended solely for the addressee(s). If you are not the intended recipient, you are hereby notified that any use, forwarding, dissemination, or reproduction of this message is strictly prohibited and may be unlawful. If you are not the intended recipient, please contact the sender by return e-mail and destroy all copies of the original message.
_______________________________________________
PyCUDA mailing list
PyCUDA at tiker.net<mailto:PyCUDA at tiker.net>
http://lists.tiker.net/listinfo/pycuda
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.tiker.net/pipermail/pycuda/attachments/20110325/91832fc8/attachment.html>
More information about the PyCUDA
mailing list