Add ARM32/ARM64 CI #930

pull sipa wants to merge 2 commits into bitcoin-core:master from sipa:202104_armci changing 2 files +49 −0
  1. sipa commented at 7:49 pm on May 2, 2021: contributor
  2. sipa force-pushed on May 2, 2021
  3. sipa force-pushed on May 2, 2021
  4. sipa force-pushed on May 2, 2021
  5. sipa cross-referenced this on May 2, 2021 from issue Arm ASM builds are broken by gmaxwell
  6. sipa force-pushed on May 2, 2021
  7. sipa force-pushed on May 2, 2021
  8. sipa force-pushed on May 2, 2021
  9. in .cirrus.yml:222 in 541269f65a outdated
    217+    - env: {}
    218+    - env: {ASM: arm}
    219+  << : *MERGE_BASE
    220+  test_script:
    221+    # https://sourceware.org/bugzilla/show_bug.cgi?id=27008
    222+    - rm /etc/ld.so.cache
    


    real-or-random commented at 9:32 am on May 3, 2021:
    I don’t think we need these lines. This is really only an issue when using qemu with a different endianness, so this affects us only on s390x.

    sipa commented at 7:04 pm on May 3, 2021:
    Done, let’s see.
  10. real-or-random approved
  11. real-or-random commented at 9:33 am on May 3, 2021: contributor
    ACK mod nit
  12. real-or-random commented at 9:52 am on May 3, 2021: contributor

    Wait, the expectation was probably that this should break due to #931.

    I think this is related to the “shortcut” in configure.ac that simply uses the native toolchain to build gen_context when we’re not cross-compiling. In this case, we are cross compiling, so we don’t take that shortcut.

    I’ll have a look.

  13. real-or-random commented at 12:39 pm on May 3, 2021: contributor

    Wait, the expectation was probably that this should break due to #931.

    I think this is related to the “shortcut” in configure.ac that simply uses the native toolchain to build gen_context when we’re not cross-compiling. In this case, we are cross compiling, so we don’t take that shortcut.

    I’ll have a look.

    Ok I think I was a little confused when I wrote that. The issue #931 appears when compiling gen_context for the build machine. On CI, we cross-compile for ARM, so building gen_context for the CI machine is never an issue.

    I think no simple CI test could test for the breakage in #931. We could of course cross-compile gen_context and then run it on qemu.

    One possible way to do so without fiddling around with the build system would be to rely on binfmt_misc, a kernel feature which allows you to run commands like ./cmd which then will be automatically wrapped, e.g., by qemu or wine. (This is why my machine will build and run gen_context.exe when cross-compiling for mingw…) But I heard binfmt_misc has some issues with Docker.

    Another possible way is to simply add a CI job that manually cross-compiles gen_context for ARM and runs it on qemu. But this doesn’t really test if the autoconf build works.

    So I’m not convinced that testing this on CI is worth the hassle.

    Anyway, my ACK on this PR is still valid.

  14. sipa commented at 12:58 pm on May 3, 2021: contributor

    Indeed, I realized too late that #931 was in fact related to the build environment for gen_context rather than the ARM asm per se.

    Still, these are very useful CI targets I think.

  15. real-or-random commented at 1:08 pm on May 3, 2021: contributor

    Still, these are very useful CI targets I think.

    For sure, and this fixes #598.

    edit: By the way, I’m happy to see that it really wasn’t a lot of work to add this build and the mingw build. So it seems that the general structure of the CI is pretty portable and adding qemu buils is simply a matter of installing the right Debian packages and passing the right HOST.

  16. gmaxwell commented at 1:56 pm on May 3, 2021: contributor
    if this supports a full docker environment could we just run qemu-system and run a whole emulated distribution? :P That said, having a cross compile to arm test is really really good too.
  17. Add ARM32/ARM64 CI 7d65ed5214
  18. Add asm build to ARM32 CI 8bbad7a18e
  19. sipa force-pushed on May 3, 2021
  20. sipa commented at 7:05 pm on May 3, 2021: contributor
    @gmaxwell I think that’s an option, but something I’d like to keep for later.
  21. real-or-random approved
  22. real-or-random commented at 10:38 am on May 5, 2021: contributor
    ACK 8bbad7a18e5dc5054b27ae44ea0c8dffe050f6bf CI output looks fine
  23. jonasnick commented at 7:30 pm on May 13, 2021: contributor
    ACK 8bbad7a18e5dc5054b27ae44ea0c8dffe050f6bf
  24. jonasnick merged this on May 13, 2021
  25. jonasnick closed this on May 13, 2021

  26. real-or-random cross-referenced this on Jun 10, 2021 from issue Add arm8 tests to the testing configuration. by gmaxwell
  27. real-or-random cross-referenced this on Dec 20, 2021 from issue Travis should build and test arm asm by gmaxwell

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin-core/secp256k1. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-12-22 16:15 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me