<div dir="ltr">Thank you, I have rewrite my program in C++ and no memory leak again.</div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Nov 12, 2014 at 3:21 AM, Rebecca N. Palmer <span dir="ltr"><<a href="mailto:rebecca_palmer@zoho.com" target="_blank">rebecca_palmer@zoho.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><a href="https://bugs.launchpad.net/ubuntu/+source/pyopencl/+bug/1354086" target="_blank">https://bugs.launchpad.net/<u></u>ubuntu/+source/pyopencl/+bug/<u></u>1354086</a><br>
<br>
It may help to wait for one run of the kernel to finish before starting the next: for me, repeated pyopencl.enqueue_copy(cq0,bCL.<u></u>data,aCL.data) leaks memory (sometimes ending in a crash, sometimes a whole-system hang) but repeated pyopencl.enqueue_copy(cq0,bCL.<u></u>data,aCL.data).wait() doesn't.<br>
<br>
Also note that frequently creating and deleting objects may be slow (compared to reusing existing ones) even when it doesn't crash.<br>
<br>
</blockquote></div><br></div>