cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

shunyo
Journeyman III

AMD CodeXL GPU profiling

Hi,

I am trying to profile my application using CodeXL and have been receiving warnings showing Memory leaks in different positions where I cannot see any memory leak happening. I am receiving messages like this:

Memory leak detected [Ref = 1, Handle = 0x000000000467D7B0]: Object created by clCreateCommandQueue

This is the code for creating command queue:

commands = clCreateCommandQueue(context, device_id, CL_QUEUE_PROFILING_ENABLE, &err);

I am receiving similar messages for clCreateProgramWithSource, clEnqueueNDRangeKernel, clEnqueueWriteBuffer etc.

I would like to ask what might be the source of the warning or if I have to change any function call.

0 Likes
1 Solution

Hi,

Do you use AMD APP SDK utils files?  if yes, there is a known issue and will be fixed in upcoming release.

Do you use events in the clEnqueueWriteBuffer and ClEnqueueNDRangeKernel API calls? If yes, don't forget to release all them.

Regards,

Ravi

View solution in original post

0 Likes
4 Replies
nibal
Challenger

Hi,

Do you use clReleaseCommandQueue? It will flush any remaining commands from the Q. If you still have commands left in Q when you finish, they may register as memory leaks.

Yes I have. If that is true, how can the same be said for clEnqueueWriteBuffer and ClEnqueueNDRangeKernel?

0 Likes

Hi,

Do you use AMD APP SDK utils files?  if yes, there is a known issue and will be fixed in upcoming release.

Do you use events in the clEnqueueWriteBuffer and ClEnqueueNDRangeKernel API calls? If yes, don't forget to release all them.

Regards,

Ravi

0 Likes

Yes, I do use the AMD APP SDK files.

I used NULL throughout. I have used events and then released them to find that the warnings go away. Thanks.

0 Likes