cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

blelump
Journeyman III

[Brook+] a question realted to GPU memory

I have a question,

Is the input data of such kernel: kernel void mul(int width, double2 A[][], double2 B[][], out double2 result<> always destroyed (on GPU memory) after every invocation of that kernel or only when destroy the Stream object?

In my particular case I need call that kernel, say 20000x times and only data of "B" changes, "A" is always the same and that is why I am asking. Copying 20000x data of "A" within host memory and GPU memory is a waste of time in this case.

thanks in advance for the reply.

 

0 Likes
5 Replies
gaurav_garg
Adept I

Only when destroy the stream, streams are persistent across kernel calls.

0 Likes

Originally posted by: gaurav.garg Only when destroy the stream, streams are persistent across kernel calls.

 

 

thank you

0 Likes

Originally posted by: gaurav.garg Only when destroy the stream, streams are persistent across kernel calls.

 

how to destroy a stream?

the application finished(not destroy the stream), run the application again, find the above running affected the current running.

 

0 Likes

Streams behave like any C++ object, when stream variable goes out of scope, it is destroyed.

0 Likes

Hi. I have a related question. I find that if I create and destroy large streams of increasing size in quick succession, the driver crashes and the OS (Vista SP2) blue-screens. It seems that GPU memory is not deallocated immediately when a stream is destroyed. Is this correct? When is GPU memory deallocated?

0 Likes