title: clBuildProgram failed with error code -11 and without build log
body: <p>I have worked little bit in OpenCL now but recently "clBuildProgram" failed in one of my program. My code excerpt is below:</p>
  
  <pre><code>cl_program program;
  program = clCreateProgramWithSource(context, 1, (const char**) &amp;kernel_string, NULL, &amp;err);
  if(err != CL_SUCCESS)
  {
  cout&lt;&lt;"Unable to create Program Object. Error code = "&lt;&lt;err&lt;&lt;endl;
  exit(1);
  }
  if(clBuildProgram(program, 0, NULL, NULL, NULL, NULL) != CL_SUCCESS)
  {
  cout&lt;&lt;"Program Build failed\n";
  size_t length;
  char buffer[2048];
  clGetProgramBuildInfo(program, device_id[0], CL_PROGRAM_BUILD_LOG, sizeof(buffer), buffer, &amp;length);
  cout&lt;&lt;"--- Build log ---\n "&lt;&lt;buffer&lt;&lt;endl;
  exit(1);
  }
  </code></pre>
  
  <p>Normally earlier I got syntax or other errors inside kernel file here with the help of "clGetProgramBuildInfo()" function whenever "clBuildProgram" Failed but when this program runs, on console it only prints:</p>
  
  <p>Program Build failed
  --- Build log ---
  </p>
  
  <p>And when I tried to print the error code returned by "clBuildProgram"; it is "-11"......
  What can be the problem with my kernel file that I dont get any build fail information ?</p>