-
-
Notifications
You must be signed in to change notification settings - Fork 686
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
Build on aarch64 fails with NEON error #1959
Comments
Could the reason be lousy support for ARM NEON by CastXML version used? Also, all of these errors seem to pass through Eigen. Is that Eigen version new enough? It is hard to diagnose/fix this without access to machine with the said architecture. |
@dzenanz This is when building against eigen 3.3.7 and CastXML 0.3.4. |
@bradking do you have any insights? |
What is the output of |
|
Thanks. What files are present in the Also, what is the output of |
|
Thanks. It looks like I suspect that CastXML's setTriple function needs to be updated to map a preprocessor defintion to |
Should this bug report be transferred to CastXML? |
On the aarch64 machine here is what i get:
|
Yes. I opened CastXML/CastXML#179 for this. See its description for a more direct observation of the problem. |
I've fixed that CastXML issue and released CastXML 0.3.5 with the fix. |
Doesn't seem to have worked (or perhaps some other reason behind the errors?):
|
Full build log attached. |
What is the output of each of these commands? $ /usr/bin/c++ -x c++ /dev/null -v -std=c++11
$ /usr/bin/castxml -x c++ /dev/null -v --castxml-cc-gnu '(' /usr/bin/c++ -std=c++11 ')' |
Also, does |
Also contains these:
|
|
Thanks. The problem is in CastXML in this code where we try to recognize which of the simulated compiler's include directories contains its builtin headers so that we can override it with CastXML's headers for its builtin Clang. In this case,
|
I've released CastXML 0.3.6 with that fix. |
Thanks a lot. "And then there was one..."
|
Please run the commands: $ cd /home/abuild/rpmbuild/BUILD/ITK-5.1.1/build/Wrapping/Modules/ITKLabelMap
$ /usr/bin/castxml -o itkBinaryGrindPeakImageFilter.cpp -E --castxml-cc-gnu "(" /usr/bin/c++ -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -DNDEBUG -Wcast-align -Wdisabled-optimization -Wextra -Wformat=2 -Winvalid-pch -Wno-format-nonliteral -Wpointer-arith -Wshadow -Wunused -Wwrite-strings -funit-at-a-time -Wno-strict-overflow -Wno-deprecated -Wno-invalid-offsetof -Woverloaded-virtual -Wstrict-null-sentinel -std=c++11 ")" -w @/home/abuild/rpmbuild/BUILD/ITK-5.1.1/build/Wrapping/ITKLabelMap.castxml.inc /home/abuild/rpmbuild/BUILD/ITK-5.1.1/build/Wrapping/itkBinaryGrindPeakImageFilter.cxx Then attach the resulting |
Sorry, took me a while, but here it is (the output is huge, so it is attach it as a zip file). |
Sorry, forgot to mention the actual command output you requested starts at the |
Thanks. The problem is described in Eigen's code here. It relies on the code here to recognize when the compiler is Clang and uses a workaround for a problem compiling the code with Clang. However, CastXML is told by This kind of problem comes up once in a while, and is almost always a case of project code trying to work around a compiler bug. The solution is to teach Eigen's code to be aware of CastXML as any other compiler, and recognize it via // See bug 1325, clang fails to call vld1q_u64.
-#if EIGEN_COMP_CLANG
+#if EIGEN_COMP_CLANG || defined(__castxml__) |
Thanks, I have now opened https://gitlab.com/libeigen/eigen/-/issues/1979 for eigen devs to look at. |
I opened https://gitlab.com/libeigen/eigen/-/merge_requests/215 to resolve that issue in Eigen, and it has now been merged. |
@bradking I can confirm that CastXML 0.3.6 + your patch for eigen leads to successful aarch64 builds. Many thanks for fixing this. |
@badshah400 great! |
Description
Since version 5, the build on aarch64 fails with NEON errors.
4.13 was ok.
Steps to Reproduce
Try to build ITK on aarch64 and check the errors:
Expected behavior
Build should succeed.
Actual behavior
Build fails.
Reproducibility
100%
Versions
5.1.0
Environment
openSUSE Tumbleweed
Additional Information
The text was updated successfully, but these errors were encountered: