Commit Graph

2024 Commits

Author SHA1 Message Date
Gjon Gojcevic 02166268ea test(libSceNgs2.native): run the waveform parse tests in their own executable
On Linux ngs2_atrac9 aborted without any output once TestParseFile was part of
its main(). The exception that TestCorruptSuperframeAtPageEnd throws in the
Ngs2 module and catches in main() has to resume through a cleanup landing pad
inside main(). That resume goes through the unwinder statically linked into the
test executable, which then fails with _URC_FATAL_PHASE2_ERROR and aborts
silently. Whether main() gets such a pad depends on what the compiler inlines
into it, so adding any function with non-trivial cleanups to that main() is
enough to trigger it.

Move the PCM and file parse tests into a new ngs2_parse executable and restore
Ngs2Atrac9.cpp to its upstream content, so the test that catches exceptions is
unchanged. The new executable has no catch and never relies on that path.
2026-10-07 09:49:31 -04:00
Gjon Gojcevic 1bdc37bb86 test(libSceNgs2.native): write the ParseWaveformFile test file where the guest path resolves
On Linux every absolute guest path is resolved under the working directory, so the temporary file in the host temp directory was not found. The test now asks ResolvePath_nid_no_patch for the host path of a guest path and writes the file there.
2026-10-06 22:14:23 -04:00
Gjon Gojcevic 74a7a1d9f1 fix(libSceNgs2.native): take (path, offset, info) in sceNgs2ParseWaveformFile and reject PCM data that does not fit
The call site of PPSA21402 sets only three argument registers, so the function has no size parameter. A data chunk that runs past the buffer or ends inside a frame returns INVALID_WAVEFORM_DATA instead of being shortened. The test no longer writes padding from a string literal.
2026-10-06 22:14:23 -04:00
Gjon Gojcevic 64230cf95a feat(libSceNgs2.native): implement sceNgs2ParseWaveformFile and parse 16-bit PCM waveforms 2026-10-06 22:14:23 -04:00
Dean 87ab98b9e9
Merge pull request #968 from ebarr24/codex/libc-stdio-binary
fix(libc): preserve guest stdio bytes on Windows
2026-10-07 15:13:48 +13:00
Dean a0f79d5b4f
Merge pull request #962 from JAB-dev/feat/ngs2-plain-module
feat(libSceNgs2): build libSceNgs2 from the libSceNgs2.native implementation
2026-10-07 15:13:07 +13:00
Dean 66e0a1e9c5
Merge pull request #1019 from fisherjoey/feat/agc-semaphore-memory-register-multiple
feat(agc): declare sceAgcSetSemaphoreMemory and sceAgcDriverRegisterMultipleResources
2026-10-07 15:04:53 +13:00
Dean 5f96e1e040
Merge pull request #1018 from Raghav314/feat/ajm-resample
feat(ajm): implement sceAjmBatchJobSetResampleParameters and sceAjmBatchJobGetResampleInfo
2026-10-07 14:47:49 +13:00
Dean ee391a5614
Merge pull request #1016 from ArjenS-LA/fix/autorun-posix-path-quoting
fix(relinker): quote literal autorun paths on POSIX
2026-10-07 13:11:16 +13:00
Dean e69f196f09
Merge pull request #1006 from Dextroid17/fix/agc-command-tests-full-mode
test(agc): fix the stale 32-bit WriteWait expectation and run the full suite
2026-10-07 13:10:03 +13:00
Joey Fisher 23a6859a51 feat(agc): declare sceAgcSetSemaphoreMemory and sceAgcDriverRegisterMultipleResources 2026-10-06 18:07:53 -06:00
raghav314 72be77590c feat(ajm): implement sceAjmBatchJobSetResampleParameters and sceAjmBatchJobGetResampleInfo
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 05:36:31 +05:30
Dean 4b0412fa97
Merge pull request #982 from ebarr24/codex/libc-wide-string-precision
fix(libc): keep wide printf precision on UTF-8 boundaries
2026-10-07 13:03:38 +13:00
Dean fde401d41f
Merge pull request #992 from CnRJay/feat/ppsa23566-missing-exports
feat(libs): declare the exports PPSA23566 imports that no library provides
2026-10-07 13:02:56 +13:00
Arjen Singh 6ac3ad5d1d fix(relinker): quote literal autorun paths on POSIX 2026-10-06 16:18:01 -07:00
Dextroid17 ea68e850ff test(agc): fix the stale 32-bit WriteWait expectation and run the full suite
WriteWait has truncated the reference and mask of a 32-bit wait since
9c2a7560 ("relaxed checks for what titles send"), but testMemory still
expected a reference above 32 bits to throw, so agc_command_tests failed
when run without arguments. ctest only registers the "defaults" mode, so
the stale expectation was never noticed.

