feat(libc): implement wide numpunct members #17765

Merged
B-Howell merged 2 commits from upstream-pr/17765 into main 2026-11-12 06:18:38 +00:00
B-Howell commented 2026-11-09 15:05:35 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by B-Howell on 2026-11-09T15:05:35Z.


What

Implements the ten existing std::numpunct<wchar_t> member exports in libSceLibcInternal: eight mangled member providers and two existing pending-NID aliases. The typed do_ methods read the existing wide facet fields and use the existing libc string-assignment helpers; the public methods dispatch through the facet vtable so derived facets retain their overrides. The guest facet layout is unchanged. Constructors, destructors, _Init, and _Tidy remain throwing and are recorded in technical debt because their guest construction/layout behavior is not established.

On the measured main/merge-preview pair 6b58dfa4/139c4b06, tools/progress.py moves from 13,544/38,634 (35.06%) to 13,554/38,634 (35.08%): ten existing libSceLibcInternal stubs are implemented, with no new throwing exports. The overlap check covered 1,952 open PRs. Manual comparison of the 13 shared-file warnings found no competing implementation. #17300 renames the still-throwing do_grouping provider. If it merges first, replace that throw and keep one provider for 2BmJdX269kI. #17628 adds declarations for separate money facets at the same location in Api.hpp. Keep both declaration groups when merging the second PR.

Tested

Windows 11 (WinLibs GCC 15.2.0, Release): baseline RED control confirmed all ten expected throws. Candidate GREEN at 954ab82ba9eceb7ff3ca1785d675be0be62117f9: all three focused tests passed 3/3 each, and public headers passed 65/65.

WSL Ubuntu 22.04 (GCC 11.4.0, Release): baseline RED control confirmed all ten expected throws. Candidate GREEN at 954ab82ba9eceb7ff3ca1785d675be0be62117f9: all three focused tests passed 3/3 each, and public headers passed 65/65.

The candidate test matrix was guest_libc_internal_wide_numpunct, guest_libc_internal_numpunct, and guest_locale, each repeated three times, plus all 65 public_headers tests on each host. tools/check_conventions.py --base origin/main passed. No title or GPU testing was run.

Main merge 012ebb93ae2485d85589fb080c95c4f9220e6130 (parents 954ab82b and main c85dcfd0; the only conflict, libSceLibcInternal/include/Api.hpp, keeps both the wide numpunct and main's money_get/money_put declarations), WSL Ubuntu 22.04 (GCC 11.4.0, Release): all three focused tests passed 3/3 each, and public headers passed 65/65. tools/check_conventions.py --base origin/main passed.

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 (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

🤖 Generated with Codex

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5226057856 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/17765). Originally posted by [B-Howell](https://github.com/B-Howell) on 2026-11-09T15:05:35Z. --- ### What Implements the ten existing `std::numpunct<wchar_t>` member exports in `libSceLibcInternal`: eight mangled member providers and two existing pending-NID aliases. The typed `do_` methods read the existing wide facet fields and use the existing libc string-assignment helpers; the public methods dispatch through the facet vtable so derived facets retain their overrides. The guest facet layout is unchanged. Constructors, destructors, `_Init`, and `_Tidy` remain throwing and are recorded in technical debt because their guest construction/layout behavior is not established. On the measured `main`/merge-preview pair `6b58dfa4`/`139c4b06`, `tools/progress.py` moves from 13,544/38,634 (35.06%) to 13,554/38,634 (35.08%): ten existing `libSceLibcInternal` stubs are implemented, with no new throwing exports. The overlap check covered 1,952 open PRs. Manual comparison of the 13 shared-file warnings found no competing implementation. #17300 renames the still-throwing `do_grouping` provider. If it merges first, replace that throw and keep one provider for `2BmJdX269kI`. #17628 adds declarations for separate money facets at the same location in `Api.hpp`. Keep both declaration groups when merging the second PR. ### Tested <!-- OS, title or homebrew, what was checked. "Not tested" is a valid answer. A performance change: the summary lines of main and of this PR from the same machine and scene, with the traces attached, captured as the Performance report issue form describes. --> Windows 11 (WinLibs GCC 15.2.0, Release): baseline RED control confirmed all ten expected throws. Candidate GREEN at `954ab82ba9eceb7ff3ca1785d675be0be62117f9`: all three focused tests passed 3/3 each, and public headers passed 65/65. WSL Ubuntu 22.04 (GCC 11.4.0, Release): baseline RED control confirmed all ten expected throws. Candidate GREEN at `954ab82ba9eceb7ff3ca1785d675be0be62117f9`: all three focused tests passed 3/3 each, and public headers passed 65/65. The candidate test matrix was `guest_libc_internal_wide_numpunct`, `guest_libc_internal_numpunct`, and `guest_locale`, each repeated three times, plus all 65 `public_headers` tests on each host. `tools/check_conventions.py --base origin/main` passed. No title or GPU testing was run. Main merge `012ebb93ae2485d85589fb080c95c4f9220e6130` (parents `954ab82b` and main `c85dcfd0`; the only conflict, `libSceLibcInternal/include/Api.hpp`, keeps both the wide numpunct and main's money_get/money_put declarations), WSL Ubuntu 22.04 (GCC 11.4.0, Release): all three focused tests passed 3/3 each, and public headers passed 65/65. `tools/check_conventions.py --base origin/main` passed. ### Checklist <!-- Rules behind each item: https://github.com/boykopovar/AnyPS5/blob/main/CONTRIBUTING.md --> - [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](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed under Silent stubs in their library's [technical debt](https://github.com/boykopovar/AnyPS5/tree/main/docs/dev/debt) file - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source - [x] Generic behaviour, not specific to one title - [x] Depends on: none <!-- #PR, or none --> - [x] Fixes: none <!-- issue it closes as Fixes #N, or none --> - [x] Unblocks: none <!-- title ID and Game bring-up discussion, e.g. PPSA01325 #3232, or none --> - [x] GPUs tested: n/a <!-- for AGC, shader recompiler or VideoOut changes: vendor, model, driver and OS of each GPU the GPU tests ran on; otherwise n/a --> - [x] AI-assisted: yes <!-- yes / no --> 🤖 Generated with [Codex](https://openai.com/codex)
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!17765
No description provided.