feat(exports): implement three small PRAGMATA exports #3791

Merged
YossiYad merged 3 commits from upstream-pr/3791 into main 2026-10-12 20:22:20 +00:00
YossiYad commented 2026-10-11 16:43:58 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by YossiYad on 2026-10-11T16:43:58Z.


What

Carries screamm's three screamm/AnyPS5:feat/pragmata-small-exports commits from #3767 unchanged onto current main, preserving their author, one per function:

  • sceNpEntitlementAccessGetGameTrialsFlag(uint32_t* flag) writes 0 (full game) and returns 0, or 0x817D0002 for a null pointer. This is PRAGMATA's reported stop on main (#3043): sceNpEntitlementAccessGetGameTrialsFlag not implemented.
  • sceRazorCpuSync() returns 0 and does nothing, like the other Razor exports without an attached capture; listed under TechnicalDebt's silent stubs.
  • sceSharePlayProhibitController(int prohibited) returns 0 for 0 and 1 and throws for other values; the setting is not stored, as no Share Play session exists.

PRAGMATA imports sceRazorCpuSync and sceSharePlayProhibitController, which no library exported, so it fails to load without them. The null-pointer code and a possible second argument of GetGameTrialsFlag are recorded in TechnicalDebt.

The library progress moves from 2903/3383 (85.81%) to 2906/3385 (85.85%). The total rises by two because the Razor and Share Play calls were not exported before.

Closes #3767.

Tested

