MacOS OpenCL issue
Issue #24
closed
I'm using a MacBook Pro 13" mid '17 with the 3.1 GHz i5 and integrated graphics. Fractorium refuses to use OpenCL. It's supported on the CPU and GPU per https://stackoverflow.com/questions/7892955/how-can-i-test-for-opencl-compability:
$ clang -framework OpenCL cl.c -o cl
ld: warning: text-based stub file /System/Library/Frameworks//OpenCL.framework/OpenCL.tbd and library file /System/Library/Frameworks//OpenCL.framework/OpenCL are out of sync. Falling back to library file for linking.
$ ./cl
Device Intel(R) Core(TM) i5-7267U CPU @ 3.10GHz supports OpenCL 1.2
Device Intel(R) Iris(TM) Graphics 650 supports OpenCL 1.2
Here's the log:
Init()
Intel Inc. Intel(R) Iris(TM) Graphics 650
Platform: 0, device: 1, error:
failed to init log scale program
<program source>:110:48: error: call to '__fast_relax_log' is ambiguous
real_bucket_t logScale = (logFilter->m_K1 * log(1.0 + histogram[index].w * logFilter->m_K2)) / histogram[index].w;
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:4655:22: note: expanded from macro 'log'
#define log(__x) __fast_relax_log(__x)
^~~~~~~~~~~~~~~~
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:4653:30: note: candidate function
__CLFN_FD_1FD_FAST_RELAX(__fast_relax_log, native_log, __cl_log);
^
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:417:27: note: expanded from macro '__CLFN_FD_1FD_FAST_RELAX'
inline float __OVERLOAD__ _name(float x) { return _default_name(x); } \
^
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:4653:30: note: candidate function
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:418:28: note: expanded from macro '__CLFN_FD_1FD_FAST_RELAX'
inline float2 __OVERLOAD__ _name(float2 x) { return _default_name(x); } \
^
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:4653:30: note: candidate function
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:419:28: note: expanded from macro '__CLFN_FD_1FD_FAST_RELAX'
inline float3 __OVERLOAD__ _name(float3 x) { return _default_name(x); } \
^
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:4653:30: note: candidate function
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:420:28: note: expanded from macro '__CLFN_FD_1FD_FAST_RELAX'
inline float4 __OVERLOAD__ _name(float4 x) { return _default_name(x); } \
^
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:4653:30: note: candidate function
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:421:28: note: expanded from macro '__CLFN_FD_1FD_FAST_RELAX'
inline float8 __OVERLOAD__ _name(float8 x) { return _default_name(x); } \
^
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:4653:30: note: candidate function
/System/Library/PrivateFrameworks/GPUCompiler.framework/Versions/A/lib/clang/3.5/include/cl_kernel.h:422:29: note: expanded from macro '__CLFN_FD_1FD_FAST_RELAX'
inline float16 __OVERLOAD__ _name(float16 x){ return _default_name(x); }
^
ERROR: Program build failure in cl::Program::build().
Error initializing OpenCL renderer, using CPU renderer instead.
Here's a screen recording: https://youtu.be/UXWW6CkfxRA
Comments (6)
-
repo owner -
Account Deleted reporter Installer; no nvidia or amd - it's the 13" model
-
repo owner Ok cool, the fix will be in the next release. Hopefully it won't take me too long, I only have a few more features to add before I'm done. Sit tight!
-
repo owner This has been fixed in the latest release, 1.0.0.16 and is mentioned in the bug fixes section:
https://www.deviantart.com/mfeemster/journal/Fractorium-1-0-0-16-Released-800491038
Closing this issue. Thanks for bringing it to my attention.
-
repo owner - changed status to resolved
-
repo owner - changed status to closed
- Log in to comment
Ok, thanks for the log dump. That's a simple kernel compilation bug where it can't tell if the value being passed to log is a float or double. I aim to have a new release available within a month or so and I'll include a fix for this in it.
Are you building from source at all? Or just using the installer?
Also, I watched your video. Just for reference I do not support Intel graphics. So if it works there, good, but if not, I don't really support it because I don't have hardware to test on.
That said, it seems you are trying to run in dual gpu mode by selecting both cards. I would advise running with only the Iris card.
btw, does that mac not have an nvidia or amd card in it? Those are the vendors I have tested on and support.