Build with ARMv7 instead of ARMv6 in Ruby and Rust
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
- Relates to omnibus-gitlab!7231 (merged)
- Test pipeline: https://gitlab.com/gitlab-org/omnibus-gitlab/-/pipelines/1072893284
- Successful Raspberry Pi build: https://gitlab.com/gitlab-org/omnibus-gitlab/-/jobs/5538586871
- Raspberry Pi kernel: https://www.raspberrypi.com/documentation/computers/linux_kernel.html. Note that https://github.com/raspberrypi/linux/blob/a054d44b23e3619e4fa2d09139e76fd8cf3f8c7b/arch/arm/configs/bcmrpi_defconfig#L34 is the only kernel tat has
CONFIG_ARCH_MULTI_V6
enabled (https://cateee.net/lkddb/web-lkddb/ARCH_MULTI_V6.html).
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.