[Bf-cycles] Tests with OpenCL - Cycles

Thomas Dinges blender at dingto.org
Tue Jan 15 16:02:53 CET 2013

Hey everyone,
I played around a bit with OpenCL the past few days and want to share my 
foundings here.

1) Nvidia GT 540M:
I compiled Blender with default settings, also for OpenCL. That means 
only __KERNEL_SHADING__ and __MULTI_CLOSURE__ was enabled.

The compilation fails though: It does not like the "int segment = ~0" 

:26679:87: error: C does not support default arguments
         int shader, int object, int prim, float u, float v, float t, 
float time,  int segment = ~0)

I compiled without hair support and removed the segment parameter to 
workaround this issue.
I tested with color_ramp.blend (SVN test repository) and Mix and Add 
Shaders do not work. Only the first closure input is passed through, the 
second gets ignored.

It seems to be related to __MULTI_CLOSURE__. When I recompile the OpenCL 
kernel without it, mix and add shaders work fine.

2) Intel Core i7 2630QM
I wanted to test OpenCL on my Sandy Bridge Intel CPU, but the CPU is not 
recognized. I of course changed device_opencl.cpp and replaced all 
The issue is in the way Cycles detects OpenCL platforms as far as I can 
see that. LuxMark 2.0 recognized both devices (nvidia GPU and Intel CPU) 

I could not get it up and running, although I found that changing the 
"platform_ids[]" index from 0 to 1 in lines 757 and 762 in 
device_opencl.cpp, at least brings up the device inside of the User 
Preferences. (the nvidia card disappears then though from UserPrefs, yet 
it will still render with the GPU).

3) Intel Core i5-3570 with HD 2500 GPU
Intels Ivy Bridge CPUs now also support OpenCL on the GPU, so I wanted 
to test that.  Both devides (CPU and GPU) show up fine in User 
Preferences (after CL_DEVICE_TYPE_ALL tweak) but the kernel compile 
crashes. It starts, but after some time Blender just closes. I could not 
debug that further.

Thanks for reading this.

Brecht:  Please don't see this as a real bug report, I know OpenCL 
development is on hold but it's interesting to keep an eye on it and 
maybe some information here is helpful.

All tests done on Windows 7 x64.

Best regards,

Thomas Dinges
Blender Developer, Artist and Musician


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.blender.org/pipermail/bf-cycles/attachments/20130115/77f6344f/attachment.htm 

More information about the Bf-cycles mailing list