[Discussion] Native Apple Silicon (ARM64) support - Long-term roadmap #1553

Closed
opened 2026-10-08 12:12:25 +00:00 by DevnisG · 3 comments
DevnisG commented 2026-10-08 12:12:25 +00:00 (Migrated from github.com)
Contributor

Imported from boykopovar/AnyPS5. Originally posted by DevnisG on 2026-10-08T12:12:25Z.


Overview

I'd like to propose exploring native Apple Silicon (ARM64) support as a long-term direction for AnyPS5.

The ongoing macOS x86-64 work in #1 is already making impressive progress, including Mach-O support, Rosetta 2, MoltenVK, and platform-specific runtime implementations.

However, relying on Rosetta 2 introduces a long-term compatibility concern as Apple transitions away from it.

This proposal is not intended to replace or interfere with the ongoing macOS port. The goal is to document possible approaches and establish a roadmap for future ARM64 support when the project is mature enough.

Technical challenges

PS5 executables contain x86-64 machine code, while Apple Silicon uses ARM64.

Native support would require investigating:

  • Static binary translation from x86-64 to ARM64.
  • CPU instruction compatibility, including SIMD, atomics and memory ordering.
  • ABI differences, TLS, exceptions and stack unwinding.
  • Mach-O executable generation and dynamic linking.
  • macOS memory management, page sizes and executable-memory restrictions.
  • Reusing existing Vulkan/MoltenVK infrastructure without affecting other platforms.

Proposed roadmap

  • Evaluate the current relinker architecture and its extension points.
  • Research existing x86-64-to-ARM64 translation projects and reusable components.
  • Compare static and dynamic translation approaches.
  • Identify reusable components from the existing macOS port.
  • Develop a minimal ARM64 proof of concept using synthetic test binaries.
  • Establish automated tests on Apple Silicon.
  • Evaluate performance, limitations and long-term maintainability.
  • Consider implementation through small, independent pull requests.

Initial milestone

A successful proof of concept would execute a small converted x86-64 guest program as a native ARM64 macOS process, with correct ABI and memory behavior.

Game compatibility and graphics support would come later.

  • #1 — macOS support
  • #1509 — ARM architecture support
  • #927 — macOS exception runtime
  • #1432 — Standalone relinker build on Apple Silicon
  • #1499 — macOS x86-64 unwind register contexts

Final thoughts

I believe native ARM64 support could be an interesting long-term opportunity for AnyPS5, especially given its executable-relinking architecture.

There's no expectation of immediate implementation. This is intended as a place to discuss feasibility, architectural decisions and potential contributions.

