feat(libSceAjmi): implement inline and run batch aliases #16283
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/16283"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by Noxy-HNR on 2026-11-06T03:50:21Z.
What
Implement the two literal-NID Ajmi batch aliases as typed forwarders to the existing same-module builders:
sceAjmiBatchJobInlineBuffer(4MsUK9kAnKg) andsceAjmiBatchJobRunBufferRa(m0xisYC6U2w). The firmware 13.42 symbol-table report identifies the shared entry addresses. Console behavior and other firmware versions remain unverified; the existing builders still leave invalid pointers and insufficient batch capacity unchecked.The main merge preserves the renamed exports from merged #15495 and replaces only the two naming-only aliases. #12613 remains the integration-order prerequisite; none of its unmerged code is included. After it lands, retain its control/split builders and rerun affected tests.
The test target now builds private NID-patched Ajmi/libc/kernel copies instead of depending on every library. Raw and patched cases share the same independent byte fixtures, with scoped search paths for Windows, Linux and macOS.
Tested
Current verification (November 9), head
d505b5c952fb92bd79af5baf533da342bb8bd772, merging main52c33518f8061a9056bd2a25225b3e4f76584b18:Windows 11 build 26300 x86-64, WinLibs GCC 15.2.0 r7/Ninja, Release, full configuration (
BUILD_TESTING=ON,ANYPS5_RELINKER_ONLY=OFF),-j 18. Builtguest_ajmi_batch_aliases_testswith its private module/dependency fixture.All four CTests passed in each of three final runs, none skipped:
guest_ajmi_batch_inline_unpatched,guest_ajmi_batch_run_unpatched,guest_ajmi_batch_inline_nid,guest_ajmi_batch_run_nid. A deliberate wrong return pointer compiled and caused both inline variants to fail the intendedinline returned pointerassertion. The source was restored, rebuilt and all four tests passed three times afterward; final-head tests passed again after committing. Public headers passed for 407 libraries / 33,828 exports; conventions and whitespace checks passed. Independent review of the exact diff, source and validation logs found no push blockers.No new Linux, macOS, console or title runtime result is claimed. Fresh hosted checks for this head are pending; full manual dispatch may require maintainer access.
Historical verification; results retain their original heads and scope
Historical-head hosted verification (
d3a71c7d7f): the Windows changed-test job passed; all four new inline/run tests passed through the raw and NID-patched exports. The job reports zero failures among 3,346 selected CTest entries, including skipped entries. Its log identifies this exact PR head. This is not a fresh full Linux run; earlier local and Linux results below retain their stated commits and scope.Merge order still follows #15495 and #12613; rebase and repeat the affected tests after those dependencies land.
New raw and NID-patched
guest_ajmi_batch_inline_*andguest_ajmi_batch_run_*tests compare complete 512-byte batch buffers with expected layouts, including preserved header bits, padding, returned and payload pointers, odd/aligned starts, instance and flag masks, size truncation, optional return addresses and unchanged external buffers. Seven published flag measurements are pinned as literal expected words.Windows x86-64, WinLibs GCC 15.2.0, Ninja, Release, full configuration with source-built dependencies, at
d3a71c7d7fon main3cb1cd29ec:libsdependency andguest_ajmi_batch_aliases_tests. The four inline/run, raw/NID-patched tests passed 4/4 in each of three runs.Export.cpp, all four tests reach the old throwing exports and fail by assertion, rather than failing symbol lookup.-Wall -Wextra -Werrortest syntax, conventions and whitespace pass. The public-header audit verifies 406 libraries / 30,649 exports.tools/pr_overlap.py --repo boykopovar/AnyPS5 --base main --branch feat/ajmi-batch-aliasesreports the declared #15495 naming overlap and adjacent debt changes in #12613. It cannot automatically compare #13486 because that branch conflicts with main. Its shared Ajmi source/header/debt additions reproduce the already-implementedsceAjm*run builder, not these twosceAjmi*aliases; I compared those patches directly. This is not a clean automatic overlap result. The current-main merge preview is clean; integrations after the declared predecessors must be rebased and retested.No Linux, console or retail-title run.
Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)