- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Please help on this opencl issue:
I have a kernel program file that runs fine on AMD and NVidia graphics cards, as well as on Intel CPUs. But when trying to build on Intel 630 graphics card, I got the following message:
error: undefined reference to `_Z5clampDv2_ddd()'
error: backend compiler failed build.
I am pretty sure this is related to calls to clamp(double2, double,double).
when I change the above call to clamp(double, double, double) and try to build the kernels again, the program simply clashes (from igc64.dll) and no exception can be caught to investigate the cause of the crash.
Any insight into this issue is welcome and is greatly appreciated.
Thanks,
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for this report. This may be a bug. However, to process it we will need a kernel which shows this behavior. If you can make a simple example you don't mind sharing you can attach it in this forum. Otherwise, please feel free to contact us with a private message. You can do this with "send author a message" which you can see in the same line as my name above this reply.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Jeffrey,
Thanks for replying.
I agree with you that this may be a bug. This is simple demonstrated: just a one function call in ANY kernel to clamp(double2, double, double) will give you the error message. Changing the call to clamp(float2, float, float) will work (of course that would not be what I wanted). Changing the call to two separate clamp(double, double, double) will also work.
After some experimenting, I found that the crashing was related to the length of the program file (mine is >76KB single file). If I truncate the content of the file (with disregard to functionality and correctness) to certain length, the compile and link with code-builder will be successful. Any one extra line of code will make code-builder report error logging to file, with the file path apparently wrong (sometimes the directory separator becomes "/" on windows 10 in stead of "\"). It seems as if some fixed length buffer boundary is exceeded in igc64.dll.
Another interesting phenomenon is with code-builder if you use a function call to pow(double,double) it will succeed in building kernels, but report error on disassembly of SPIRV and the ".txtspirv" file will not be created.
I will try to make my program files into separate smaller ones and link them in the end. I have just begun to use code-builder. I find it handy. But have not figured out how to load multiple program files into one session yet. Could you direct me on how that can be done.
regards,
Liang
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Jeffrey,
Here is a simple kernel form the Intel kernel template, in which I inserted the bug test section:
const int id = y * width + x;
This kernel program will compile but will result in build error "error: undefined reference to `_Z5clampDv2_ddd()'".
If you comment out the line with "a = clamp(a, -b, b);" you will get "Failed to disassemble SPIR-V output file: error: 203: End of input reached while decoding OpExtInst starting at word 196: expected more operands after 7 words."
On another note, the Intel(R) HD Graphics 630 device disappeared with the Intel(R) OpenCL platform from my ordinary OpenCL inquiry process (using clGetPlatformIDs), but they still appear in Code-Builder environment. Do you have any idea what might have caused this phenomenon and how to get them back?
thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
OK, the cause of the Intel(R) OpenCL platform and HD Graphics 630 device disappearing was the installation of Intel OpenCL SDK, which enabled the CPU only platform and disabled the normal Intel(R) OpenCL platform. After uninstalling the Intel OpenCL SDK, Intel(R) OpenCL platform and HD Graphics 630 device both reappeared again. This should not be normal I suppose.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page