-
Notifications
You must be signed in to change notification settings - Fork 75
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
Enabling ARM64 CI #430
Enabling ARM64 CI #430
Conversation
#134 * Moving CircleCI from old 1.x config style (`./circle.yml`) to the newer 2.x style (`./.circleci/config.yml`). * Adding a 2nd job to the existing CircleCI config (Darwin), to try and build an ARM64 Docker build. * Updates to Dockerfile for `nupic.cpp` instead of older `nupic.core`. With these changes (so far), one can start a local CircleCI build of NuPIC Docker on ARM64. We get to our first error (which seems like the kind of error I'd expect going from `x86_64` -> `arm64`. I have no idea what to do with it, though: ``` [ 63%] Building CXX object src/test/CMakeFiles/unit_tests.dir/unit/ntypes/BasicTypeTest.cpp.o /usr/local/src/nupic.cpp/src/test/unit/ntypes/BasicTypeTest.cpp:115:49: error: narrowing conversion of '-128' from 'int' to 'nupic::Byte {aka char}' inside { } [-Wnarrowing] Byte bufByte[8] = {0, 1, 2, 3, 4, 5, -128, 127}; ^ src/test/CMakeFiles/unit_tests.dir/build.make:521: recipe for target 'src/test/CMakeFiles/unit_tests.dir/unit/ntypes/BasicTypeTest.cpp.o' failed make[2]: *** [src/test/CMakeFiles/unit_tests.dir/unit/ntypes/BasicTypeTest.cpp.o] Error 1 CMakeFiles/Makefile2:436: recipe for target 'src/test/CMakeFiles/unit_tests.dir/all' failed make[1]: *** [src/test/CMakeFiles/unit_tests.dir/all] Error 2 Makefile:151: recipe for target 'all' failed make: *** [all] Error 2 setup.py: Calling /usr/local/src/nupic.cpp/bindings/py/packaging/setup.py ```
@breznak I'm not seeing any settings from the CircleCI UI or Config for this, but it appears we can just force a success exit code in the script? |
numpy and boost are slooow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @brev , this is a great contribution! 💯 I'll be very happy to see ARM64 officially working!
- seems the "make arm64 CI jobs ok-to-fail until fixed" problem is fine, as CircleCI is smart enough and runs the checks as separate jobs, so you can see OSX is still required, while ARM is not 👌
- there's a weird problem saying for our OSX job that it does not run with comment "Please select OSX plan". I don't know why this PR would cause it? Maybe the change to v2 format. If you are unaware of the problem/fix as well, I'll have to email their support, they were really responsive and helpful. I've mailed them to enable OSX for us for free, as is their offering for open-source, maybe the system just changed with the move to v2.
So the only issue is the OSX not running, which I'll also try to resolve by mailing support.
- run: $CI_SUDO docker run --rm --privileged multiarch/qemu-user-static:register --reset | ||
- run: | ||
command: $CI_SUDO docker build --build-arg arch=arm64 . | ||
no_output_timeout: 2h |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
question, how long to the tests (on CI in docker...) take to run?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@breznak arm64 is 1 hour 45 min, mac is 25 min.
ran against this extention library. If you are porting your code to this codebase, please review [API Changelog](API_CHANGELOG.md). | ||
|
||
### New Features | ||
### New Features |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok now, but for the future please fix your editor to avoid these "automated" whitespace changes. It makes the review more difficult.
|
||
# Multiarch Ubuntu Bionic 18.04. arches: x86_64, arm64, etc. | ||
# https://hub.docker.com/r/multiarch/ubuntu-core/tags/ | ||
FROM multiarch/ubuntu-core:$arch-bionic | ||
|
||
RUN apt-get update && \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please try if this works without the update, only install? As after updating, much more packages will be rebuilt and it takes much longer.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
update is needed, some packages are no longer downloadable otherwise. This is a bummber, would have been faster to use just what is in the docker img.
For some reason this PR kept running in Brev's CI, and not under htm-community (we have open-source deal with CircleCI to allow us run OSX CI for free 👍 ) |
I've merged this great contribution from @brev 👏 that:
Thank you!! 👍 |
Very good. Thanks @brev |
Enabling ARM64 CI
Enabling ARM64 CI on CircleCI using Docker + QEMU.
TODO
workflow config too? researching.can we mark a job/platform(this arm64) in circle to "be able to fail"? (per @breznak)Changes
Local Test
Context