opencl - clBuildProgram yields access violation (using Cloo) -


opencl 1.1, using cloo 0.9.1.0.

for cl module crash @ following line:

program.build(null, null, null, intptr.zero); 

visual studio 2010 tells me this:

an unhandled exception of type 'system.accessviolationexception' occurred in cloo.dll

additional information: attempted read or write protected memory. indication other memory corrupt.

i have trace error line of code.

int offset = 1000000 * (input == 0); // culprit! const sampler_t smp = clk_normalized_coords_false | clk_address_clamp | clk_filter_nearest; int4 pixel = read_imagei(image, smp, (int2)(offset + x, y)); 

i'm using trick above avoid branching. works in 1 situation above yields access violation @ compile-time. if remove conditional multiplication works. e.g.

int offset = 1000000; // -or- int offset = (input != 0 ? 0 : 1000000); 

am facing compiler bug here? how work around error?

some details graphics card/driver:

driver packaging version: 8.85.7.2-110901a1-125827c-fujitsu technology

solutions provider: ati technologies inc. 2d driver version: 8.01.01.1152

it's compiler bug. fixed day. now, avoid specific optimization trick.


Comments

Popular posts from this blog

java - Play! framework 2.0: How to display multiple image? -

gmail - Is there any documentation for read-only access to the Google Contacts API? -

php - Controller/JToolBar not working in Joomla 2.5 -