Update the expectation to the truncating behaviour (the packet keeps the low
halves) and register the full mode as agc_commands so the packet, marker,
flip, register and memory cases are checked again.

Closes #1005.
2026-10-06 18:58:45 -04:00
Adrià ab9437e34d
feat(libkernel): implement scePthreadTestcancel and pthread_testcancel (#834) 2026-10-07 11:43:32 +13:00
Dean 23ba389799
Merge pull request #993 from CnRJay/fix/mutexattr-settype-einval
fix(libkernel): return EINVAL for unknown mutex attribute types
2026-10-07 11:43:11 +13:00
Adrià 09f8782378
feat(libSceAudio3d): implement sceAudio3dTerminate (#830) 2026-10-07 11:42:29 +13:00
Dean 25f311fa00
Merge pull request #559 from Phi1ow/implement-login-dialog
feat(logindialog): implement the libSceLoginDialog state machine
2026-10-07 11:41:57 +13:00
Dean b5c1d08bd9
Merge pull request #553 from Phi1ow/implement-userservice-foreground-and-ids
feat(userservice): implement foreground user, registered list, user colour and NP account id
2026-10-07 11:41:16 +13:00
Chad df98b8899e feat(libs): name the PPSA23566 stubs from the shadPS4 NID list and implement sleep
20 of the 31 NIDs have names in shadPS4's aerolib list. They are declared
under those names; POSIX sleep is implemented. The NpPartner001 and Psml
MFSR2 exports stay unnamed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 17:28:39 -05:00
Dean c1241ad0dc
Merge pull request #979 from hugodearaujo/fix/video-recording-open-signature
fix(libSceVideoRecordingP): correct the sceVideoRecordingOpen signature
2026-10-07 11:11:12 +13:00
JAB e289b56e6f
feat(libSceNgs2.native): implement sceNgs2RackGetInfo, sceNgs2VoiceGetPortInfo and sceNgs2VoiceQueryInfo (#958)
RackGetInfo reports the rack's handles, buffer, id, uid, option limits,
render count and active voices. VoiceGetPortInfo reports a port's matrix,
volume and destination. VoiceQueryInfo answers info id 0x4001 with the
voice channel count and throws for other ids. Assumptions are recorded in
TechnicalDebt.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 11:10:30 +13:00
Dean 2b45df4706
Merge pull request #905 from gookie-dev/feat/pad-vr-controller-exports
feat(libScePad): declare the VR controller exports
2026-10-07 11:07:02 +13:00
Dean 24eac1c445
Merge pull request #886 from Fishybeing/fix/http-status-line-overflow
fix(http): count sceHttpParseStatusLine as implemented
2026-10-07 11:06:19 +13:00
Dean 97a6604f81
Merge pull request #883 from Fishybeing/fix/memorypool-header-guard
fix(libkernel): correct the MemoryPool.hpp include guard
2026-10-07 11:05:38 +13:00
Dean 84c058756b
Merge pull request #870 from aryanrawatispro-ship-it/feat/player-invitation-dialog-result
feat(playerinvitationdialog): implement scePlayerInvitationDialogGetResult
2026-10-07 11:05:26 +13:00
Dean 762bab6f9a
Merge pull request #863 from LeandroLP23/feat/font-writing-line-ordering-space
feat(font): implement sceFontWritingLineGetOrderingSpace
2026-10-07 11:04:45 +13:00
Chad 69973800a7 fix(libkernel): return EINVAL for unknown mutex attribute types
UFC 6 (PPSA23566) passes type 0 to pthread_mutexattr_settype during
startup. libkernel rejects it with EINVAL and leaves the attribute
unchanged, as fpPS4's decompiled body does, instead of aborting.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 17:04:06 -05:00
Chad 7cbf45b660 feat(libs): declare the exports PPSA23566 imports that no library provides
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 17:04:05 -05:00
Dean edf90b169f
Merge pull request #824 from LeandroLP23/feat/font-get-font-resolution
feat(font): implement sceFontGetFontResolution
2026-10-07 11:04:01 +13:00
Dean b3c0365824
Merge pull request #823 from LeandroLP23/feat/font-glyphs-count-char-glyph-code
feat(font): implement sceFontGetFontGlyphsCount and sceFontGetCharGlyphCode
2026-10-07 11:03:19 +13:00
Phi1ow 0178b6530e fix(logindialog): report user-cancelled and write only the leading result int32
sceLoginDialogGetResult zeroed 8 bytes of a result struct of unknown size and reported result 0
with user id 0. It now writes only the leading int32 (USER_CANCELED), like
sceWebBrowserDialogGetResult and like the sign-in dialog, so a title takes its "no user chosen"
path instead of reading an invalid user id. Records the dialog in the silent-stubs list in
docs/dev/TechnicalDebt.md.
2026-10-06 23:46:00 +02:00
Phi1ow fae2c8e6be feat(logindialog): implement the libSceLoginDialog state machine
The seven libSceLoginDialog exports were throwing stubs. They now implement the common-dialog
state machine (NONE -> INITIALIZED -> RUNNING -> FINISHED), mirroring the existing
libSceSigninDialog: the local user is always signed in, so the dialog finishes as soon as it
opens and a title waiting on it never blocks.

- sceLoginDialogInitialize -> INITIALIZED, or 0x80B80004 if already initialized
- sceLoginDialogOpen -> validates the state and the parameter, then FINISHED
- sceLoginDialogUpdateStatus / sceLoginDialogGetStatus -> the status
- sceLoginDialogGetResult -> zeroes the result (signed in) once FINISHED
- sceLoginDialogClose -> ok, or 0x80B80003 when not initialized
- sceLoginDialogTerminate -> NONE, or 0x80B80003 when not initialized

The status values and the shared common-dialog error codes match libSceSigninDialog and
libSceWebBrowserDialog. Adds a CMakeLists.txt so the library can carry its guest test.

New test core/libs/tests/GuestLoginDialog.cpp drives the whole machine (the not-initialized
and already-initialized errors, the argument and not-finished errors, open/get-result/close
and terminate). It fails on main (the stubs throw) and passes with the change.
2026-10-06 23:46:00 +02:00
Phi1ow 55cbd2d6f1 feat(userservice): implement foreground user, registered list, user colour and NP account id
Four exports that titles call during start-up were missing. They now follow the
single-user / offline model already used in this file (sceUserServiceGetInitialUser,
sceUserServiceGetLoginUserIdList, sceUserServiceGetPlatformPrivacyWs1):

- sceUserServiceGetForegroundUser(int*) -> the initial user
- sceUserServiceGetRegisteredUserIdList(UserServiceRegisteredUserIdList*) -> initial
  user in slot 0, the other 15 slots invalid
- sceUserServiceGetUserColor(int, int*) -> blue (0)
- sceUserServiceGetNpAccountId(int, uint64_t*) -> 0 (no PSN account linked)

Adds UserServiceRegisteredUserIdList (int[16]) to SceTypes.hpp and a CMakeLists.txt
so the library can carry its guest test. Signatures follow the public OpenOrbis SDK
headers.

New test core/libs/tests/GuestUserService.cpp checks the valid returns, the pointer
and wrong-user-id error paths; it fails without the change (the symbols are undefined)
and passes with it.
2026-10-06 23:42:15 +02:00
hugodearaujo 956a8b7d5f fix(libSceVideoRecordingP): correct the sceVideoRecordingOpen signature
sceVideoRecordingOpen takes the target path, the recording param, the
heap and the heap size, not (buffer, size, param). It still throws.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 18:29:36 -03:00
Ethan Barr 62de7ab8ac fix(libc): keep wide printf precision on UTF-8 boundaries 2026-10-06 14:28:56 -07:00
Dean 5fc8755f4c
Merge pull request #961 from JAB-dev/feat/ngs2-mastering-gain
feat(libSceNgs2.native): mastering voice gain parameter
2026-10-07 10:22:26 +13:00
Dean 2775bb328a
Merge pull request #945 from Kikoarl/feat/prx-msgdialog-native-getstatus
feat(libSceMsgDialog.native): implement sceMsgDialogGetStatus
2026-10-07 10:21:42 +13:00
Dean a1107d2adf
Merge pull request #939 from CnRJay/feat/keyboard-jis-key2char
feat(libSceKeyboard): translate the 106-key arrangement in sceKeyboardGetKey2Char
2026-10-07 10:20:49 +13:00
CnR 7e3dcbc27e
feat(libkernel): implement sceKernelReleaseFlexibleMemory (#952)
* feat(libkernel): implement sceKernelReleaseFlexibleMemory

Unmaps the range through sceKernelMunmap, which returns its pages to
the flexible memory budget, as fpPS4 and prosper do.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(libkernel): keep the flexible memory release check apart from the batch map checks

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 10:20:07 +13:00
Dean 957171aeb3
Merge pull request #795 from CnRJay/feat/http2-cookie-box
feat(libSceHttp2): implement cookie boxes and requests without a content length
2026-10-07 10:19:25 +13:00
Dean 0056fc5027
Merge pull request #793 from CnRJay/feat/barrierattr-process-shared
feat(libkernel): accept PTHREAD_PROCESS_SHARED barrier attributes
2026-10-07 10:18:43 +13:00
Dean 0372190240
Merge pull request #911 from Pacuka/fix/audiodec-native
fix(audiodec): build libSceAudiodec.native from the libSceAudiodec sources
2026-10-07 10:18:31 +13:00
Dean 3e79925c4b
Merge pull request #912 from Pacuka/fix/trophy2-gameinfo-null-data
fix(trophy2): accept a null data or details in sceNpTrophy2GetGameInfo
2026-10-07 10:17:49 +13:00
Dean 943be291a6
Merge pull request #893 from merwie/fix/avplayer-frame-at-jump-while-paused
fix(avplayer): deliver the frame at a jump while paused
2026-10-07 10:17:07 +13:00
Dean a876f2392f
Merge pull request #892 from adriadam10/feat/systemservice-music-player
feat(libSceSystemService): implement Disable/ReenableMusicPlayer
2026-10-07 10:16:24 +13:00
Dean 1a211f4f5c
Merge pull request #891 from adriadam10/feat/razor-cpu-flush-occurred
feat(libSceRazorCpu): implement sceRazorCpuFlushOccurred
2026-10-07 10:15:42 +13:00
Dean df247280db
Merge pull request #890 from alfalfa-star/fix/pad-read-state-invalid-handle
fix(pad): return INVALID_HANDLE from scePadReadState for an unknown handle
2026-10-07 10:15:00 +13:00