Skip to content

feat(aot): run controller input and independent provider-transfer consumers - #4397

Closed
yabanana wants to merge 101 commits into
boykopovar:mainfrom
yabanana:feature/aot-pad-input
Closed

yabanana wants to merge 101 commits into
boykopovar:mainfrom
yabanana:feature/aot-pad-input

Conversation

@yabanana

@yabanana yabanana commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

What

Add the public SDK's unchanged pad_input as the next runnable native Apple ARM64 consumer. Its seven functions are compiled AOT from an x86-64 ELF and linked to the shared runtime. The build uses #4396's provider catalog and matching DWARF candidates instead of a handwritten list of C function signatures and frame objects.

The acceptance target compares the independently source-compiled ARM64 program and the AOT program across button edges, intercepted input, OPTIONS, read failure, user/initialization/open errors and the 625-iteration timeout. Test adapters publish state through the existing Pad implementation and count sleeps. A separate production-provider smoke preserves all 625 real 16 ms sleeps. Input buffers, notifications, return codes, closure and teardown are checked. Binary/object/runtime hashes bind the reports to the tested artifacts.

Also include a reproducible transfer probe using the unchanged public ps5-payload-dev/sdk hello_world source at f5d40f02770e9b0001dd9e18056eca70b3da8b40. Its three known provider contracts transfer without changing the generic mechanism. The old-style main() remains a recovery obligation and is qualified in an explicit source profile. The original source/license is supplied separately, not vendored into this PR. This probe uses declaration-only cross headers and the verified ps5link CRT, so it does not validate that SDK's original loader.

Stacked on #4396 and its prerequisites, based on main c36fd0a0e. Review the incremental consumer change. Keep this draft while the in-tree direction is being decided.

Tested

Latest integration checkpoint (12 October): aligned with main 2f4cc8983, including the new component technical-debt layout. The final combined stack with the separate C++ follow-up #4718 passed 588 compiler/relinker/runtime checks and 26 native integrations on Apple Silicon. Rebuilt cube AOT/reference still match all eight RGB frames after 600 flips each; controller and typed module-bundle acceptance pass. These are local results; hosted CI is running on the updated head. Full Linux/Windows builds still require maintainer dispatch.

Integration checkpoint, 12 October: merged main fe66af13e through the dependency stack and requalified affected provider identities after reviewing their implementations. The final combined stack passed 526 compiler/relinker/runtime cases, 26 native integration cases, the rebuilt graphics pair (600 flips each, teardown, eight exact RGB frames), controller O2 and SHA/memcmp O0/O2 checks on Apple Silicon. Hosted checks refer to the new head and remain separate from these local results. Full Linux/Windows builds require maintainer dispatch.

Apple ARM64, current head:

  • 475 compiler/relinker/runtime checks passed, plus the new native_aot_pad_input_compile check. The new compile check is registered in the existing Apple AOT CI lane; it does not require the graphics dependencies.
  • 20 native integration tests passed, including the six controller scenarios and direct-memory alias regression inherited from feat(aot): run source-built graphics on native Apple ARM64 #3891.
  • native_pad_input_check: both native binaries agree in all six scenarios. The production-provider run completed its original delay and teardown in about 12 seconds.
  • Independent-source transfer: both ARM64 binaries produced Hello, world!, returned zero and completed teardown.
  • Graphics regression on the rebuilt shared runtime: 600 flips per executable and all eight 1920x1080 RGB comparisons exact.
  • Conventions, diff and test-registration checks passed. New hosted CI is pending. Full Linux/Windows Build jobs still require maintainer dispatch; skipped jobs are not passes.

Reproduce after configuring the native graphics runtime as in BUILD.md:

cmake --build build --target native_pad_input_check --parallel 6

BUILD.md contains the independent-source probe command as well.

Limits: the x86 controller input uses an O0 fixed-frame debug profile; this is not optimized or stripped-input recovery. Four C signatures and 26 frame objects are recovered, but seven of the ten catalog entries were newly qualified for this consumer. Native-pointer lifetimes, CRT initialization and constant-10 division safety remain explicit source facts. Physical controller acquisition/event pumping, console behavior, game compatibility and performance gains are not established by these tests. The startup and host string bindings in the transfer probe remain explicit qualifications.

Checklist

Rebase the graphics proposal onto upstream b42ef24 without carrying the historical macOS merge chain. Includes the compiler/runtime prerequisite from PR boykopovar#1835 and the still-required macOS foundation from mugurc/macos-port at 21930ce; those platform changes remain until their upstream PRs land. Preserve upstream starting-quad folding and the qualified vertex lane rule. Keep x87-dependent Math.cpp outside the optional ARM64 graphics closure rather than weakening its ABI assertion.
This was referenced Oct 15, 2026
@ArjenS-LA ArjenS-LA mentioned this pull request Oct 15, 2026
11 tasks done
@yabanana

Copy link
Copy Markdown
Contributor Author

Superseded by #5021, which now contains the consolidated native ARM64 AOT implementation and verified consumers. #1835 remains the architecture discussion. Closing this stacked PR to keep one implementation review; its branch and review history are retained. This is not a merge into main.

@yabanana yabanana closed this Oct 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agc libSceAgc* build ci .github docs libc libkernel needs rebase Conflicts with main, rebase needed prx relinker shader core/shader

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant