Hi,
I have a crash with the following exception:
This is the sourcecode of the cuda file (edit: cpp file see below):
#include <optix_world.h>
struct BiDirSubPathVertex {bool existing;};
using namespace optix;
rtCallableProgram(void, sampleLightPath, ());
rtCallableProgram(void, sampleEye, ());
rtDeclareVariable(uint2, launch_index, rtLaunchIndex, );
rtBuffer<float4, 2> output_buffer;
RT_CALLABLE_PROGRAM void sampleLightPath_f() {}
RT_CALLABLE_PROGRAM void sampleEye_f() {}
RT_PROGRAM void pathtrace_camera() {
BiDirSubPathVertex lightVertices[2];
lightVertices[0].existing = false;
lightVertices[1].existing = false;
for(unsigned int i=0; i<2; i++) {
sampleLightPath();
if(!(lightVertices[i].existing)) break;
}
// rtPrintf("cztery\n");
sampleEye();
output_buffer[launch_index] = make_float4(1.f, 1.f, 1.f, 1.f);
}
RT_PROGRAM void exception()
{
rtPrintExceptionDetails();
output_buffer[launch_index] = make_float4(1.f, 1.f, 0.f, 0.0f);
}
You see the rtPrintf? if the comment signs are removed, the program doesn’t crash. So while the crash is simple to work around in this specific place, it would be hard if the print is not already there.
The original code file was about 700 lines long, the functions had parameters and traced rays. While removing more and more code, it always depended only on this one rtPrintf whether it crashed or not. In the original code I had exceptions and printing enabled, but it didn’t make any difference.
I verified the crash on Win7 64 (vs12 compiler, nvidia driver around 336 whql) and OpenSuse Linux 13.1 64 (gcc 4.8, nvidia driver 331.49), both systems had Cuda 5.5 and Optix 3.5 installed. the workstation has an AMD quadcore and a GeForce GTX 550Ti.
edit:
additionally verified on a Win7 64bit, vs12 compiler, nvidia driver 332.76, cuda 5.0 and Optix 3.0. the workstation has a intel xeon quad core and quadro 2000 graphics.<<
minimal example: http://xibo.at/meine/optixCrashBugPrintMinimalExample.zip new file with less code
It’s based on sutil, the same build steps as in the optix examples are necessary.
Is anybody able to reproduce?
thanks,
adam