Linux (Bazzite 44, GCC 16.2.1, Ninja, Release, -DBUILD_TESTING=ON), based on main a11c8f7f:

  • Full build, libs, and full ctest: 824 pass, 8 skip, no failures (832 registered tests).
  • guest_offline_imports, guest_razor_cpu and guest_share_play pass at each of the three commits on its own. This is the first Linux run of the commits; the author reported Windows only.
  • tools/check_conventions.py --base upstream/main and git diff --check pass.
  • The original author reported Windows testing in #3767. PRAGMATA was not run on this machine.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw; silent stubs are listed in TechnicalDebt
  • No notes, investigation .md files or images added to the repository
  • No new third-party code
  • Generic behaviour, not specific to one title
  • Depends on: none
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4820652532 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3791). Originally posted by [YossiYad](https://github.com/YossiYad) on 2026-10-11T16:43:58Z. --- ### What Carries screamm's three `screamm/AnyPS5:feat/pragmata-small-exports` commits from #3767 unchanged onto current `main`, preserving their author, one per function: - `sceNpEntitlementAccessGetGameTrialsFlag(uint32_t* flag)` writes 0 (full game) and returns 0, or `0x817D0002` for a null pointer. This is PRAGMATA's reported stop on `main` (#3043): `sceNpEntitlementAccessGetGameTrialsFlag not implemented`. - `sceRazorCpuSync()` returns 0 and does nothing, like the other Razor exports without an attached capture; listed under TechnicalDebt's silent stubs. - `sceSharePlayProhibitController(int prohibited)` returns 0 for 0 and 1 and throws for other values; the setting is not stored, as no Share Play session exists. PRAGMATA imports `sceRazorCpuSync` and `sceSharePlayProhibitController`, which no library exported, so it fails to load without them. The null-pointer code and a possible second argument of `GetGameTrialsFlag` are recorded in TechnicalDebt. The library progress moves from 2903/3383 (85.81%) to 2906/3385 (85.85%). The total rises by two because the Razor and Share Play calls were not exported before. Closes #3767. ### Tested Linux (Bazzite 44, GCC 16.2.1, Ninja, Release, `-DBUILD_TESTING=ON`), based on `main` `a11c8f7f`: - Full build, `libs`, and full `ctest`: 824 pass, 8 skip, no failures (832 registered tests). - `guest_offline_imports`, `guest_razor_cpu` and `guest_share_play` pass at each of the three commits on its own. This is the first Linux run of the commits; the author reported Windows only. - `tools/check_conventions.py --base upstream/main` and `git diff --check` pass. - The original author reported Windows testing in #3767. PRAGMATA was not run on this machine. ### Checklist - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except technical debt - [x] Unimplemented paths throw; silent stubs are listed in TechnicalDebt - [x] No notes, investigation `.md` files or images added to the repository - [x] No new third-party code - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] AI-assisted: yes
github-actions[bot] commented 2026-10-11 16:46:42 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-11T16:46:42Z.


Progress report (3e0e01f → 9698804)

📈 System libraries: 86.4% (+0.04%, +3 implemented functions)

✅ 3 implemented
Library Name
libSceNpEntitlementAccess sceNpEntitlementAccessGetGameTrialsFlag
libSceRazorCpu sceRazorCpuSync
libSceSharePlay sceSharePlayProhibitController
⚪ 1 behaviourally empty (constant return or throw)
Library Name
libSceRazorCpu sceRazorCpuSync
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6111325137 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3791#issuecomment-6111325137). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-11T16:46:42Z. --- <!-- progress-report --> ### Progress report (3e0e01f → 9698804) 📈 **System libraries**: 86.4% (+0.04%, +3 implemented functions) <details> <summary>✅ 3 implemented</summary> | Library | Name | | - | - | | libSceNpEntitlementAccess | `sceNpEntitlementAccessGetGameTrialsFlag` | | libSceRazorCpu | `sceRazorCpuSync` | | libSceSharePlay | `sceSharePlayProhibitController` | </details> <details> <summary>⚪ 1 behaviourally empty (constant return or throw)</summary> | Library | Name | | - | - | | libSceRazorCpu | `sceRazorCpuSync` | </details>
xXPBSXx commented 2026-10-11 22:50:16 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-11T22:50:16Z.


Test from PRAGMATA (PPSA02530), Windows, MinGW GCC 15.2.0: the import audit on main plus this PR no longer lists sceRazorCpuSync or sceSharePlayProhibitController, which the title imports. With the rest of the stack applied (#3537, #3737, #3517, #3604, #3707 and my export PRs #3799 and #3773) the title gets through the loader and starts; it then crashes in the title's own code (0xc0000005, write at 0x20, app.exe+0x26917; the known allocator/ASLR matter of #3043). Not tested: this PR alone, and what the title does with the two calls.

AI-assisted (Claude Code).

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6114782197 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3791#issuecomment-6114782197). Originally posted by [xXPBSXx](https://github.com/xXPBSXx) on 2026-10-11T22:50:16Z. --- Test from PRAGMATA (PPSA02530), Windows, MinGW GCC 15.2.0: the import audit on `main` plus this PR no longer lists `sceRazorCpuSync` or `sceSharePlayProhibitController`, which the title imports. With the rest of the stack applied (#3537, #3737, #3517, #3604, #3707 and my export PRs #3799 and #3773) the title gets through the loader and starts; it then crashes in the title's own code (`0xc0000005`, write at `0x20`, `app.exe+0x26917`; the known allocator/ASLR matter of #3043). Not tested: this PR alone, and what the title does with the two calls. AI-assisted (Claude Code).
oneandonlydean commented 2026-10-12 08:24:15 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-12T08:24:15Z.


Needs another rebase: docs/dev/TechnicalDebt.md conflicts with main again, and eligibility fails on 24c052a32 because of it.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6120521428 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3791#issuecomment-6120521428). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-12T08:24:15Z. --- Needs another rebase: `docs/dev/TechnicalDebt.md` conflicts with main again, and eligibility fails on 24c052a32 because of it.
adriadam10 commented 2026-10-12 20:01:51 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-12T20:01:51Z.


Rebased onto current main (the debt entries moved to docs/dev/debt/<library>.md): the three commits are unchanged, and the three TechnicalDebt entries now live in debt/libSceNpEntitlementAccess.md (Functional, replacing the old PPSA08427 "no parameters" line), debt/libSceRazorCpu.md (Silent stubs) and debt/libSceSharePlay.md (Functional). guest_offline_imports, guest_razor_cpu and guest_share_play pass on the rebased tree. Merging once CI is green.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6131670667 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3791#issuecomment-6131670667). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-12T20:01:51Z. --- Rebased onto current `main` (the debt entries moved to `docs/dev/debt/<library>.md`): the three commits are unchanged, and the three TechnicalDebt entries now live in `debt/libSceNpEntitlementAccess.md` (Functional, replacing the old PPSA08427 "no parameters" line), `debt/libSceRazorCpu.md` (Silent stubs) and `debt/libSceSharePlay.md` (Functional). `guest_offline_imports`, `guest_razor_cpu` and `guest_share_play` pass on the rebased tree. Merging once CI is green.
Sign in to join this conversation.
No reviewers
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!3791
No description provided.