I'd be interested in hearing the maintainers' thoughts on whether this direction aligns with the project's philosophy and whether it makes sense to track it separately from the existing macOS effort.

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5761547695 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/1553). Originally posted by [DevnisG](https://github.com/DevnisG) on 2026-10-08T12:12:25Z. --- ## Overview I'd like to propose exploring native Apple Silicon (ARM64) support as a long-term direction for AnyPS5. The ongoing macOS x86-64 work in #1 is already making impressive progress, including Mach-O support, Rosetta 2, MoltenVK, and platform-specific runtime implementations. However, relying on Rosetta 2 introduces a long-term compatibility concern as Apple transitions away from it. This proposal is not intended to replace or interfere with the ongoing macOS port. The goal is to document possible approaches and establish a roadmap for future ARM64 support when the project is mature enough. ## Technical challenges PS5 executables contain x86-64 machine code, while Apple Silicon uses ARM64. Native support would require investigating: - Static binary translation from x86-64 to ARM64. - CPU instruction compatibility, including SIMD, atomics and memory ordering. - ABI differences, TLS, exceptions and stack unwinding. - Mach-O executable generation and dynamic linking. - macOS memory management, page sizes and executable-memory restrictions. - Reusing existing Vulkan/MoltenVK infrastructure without affecting other platforms. ## Proposed roadmap - [ ] Evaluate the current relinker architecture and its extension points. - [ ] Research existing x86-64-to-ARM64 translation projects and reusable components. - [ ] Compare static and dynamic translation approaches. - [ ] Identify reusable components from the existing macOS port. - [ ] Develop a minimal ARM64 proof of concept using synthetic test binaries. - [ ] Establish automated tests on Apple Silicon. - [ ] Evaluate performance, limitations and long-term maintainability. - [ ] Consider implementation through small, independent pull requests. ## Initial milestone A successful proof of concept would execute a small converted x86-64 guest program as a native ARM64 macOS process, with correct ABI and memory behavior. Game compatibility and graphics support would come later. ## Related work - #1 — macOS support - #1509 — ARM architecture support - #927 — macOS exception runtime - #1432 — Standalone relinker build on Apple Silicon - #1499 — macOS x86-64 unwind register contexts ## Final thoughts I believe native ARM64 support could be an interesting long-term opportunity for AnyPS5, especially given its executable-relinking architecture. There's no expectation of immediate implementation. This is intended as a place to discuss feasibility, architectural decisions and potential contributions. I'd be interested in hearing the maintainers' thoughts on whether this direction aligns with the project's philosophy and whether it makes sense to track it separately from the existing macOS effort.
yabanana commented 2026-10-08 13:09:19 +00:00 (Migrated from github.com)
Author
Contributor

Imported from boykopovar/AnyPS5. Originally posted by yabanana on 2026-10-08T13:09:19Z.


I'm an Apple Silicon user and I'm investigating an AOT-only route: reuse AnyPS5's ELF, unwind and relocation analysis, add verified reverse-engineering annotations, recover native function signatures, and compile to ARM64 Mach-O through LLVM. The shipped program would have no x86 interpreter, JIT or Rosetta dependency; Vulkan/MoltenVK would remain initially.

A small binary-input experiment on three scalar functions with known ABIs produced ARM64 machine code identical to a source-compiled scalar reference. This only checks one mechanism: indirect-call coverage, C++ exceptions, TLS and memory ordering remain substantial work, and no game compatibility is established.

I'm preparing the full design before proposing implementation. Would this direction fit the project?

AI-assisted research.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6060588712 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/1553#issuecomment-6060588712). Originally posted by [yabanana](https://github.com/yabanana) on 2026-10-08T13:09:19Z. --- I'm an Apple Silicon user and I'm investigating an AOT-only route: reuse AnyPS5's ELF, unwind and relocation analysis, add verified reverse-engineering annotations, recover native function signatures, and compile to ARM64 Mach-O through LLVM. The shipped program would have no x86 interpreter, JIT or Rosetta dependency; Vulkan/MoltenVK would remain initially. A small binary-input experiment on three scalar functions with known ABIs produced ARM64 machine code identical to a source-compiled scalar reference. This only checks one mechanism: indirect-call coverage, C++ exceptions, TLS and memory ordering remain substantial work, and no game compatibility is established. I'm preparing the full design before proposing implementation. Would this direction fit the project? AI-assisted research.
DevnisG commented 2026-10-08 13:52:26 +00:00 (Migrated from github.com)
Author
Contributor

Imported from boykopovar/AnyPS5. Originally posted by DevnisG on 2026-10-08T13:52:26Z.


This is exactly the kind of long-term direction I was hoping to explore when opening this issue.

An AOT-only pipeline using LLVM, producing native ARM64 Mach-O binaries without Rosetta or a runtime x86 translation layer, sounds particularly interesting.

I also like the idea of reusing AnyPS5's existing ELF, relocation and unwind infrastructure rather than building an entirely separate toolchain.

One area I'm especially curious about is how you plan to handle indirect branches, function boundary recovery and ABI reconstruction for larger binaries where reliable annotations may not be available.

I'd be very interested in reviewing your design once it's ready and potentially contributing to the implementation or testing on Apple Silicon.

Thanks for sharing your progress!

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6061384704 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/1553#issuecomment-6061384704). Originally posted by [DevnisG](https://github.com/DevnisG) on 2026-10-08T13:52:26Z. --- This is exactly the kind of long-term direction I was hoping to explore when opening this issue. An AOT-only pipeline using LLVM, producing native ARM64 Mach-O binaries without Rosetta or a runtime x86 translation layer, sounds particularly interesting. I also like the idea of reusing AnyPS5's existing ELF, relocation and unwind infrastructure rather than building an entirely separate toolchain. One area I'm especially curious about is how you plan to handle indirect branches, function boundary recovery and ABI reconstruction for larger binaries where reliable annotations may not be available. I'd be very interested in reviewing your design once it's ready and potentially contributing to the implementation or testing on Apple Silicon. Thanks for sharing your progress!
oneandonlydean commented 2026-10-10 06:25:12 +00:00 (Migrated from github.com)
Author
Contributor

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-10T06:25:12Z.


Closing as a duplicate of #1, where other host platforms are discussed.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6094630839 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/1553#issuecomment-6094630839). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-10T06:25:12Z. --- Closing as a duplicate of #1, where other host platforms are discussed.
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5#1553
No description provided.