Repository navigation
Support opt-in Raspberry Pi 4 guest builds - #2092
Merged
Merged
Conversation
Select the exclusive load/store allocator when LSE is disabled. Preserve guest target flags in non-PIE builds and document the opt-in configuration. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: cshung <3410332+cshung@users.noreply.github.com>
cshung
requested review from
danbugs,
dblnz,
devigned,
jprendes,
jsturtevant,
ludfjig,
simongdavies and
syntactically
as code owners
November 23, 2026 22:04
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues block the opt-in Raspberry Pi 4 guest-build changes.
No open issues 🎉
What changed in this PR
This PR enables opt-in Raspberry Pi 4 guest builds for Hyperlight on 64-bit Linux/KVM while keeping LSE atomics enabled by default.
Changes:
- Adds an exclusive load/store retry loop for physical-page allocation when LSE is disabled.
- Preserves incoming
RUSTFLAGSin non-PIE guest builds. - Documents build commands and platform requirements. Hardware validation remains manual, without Raspberry Pi CI coverage.
| File | Description |
|---|---|
src/hyperlight_guest/src/arch/aarch64/prim_alloc.rs |
Selects LSE or exclusive load/store atomics at compile time. |
Justfile |
Preserves caller-supplied flags for non-PIE Rust guests. |
docs/how-to-build-a-hyperlight-guest-binary.md |
Explains opt-in builds and Raspberry Pi 4 requirements. |
CHANGELOG.md |
Records guest support for ARM64 CPUs without LSE. |
Review effort: Balanced
Benchmark ResultsMeasured commit: kvm / amd (Linux) (➖ stable)No benchmark improved or regressed. Benchmark Resultsfunction_call_codec
payload_allocation
sandboxes
slot_pool
snapshot_files
virtq_readonly
virtq_readwrite
kvm / intel (Linux) (➖ stable)No benchmark improved or regressed. Benchmark Resultsfunction_call_codec
payload_allocation
sandboxes
slot_pool
snapshot_files
virtq_readonly
virtq_readwrite
mshv3 / amd (Linux) (➖ stable)No benchmark improved or regressed. Benchmark Resultsfunction_call_codec
payload_allocation
sandboxes
slot_pool
snapshot_files
virtq_readonly
virtq_readwrite
mshv3 / intel (Linux) (➖ stable)No benchmark improved or regressed. Benchmark Resultsfunction_call_codec
payload_allocation
sandboxes
slot_pool
snapshot_files
virtq_readonly
virtq_readwrite
hyperv-ws2025 / amd (Windows) (➖ stable)No benchmark improved or regressed. Benchmark Resultsfunction_call_codec
payload_allocation
sandboxes
slot_pool
snapshot_files
virtq_readonly
virtq_readwrite
hyperv-ws2025 / intel (Windows) (➖ stable)No benchmark improved or regressed. Benchmark Resultsfunction_call_codec
payload_allocation
sandboxes
slot_pool
snapshot_files
virtq_readonly
virtq_readwrite
Reported by |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Opt-in guest builds for Raspberry Pi 4 on 64-bit Linux/KVM. The Pi 4's Cortex-A72 lacks LSE atomics.
This is a niche configuration intended for testing. There is no Raspberry Pi 4 CI coverage, and this PR does not add any. Manual hardware validation is sufficient for this use case.
Configuration
Default ARM64 builds retain LSE. Disabling LSE selects an atomic exclusive load/store retry loop for the physical-page allocator. The loop may cost more under contention. Non-PIE guest builds preserve incoming
RUSTFLAGS.Validation
just fmt-apply,just clippy,just build,just guests, andjust testpassed. Guest Clippy passed with LSE enabled and disabled.LDADD. All ten opt-in guest binaries contain no LSE instructions.