memo / ofxMSAOpenCL

C++ openFrameworks addon for very simple to use wrapper for OpenCL. All underlying openCL objects are accessible to allow advanced features too if need be
http://www.memo.tv/ofxmsaopencl/
Other
88 stars 35 forks source link

clEnqueueNDRangeKernel returns CL_INVALID_COMMAND_QUEUE #1

Open mattbilson opened 11 years ago

mattbilson commented 11 years ago

Have been trying to run the particle example, and have run in to an issue with the command queue.

The line below sets err to CL_INVALID_COMMAND_QUEUE, rather than CL_SUCCESS

err = clEnqueueNDRangeKernel(pOpenCL->getQueue(), clKernel, numDimensions, NULL, globalSize, localSize, 0, NULL, NULL);
assert(err == CL_SUCCESS);

The console output is this :

[verbose] OpenCL::loadProgramFromFile
[verbose] OpenCLProgram::OpenCLProgram
[verbose] OpenCLProgram::loadFromFile MSAOpenCL/Particle.cl, isBinary: 0
[verbose] OpenCLProgram::loadFromSource 
[verbose] OpenCL::loadKernel updateParticle, 0
[verbose] OpenCLProgram::loadKernel updateParticle
[verbose] OpenCLKernel::OpenCLKernel 3931920, updateParticle
[verbose] OpenCLBuffer::initBuffer
[verbose] OpenCLMemoryObject::memoryObjectInit
[verbose] OpenCLBuffer::initFromGLObject
[verbose] OpenCLMemoryObject::memoryObjectInit
Assertion failed: (err == CL_SUCCESS), function run, file /Users/mattbilson/Development/workspace/openframeworks/of_v0072_osx_release/apps/gl/msaOpenClExample-particles/../../../addons/ofxMSAOpenCL/src/MSAOpenCLKernel.cpp, line 37.

Hardware information log below in case that is useful

[verbose] OpenCL::setupFromOpenGL 
[verbose] 2 devices found

[verbose] 

*********
OpenCL Device information:
 vendorName..................NVIDIA
 deviceName..................GeForce 9600M GT
 driverVersion...............CLH 1.0
 deviceVersion...............OpenCL 1.0 
 maxComputeUnits.............4
 maxWorkItemDimensions.......3
 maxWorkItemSizes[0].........512
 maxWorkGroupSize............512
 maxClockFrequency...........1250
 maxMemAllocSize.............128.000 MB
 imageSupport................YES
 maxReadImageArgs............128
 maxWriteImageArgs...........8
 image2dMaxWidth.............4096
 image2dMaxHeight............4096
 image3dMaxWidth.............2048
 image3dMaxHeight............2048
 image3dMaxDepth.............2048
 maxSamplers.................16
 maxParameterSize............4352
 globalMemCacheSize..........0.000 MB
 globalMemSize...............256.000 MB
 maxConstantBufferSize.......64.000 KB
 maxConstantArgs.............9
 localMemSize................16.000 KB
 errorCorrectionSupport......NO
 profilingTimerResolution....1000
 endianLittle................1
 profile.....................FULL_PROFILE
 extensions..................cl_APPLE_SetMemObjectDestructor cl_APPLE_ContextLoggingFunctions cl_APPLE_clut cl_APPLE_query_kernel_names cl_APPLE_gl_sharing cl_khr_gl_event cl_khr_byte_addressable_store cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics 
*********
mattbilson commented 11 years ago

This is using of_v0072_osx_release

pach commented 11 years ago

Got exactly the same issue on my MBP which is running 10.8 and a GT330M. I'm quite sure it was working on the same MBP under 10.7 and the old OF last year. it's working on another friend MBP which is under 10.8.2 and a Radeon HD6750. it's also working on my macPro which is 10.7 and has two Radeon (HD5870 and X1900XT)