-
Notifications
You must be signed in to change notification settings - Fork 1.6k
cmake: DYNAMIC_ARCH build broken on OS X #2634
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Please pull from develop, not master - the latter is almost three years out of date. There is a github action for homebrew builds in the develop tree, though it currently fails in an xcode version check after the successful build. |
This issue is about the develop version. Sorry for using the wrong word in the description. |
Oh, I see. From your log the problem seems to be not so much ZEN architecture but the essentially unimplemented "quadruple precision support, not sure why a CMAKE build would suddenly attempt this on OSX. Would you happen to have set EXPRECISION=1 or QUAD_PRECISION=1 in an environment variable like CFLAGS, perhaps in the context of a different project ? (Alos not sure what to make of the |
Can you make this go away with |
I'm trying the The |
Thanks @martin-frbg. According to above Github Actions runs, In general, could you recommend "how experimental" you would consider the cmake build to be? Is there a plan to consider it "stable" at some point? |
The problem with the cmake build is that it is a comparatively late addition where the gmake build already used some trickery (recursions and kernel configuration files that use gmake conditional syntax), and not all combinations of options will have been tested on all platforms. Your build logs seem to suggest that USE_LOCKING may not have been passed correctly, I'll check that later today. (~~Though this should be¨¨ Actually this is redundant with the USE_THREAD option you set - if you leave that out the USE_LOCKING gets applied as it should be) Not sure I understand what the "libs dependency" is that Conan is working around with their use of -DANDROID - if it is necessary in an OSX context, it could be just the "-lm" that gets added on both Linux and BSD together with the NO_EXPRECISION. |
@martin-frbg there is also another issue when building with
reference: https://github.com/leezu/OpenBLAS/runs/728422254?check_suite_focus=true |
Hmm. Wonder why that is - when the build gets there it must have confirmed that AVX512 support is available. Possibly an OSX LLVM bug ? |
@martin-frbg But why would |
No idea unless builds happened on different hardware (one Xeon so including the AVX512 "SkylakeX" kernels, the other not) |
Maybe. I added a commit #2638 to print the CPU arch. It now shows
|
Confused... but one difference appears to be that the cmake build lost the "-O2" , wonder how and when that happened (and disabling optimization for the skx sgemm kernel is sufficient to break the gmake build). |
The "-O2" was removed from system.cmake in #1279 , possibly on the premise that the "correct" way to handle this in cmake would be to specify a CMAKE_BUILD_TYPE or to set CMAKE_C_FLAGS. The default build type (with neither Debug or Release specified) seems to invoke the compiler without any optimization, which for some reason makes llvm run out of registers in the case of that one AVX512-heavy source file. |
Thank you @martin-frbg for investigating this and finding the |
Probably could not hurt (googling found lots of references to that "more registers than available" message but most seemed to be for ARM or 32bit x86). Sorry for messing up your PR BTW - at first I had actually got it wrong and thought overoptimization was causing the problem. |
Uh oh!
There was an error while loading. Please reload this page.
With latest develop, DYNAMIC_ARCH build on OS X fails with
symbol(s) not found for architecture x86_64
errors for symbols like_xtrsm_outucopy_ZEN", referenced from: _gotoblas_ZEN in libopenblas.a(setparam_ZEN.c.o)
.See for example this Github Actions log: https://github.com/leezu/OpenBLAS/runs/719019580?check_suite_focus=true
The Makefile build works https://github.com/leezu/OpenBLAS/runs/719019582?check_suite_focus=true
Besides this bug, would it be sensible to enable Github Actions CI for OpenBLAS repo? I'm happy to open a PR with an slightly extended version of leezu@560c39d used to produce above log.
The text was updated successfully, but these errors were encountered: