A Tale of Two Architectures: 32‑bit vs 64‑bit Raspberry Pi OS Lite on the Pi Zero 2 W
Updated: 4 May 2025 — Raspberry Pi OS Bookworm
Why this test?
The Pi Zero 2 W is the first “Zero‑class” board with a 64‑bit Cortex‑A53 CPU yet it still ships with just 512 MB of RAM.
That raises an obvious question:
Does running the 64‑bit build of Raspberry Pi OS cost me precious memory compared with the 32‑bit image?
To get a first‑order answer I installed identical Bookworm Lite images on two SD cards, booted one in 64‑bit mode and the other in 32‑bit mode, waited until the blueled
heartbeat settled (~5 min) and captured a single top
snapshot from each board via SSH.
(Both images were vanilla except for an apt update && apt full-upgrade
and enabling SSH.)
Raw snapshots
64‑bit Pi OS Lite (`arm64`)
top - 10:32:28 up 6 min, 1 user, load average: 0.08, 0.11, 0.07
Tasks: 136 total, 1 running, 135 sleeping, 0 stopped, 0 zombie
%Cpu(s): 0.2 us, 0.1 sy, 0.0 ni, 97.4 id, 2.4 wa, 0.0 hi, 0.0 si, 0.0 st
MiB Mem : 417.0 total, 218.2 free, 125.4 used, 124.0 buff/cache
MiB Swap: 512.0 total, 512.0 free, 0.0 used. 291.6 avail Mem
32‑bit Pi OS Lite (`armhf`)
top - 10:51:03 up 11 min, 1 user, load average: 0.01, 0.06, 0.07
Tasks: 129 total, 1 running, 128 sleeping, 0 stopped, 0 zombie
%Cpu(s): 0.3 us, 0.0 sy, 0.0 ni, 99.7 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
MiB Mem : 425.7 total, 263.4 free, 103.1 used, 107.7 buff/cache
MiB Swap: 512.0 total, 512.0 free, 0.0 used. 322.6 avail Mem
Head‑to‑head at a glance
Metric (MiB) | 64‑bit | 32‑bit | Δ (32‑bit – 64‑bit) |
---|---|---|---|
Total reported | 417.0 | 425.7 | +8.7 |
Used | 125.4 | 103.1 | ‑22.3 |
Buff/Cache | 124.0 | 107.7 | ‑16.3 |
Free | 218.2 | 263.4 | +45.2 |
Avail Mem | 291.6 | 322.6 | +31.0 |
Tasks | 136 | 129 | ‑7 |
(Positive deltas mean the 32‑bit image fares better.)
What the numbers tell us
- Memory footprint: Right after boot the 32‑bit system keeps about 30 MiB more genuinely available RAM.
That is ~7 % of total memory on this board — not huge, but often the difference between keeping all file‑system caches in RAM and dipping into swap.
The gap mirrors measurements from Phoronix (103 MiB vs 196 MiB on a Pi 4)[^1] and other community reports[^2][^3]. - Extra processes: Seven more user‑land tasks run on the 64‑bit image. Most are architecture helpers like
systemd-udevd
workers compiled twice (native + compat) or services that start a few seconds earlier in the faster‑booting 64‑bit kernel. - CPU & I/O: Both boards are practically idle. The 2.4 % I/O‑wait spike on the 64‑bit board likely came from
apt
’s post‑install housekeeping and vanished by the time the 32‑bit snapshot was taken.
Why does 64‑bit use more RAM?
- Pointer size and structure padding: Every in‑memory pointer doubles from 4 to 8 bytes. In large daemons (
systemd
,dbus-daemon
) this adds up quickly. - Wider instruction set: AArch64 instructions are always 4 bytes long (vs the variable‑length Thumb2 mix used by armv7) which slightly bloats code sections in binaries and shared libraries.
- Kernel page tables & per‑process overhead: The 64‑bit kernel maintains additional translation tables to access the 48‑bit virtual address space[^4].
- Different default services: Since Bookworm, VNC on 32‑bit is disabled until RealVNC ships an armhf build[^5]; the 64‑bit image enables Wayland & VNC out‑of‑the‑box, costing a few background services.
Do these ~30 MiB matter in real projects?
- Headless appliances (Pi‑hole, MQTT, Zigbee gateway) rarely exceed 100 MiB RSS and never touch swap, so either architecture is fine.
- Interactive workloads (Python notebooks, big
npm
builds) regularly brush the 512 MiB ceiling. Hitting swap on an SD card can be a painful 5× slowdown. For those tasks, the 32‑bit image buys you a few more cached pages before swapping kicks in. - CPU‑bound jobs (compression, cryptography, media encoding) see 10–30 % speed‑ups on AArch64 according to multiple benchmarks[^6][^7][^8]. If wall‑clock time beats a few extra megabytes, choose 64‑bit.
Recommendations
- Need every last MiB? Stay on 32‑bit, disable the desktop, and mount
/var/log
intmpfs
. - Need performance or modern containers? Go 64‑bit and, if RAM is tight, add
zram-config
to off‑load swap into compressed RAM. - Don’t sweat SD‑card wear: The additional package size or swap activity from 64‑bit is measured in hundreds of megabytes per month—trivial compared with a high‑endurance card’s terabytes‑written rating[^9].
Next experiments
- Compare swapping behaviour under a real compile workload (
stress-ng
ormake -j4 linux
). - Measure power draw: Does the fuller caches of 64‑bit cause extra SDRAM refresh power?
- Benchmark zram vs physical swap on SD.
Footnotes & further reading
[^1]: Further Investigating the Raspberry Pi 32‑bit vs 64‑bit Performance, Phoronix, Feb 2022 — https://www.phoronix.com/review/raspberrypi-os-64bit
[^2]: Raspberry Pi OS 64‑bit vs 32‑bit – Tech Explorations, Jan 2024 — https://techexplorations.com/guides/rpi/begin/rpi-os-32bit-vs-64bit
[^3]: “Bookworm is here – which should I choose, 32 bit or 64 bit?”, Raspberry Pi Forums thread #357532 — https://forums.raspberrypi.com/viewtopic.php?t=357532
[^4]: “Raspberry Pi OS memory usage”, Raspberry Pi Forums thread #365766 — https://forums.raspberrypi.com/viewtopic.php?t=365766
[^5]: Raspberry Pi Blog, Bookworm — the new version of Raspberry Pi OS, Oct 2023 — https://www.raspberrypi.com/news/bookworm-the-new-version-of-raspberry-pi-os/
[^6]: Phoronix benchmark suite averages showing 48 % mean speed‑up — https://www.phoronix.com/review/raspberrypi-os-64bit
[^7]: Reddit discussion of Phoronix results — https://www.reddit.com/r/raspberry_pi/comments/smv9h3/raspberry_pi_os_32bit_vs_64bit_performance_review/
[^8]: Medium post “Use 32‑bit OS for Raspberry Pi Zero 2 W”, TechHara, Sep 2023 — https://medium.com/@techhara/stick-with-32-bit-os-for-raspberry-pi-zero-2w-d5367ce5a6d4
[^9]: SanDisk WD Purple SC QD102 microSD datasheet (32 TBW for 32 GB model) — https://shop.sandisk.com/products/memory-cards/microsd-cards/wd-purple-qd102-microsd