feat(libc): export the wide num_put facet vtable as data #9845

Merged
mazen320 merged 2 commits from upstream-pr/9845 into main 2026-10-24 12:50:33 +00:00
mazen320 commented 2026-10-22 17:43:11 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by mazen320 on 2026-10-22T17:43:11Z.


What

Export num_put<wchar_t>'s vtable (NID 59oywaaZbJk) as fourteen zeroed uintptr_t slots plus the matching facet id, so titles that resolve it as data get a 112-byte object matching title libc.prx (PPSA16833 / LEGO Batman). Facet calls through the slots still fault until methods are wired (debt note). Orthogonal to #9698 (char vtable size) and #9038 (char _Getcat).

Tested

  • python tools/check_conventions.py --base upstream/main — pass
  • Built guest_locale_tests with this change and ran it on Windows MinGW; output Guest locale checks passed (load build-win/core/libs/libs/unpatched/libc.prx ahead of other libc.prx on PATH)
  • Windows/Linux CI jobs not claimed here

Checklist

  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • Silent stubs: none
  • GPUs tested: none (libc data export only)
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4971632278 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9845). Originally posted by [mazen320](https://github.com/mazen320) on 2026-10-22T17:43:11Z. --- ### What Export `num_put<wchar_t>`'s vtable (NID `59oywaaZbJk`) as fourteen zeroed `uintptr_t` slots plus the matching facet `id`, so titles that resolve it as data get a 112-byte object matching title `libc.prx` (PPSA16833 / LEGO Batman). Facet calls through the slots still fault until methods are wired (debt note). Orthogonal to #9698 (char vtable size) and #9038 (char `_Getcat`). ### Tested - `python tools/check_conventions.py --base upstream/main` — pass - Built `guest_locale_tests` with this change and ran it on Windows MinGW; output `Guest locale checks passed` (load `build-win/core/libs/libs/unpatched/libc.prx` ahead of other `libc.prx` on `PATH`) - Windows/Linux CI jobs not claimed here ### Checklist - Depends on: none - Fixes: none - Unblocks: none - Silent stubs: none - GPUs tested: none (libc data export only) - AI-assisted: yes
MarcZX10 commented 2026-10-22 17:51:02 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-22T17:51:02Z.

Review: APPROVED


Reviewed the complete updated diff, its writable zero-initialized data test, and the author-reported Windows MinGW locale test rerun after rebasing onto current main. No code issue found. CI has conventions/report/eligibility and Linux register-context passing; the remaining relinker/register-context jobs were still pending at my last check, and product builds are skipped.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5618525140 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/9845#pullrequestreview-5618525140). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-22T17:51:02Z. **Review:** APPROVED --- Reviewed the complete updated diff, its writable zero-initialized data test, and the author-reported Windows MinGW locale test rerun after rebasing onto current main. No code issue found. CI has conventions/report/eligibility and Linux register-context passing; the remaining relinker/register-context jobs were still pending at my last check, and product builds are skipped.
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!9845
No description provided.