I'm having a problem compiling my CL code. The whole code is too big to post it here but my experiments narrowed it all down to a rather ridiculous situation.
I have some pixels being processed in a global buffer (each pixel being an uint). Whenever I want to write a pixel to that buffer I call a function
void Write(__global uint *where, uint value)
{
*where = value;
}
When I call clBuildProgram() it just never exits.
Now, the funny part. If I replace this function's body with
*where = 0;
clBuildProgram() returns with success.
The only possibility I can think about is that CL compiler builds some kind of data-dependency graph which it then processes incorrectly (falling into infinite loop or maybe just exponential time).
Anyone have ideas?
Additional info:
1. My card is HD 4800. I'm using latest drivers and 2.2 Stream SDK.
2. I can provide full code if this helps.
3. I've also had various misterious crashes while investigating.