Write files from kernel write files parallely

Hi All,

May i ask, if it is possible to write data into a file through kernel?
I am now done with my iterations.
Time taken was quite impressive.
But now when i need retrieved these whole bunch of data into a file and it is taking too much time.

I wish if it is possible to write a file from kernel :).


Currently, it is impossible.

try using pinned memory, make sure you have as much pci-e lanes as possible (x16) if you have multiple jobs then you can do parallel mem copies and computation with streams. This will make your copies faster and help hide the time it takes.

How about using cuPrintf?

I have not tried this yet, but isn’t this what the cuPrintf class is for? I had to become an approved NVIDIA developer in order to get this. I have downloaded it and included it in my program, but I have not made calls yet. It is my understanding that you can designate an output file during initialization and can print to the file in device kernel functions. Of course this is all text file printing, but it is better than nothing; at least I think it is as I have not tried it yet. I am most interestied in using this as a debugging aid.

Ken Chaffin

Just my fantasy… Feel free to ignore…

If the OS supports “mmaping” file system objects into “pinned” memory - One can directly write it from kernels…that have zero-copy support…

But then, probably I am asking for more… “mmap” does support a way in which you can ask it to “map” at a known virtual address… But I dont know the repercussions of passing a NVIDIA driver allocated pointer to that… call…