Skip to content

Build with ARMv7 instead of ARMv6 in Ruby and Rust

Stan Hu requested to merge sh-require-armv7 into master

As mentioned in https://github.com/rust-lang/rust/issues/60605#issuecomment-491987866, requiring ARMv7 works around a bug in LLVM that causes an infinite loop when the deprecated CP15 barrier instructions are emulated in software. ARMv7 introduced the equivalent DMB instruction.

This means that really old platforms such as Raspberry Pi 1, Raspberry Pi Zero, etc. will no longer work, but Raspberry Pi 4 (ARMv8) has been documented as the minimum requirement in https://docs.gitlab.com/omnibus/settings/rpi.html.

Note that the Go, nodejs, and other ARMv6 binaries are still used since they are compatible with ARMv7.

Bump to Rust v1.73.0 now that the infinite loop issue is not an issue with ARMv7.

Links

Testing

$ docker inspect registry.gitlab.com/gitlab-org/gitlab-omnibus-builder/staging/rpi_11:sh-require-armv7 | grep -A 1 Architecture
        "Architecture": "arm",
        "Variant": "v7",

Test on a Raspberry Pi 4 8GB on Mythic Beasts (https://www.mythic-beasts.com):

root@rpi-buster-armhf:~# uname -a
Linux rpi-buster-armhf 5.10.63-v7l+ #1496 SMP Wed Dec 1 15:58:56 GMT 2021 armv7l GNU/Linux
root@rpi-buster-armhf:~# cat /proc/cpuinfo
processor       : 0
model name      : ARMv7 Processor rev 3 (v7l)
BogoMIPS        : 108.00
Features        : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x0
CPU part        : 0xd08
CPU revision    : 3

processor       : 1
model name      : ARMv7 Processor rev 3 (v7l)
BogoMIPS        : 108.00
Features        : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x0
CPU part        : 0xd08
CPU revision    : 3

processor       : 2
model name      : ARMv7 Processor rev 3 (v7l)
BogoMIPS        : 108.00
Features        : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x0
CPU part        : 0xd08
CPU revision    : 3

processor       : 3
model name      : ARMv7 Processor rev 3 (v7l)
BogoMIPS        : 108.00
Features        : half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x0
CPU part        : 0xd08
CPU revision    : 3

Hardware        : BCM2711
Revision        : d03114
Serial          : 100000005cd60c4f
Model           : Raspberry Pi 4 Model B Rev 1.4

I confirmed that the bullseye Raspberry Pi build installed and came up successfully on this platform.

Edited by Stan Hu

Merge request reports