Commit Graph
7981 Commits
Author SHA1 Message Date
orezraey 7735835ba8 Merge remote-tracking branch 'origin/main' into fix/libscecescs-eucjp-measured-ps5
# Conflicts:
#	core/libs/tests/GuestCes.cpp
#	docs/dev/debt/libSceCesCs.md
2026-10-23 08:02:15 -03:00
xXPBSXxandClaude Sonnet 5.5 cb20a0563c docs(debt): note how titles call inet_pton
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 13:02:04 +02:00
orezraey 803744fe85 Merge remote-tracking branch 'origin/main' into fix/libscecescs-scalar-measured-ps5
# Conflicts:
#	core/libs/prx/libSceCesCs/Export.cpp
#	core/libs/tests/GuestCes.cpp
#	docs/dev/debt/libSceCesCs.md
2026-10-23 07:55:22 -03:00
xXPBSXxandClaude Sonnet 5.5 79b6e97632 docs(debt): note how a title calls sceHmd2Open and sceHmd2Initialize
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:48:07 +02:00
Daniele Giovane 13b1892fdd Merge main and address review for PR 8495 2026-10-23 12:45:54 +02:00
Daniele Giovane bc00fafac0 Merge main and address review for PR 9160 2026-10-23 12:45:54 +02:00
Dean e3d03fbae6 Merge pull request #7930 from AnthonyClemens/perf/agc-skip-empty-indirect
perf(agc): skip CPU-path indirect draws that draw nothing before buil…
2026-10-23 23:45:49 +13:00
dotaku22 171419e958 feat(libc): implement buffered stream purge 2026-10-23 12:42:22 +02:00
Dean 812ed15875 Merge pull request #9047 from VakzOs/feat/libressl-des
feat(libSceLibreSsl): implement DES_set_key, DES_ecb_encrypt and DES_set_odd_parity
2026-10-23 23:38:53 +13:00
xXPBSXxandClaude Sonnet 5.5 8b9c212d14 docs(debt): note how a title uses the sceNetCtlGetInfo host name codes
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:37:55 +02:00
xXPBSXxandClaude Sonnet 5.5 735701a30a docs(debt): note the formats a title passes to sceAudioOut2PortCreate
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:37:44 +02:00
xXPBSXxandClaude Sonnet 5.5 e9b842569a docs(debt): shorten the sceKernelFtruncate title note below the entry length limit
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:37:11 +02:00
Santhosh Kumar ba318138b5 chore(libSceFreeType): sync main and preserve bitmap debt placement 2026-10-23 16:03:57 +05:30
JAB-devandClaude Sonnet 5.5 1c335b6ea9 Merge branch 'main' of https://github.com/boykopovar/AnyPS5 into fix/audioout2-speaker-info-errors
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:33:19 +02:00
BunnyFlandClaude Opus 5.5 9aa0f22dc7 feat(libkernel): implement the system-ex version, lower-limit and trace memory queries
sceKernelGetSystemExVersion, sysKernelGetLowerLimitSysexVersion,
sysKernelGetLowerLimitUpdVersion and sceKernelGetTraceMemoryStats were
NotImplemented stubs in libkernel_sys. libkernel, libkernel_sys and
libkernel_web of firmware 13.42 answer them without asking the kernel:
empty strings, a zero version and zero statistics, with the null checks
and return codes the firmware uses, including the plain 22 of
sceKernelGetSystemExVersion.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-23 12:29:49 +02:00
Dean Galvin f9cbe3f1ac docs(libSceUserService): keep the keyboard type entry under the length limit 2026-10-23 23:29:29 +13:00
Santhosh Kumar ebcdd68c65 chore(libSceFreeType): sync current main and preserve merged features 2026-10-23 15:58:44 +05:30
Santhosh Kumar 82edad6701 fix(libSceLibreSsl): isolate packaged test dependencies on POSIX
Sync current main and keep the unpatched libc test dependency Windows-only.
2026-10-23 15:56:49 +05:30
Dean Galvin 9ec09517ee fix(libSceConvertKeycode): treat oversized app metadata as a PS5 title
AppMetadata throws length_error for a title or title ID that does not fit its
buffer, which the title ID lookup did not catch, so a homebrew title with a long
ID made sceConvertKeycodeGetImeKeyboardType throw instead of using the PS5
fallback. Catch it with the other metadata failures and cover oversized,
malformed and missing metadata at the export. sceUserServiceGetKeyboardType also
gets a test that a malformed ANYPS5_LANGUAGE is rejected with the output left
untouched, and the debt entries say so.
2026-10-23 23:25:25 +13:00
Dean 513ca7e558 Merge pull request #9141 from MarrasFederico/feat/kernel-sys-pthread-scope-atfork
feat(libkernel_sys): implement the scePthread scope, atfork and setconcurrency forms
2026-10-23 23:18:24 +13:00
jacob6769 1d5d71aa21 Merge remote-tracking branch 'origin/main' into feat/ces-korean-big5-scalars
# Conflicts:
#	core/libs/prx/libSceCesCs/Export.cpp
#	core/libs/prx/libSceCesCs/PendingExports.cpp
#	docs/dev/debt/libSceCesCs.md
2026-10-23 19:17:52 +09:00
xXPBSXxandClaude Sonnet 5.5 cdf5ac5dc0 docs(debt): shorten the RackGetInfo title sentence under the entry length limit
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:11:52 +02:00
xXPBSXxandClaude Sonnet 5.5 dab63bbea7 docs(debt): give the call site and separate the title observation in the RackGetInfo entry
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:11:43 +02:00
xXPBSXxandClaude Sonnet 5.5 371aab6bdf docs(debt): note the buffer size a title passes to sceNgs2RackGetInfo
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:11:36 +02:00
JAB-devandClaude Sonnet 5.5 3a66884153 Merge branch 'main' of https://github.com/boykopovar/AnyPS5 into feat/agc-4-4-4-4-partial-writes
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:09:33 +02:00
JAB-devandClaude Sonnet 5.5 8415906b22 Merge branch 'feat/agc-4-4-4-4-color-target' into feat/agc-4-4-4-4-partial-writes
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:09:28 +02:00
Dean 59078c05f5 Merge pull request #8972 from simonbronk/feat/libSceCesCs-sbc-mbcs-utf16-utf32
feat(libSceCesCs): add UTF-16 and UTF-32 forms of the SBC and MBCS string conversions
2026-10-23 23:06:53 +13:00
MD5Visual 167d7f3f9e docs(debt): note two reimplementations agree on four libSceFios2 date and handle prototypes 2026-10-23 13:04:32 +03:00
JAB-devandClaude Sonnet 5.5 8b7dd6beb7 Merge branch 'main' of https://github.com/boykopovar/AnyPS5 into feat/agc-4-4-4-4-color-target
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-23 12:00:34 +02:00
orezraey ac35cf8c9c Merge remote-tracking branch 'origin/main' into fix/libc-gethostname-measured-ps5 2026-10-23 06:55:24 -03:00
orezraey e26d09b41d Merge remote-tracking branch 'origin/main' into docs/libkernel-sem-timedwait-measured-ps5 2026-10-23 06:55:19 -03:00
orezraey 5c7cdfda26 Merge remote-tracking branch 'origin/main' into fix/libkernel-close-standard-descriptors-measured-ps5 2026-10-23 06:55:14 -03:00
orezraey afcba0fa55 Merge remote-tracking branch 'origin/main' into docs/libc-math-measured-ps5 2026-10-23 06:55:05 -03:00
orezraey 8c2c979aec Merge remote-tracking branch 'origin/main' into fix/libkernel-posix-thread-attr-measured-ps5
# Conflicts:
#	docs/dev/debt/libkernel.md
2026-10-23 06:55:00 -03:00
thuanquangandClaude 175d986c28 perf(agc): create the host import of a linear color target in registered memory
A linear color target got a resident image only when its memory already
had a host import (#6892). Every other draw into it was synchronous:
copied in, drawn, waited for on the CPU and copied back. #6892 only
looked the import up because a first version that made it broke
agc_driver_pixel_ancillary_word and agc_driver_pixel_fixed_point_position:
the import over a short-lived block was compared, and the next block
allocated at the same address stayed outside the write watch. A page
committed again inside an excluded block is watched again since #6759.

On a lookup miss the draw now makes the import itself, with the new
ColorTarget requester, when its registered ranges are writable, the
whole import run is write-watched and the import keeps it watched: a
separate alias of shared memory, a direct import of private memory that
settles on Windows (1 MiB or more, when the import probe keeps the
watch and a settle queue exists), or an import the probe keeps watched
on other systems, where a dma-buf import must stay watched too if the
range has shared backing. Private pages that the write watch armed
read-only count as writable when their guest protection is, because the
import opens them (a resident direct-memory run the CPU has not stored
to since its last collect). The gate's scan stops at the first page
that decides a refusal, and a run of private memory whose direct import
would be compared is refused after one page query. A refusal is
remembered for its run until the registry, the committed pages
(Windows) or the write watch change, or a shared alias is mapped over
the run, so a target that stays synchronous costs a lookup per draw.
importRunAt checks this after its remembered failures and refusals and
before it retires or evicts anything, through the helpers its own
decision now uses: importWatching (settled, watched host-pointer and
dma-buf imports) and importPages (the Windows page scan). A target whose
import would be compared stays synchronous, because a compared import
makes every refresh of the resident image compare the whole target. A
target over an import that already exists is resident as before, with
ExistingHostImportFor as the fast path, and APS5_NO_RESIDENT_LINEAR=1
still keeps every linear target synchronous.

This is the case draft #1191 (MichonGoddijn231849) was to bring back
on top of #6892 once partial-block write-watch coverage existed.

agc_driver_linear_target_import_creation covers a target in freshly
registered, write-watched memory (the draw is recorded, the target is
imported and stays watched), a block freed and allocated again at the
same address (it is watched, and the next draw starts from the CPU's
bytes), a resident direct-memory run armed read-only by the write watch
(the draw is recorded and the target imported; Windows), the gate over
armed and read-only private memory (a compared import of an armed run is
refused without opening it, memory committed read-only behind a writable
registry range is refused without a count, an armed run is imported
where imports stay watched; Windows), a 64 KiB block whose import would
be compared (no import, a synchronous draw, the block stays watched), a
1 MiB block the guest registered read-only (no import, a synchronous
draw), a 1 MiB run with one 64 KiB block outside the write watch
(refused, the target stays watched), and the same run once that block is
committed again (the refused run is imported; Windows).
On other systems the test forces ImportWatch::Watch, so the watched
cases also run where imports are compared (lavapipe in CI). The import
requester tests count the new requester and check that it makes no
compared import, no import of a range the guest cannot write and no
import of memory outside the write watch.

Co-Authored-By: Claude <[email protected]>
2026-10-23 16:54:49 +07:00
thuanquangandClaude 14d263c416 fix(agc): store the exact union of a linear target's drawn rectangles
A drawn target kept the bounding box of its draws' scissors, so a store
at a completion point also wrote the pixels between two disjoint
scissors, over CPU stores made there after the draws.

- The target keeps the clipped scissor rectangles. Two merge only when
  their union is a rectangle: one inside the other, or the same columns
  overlapping or touching in rows, or the same rows overlapping or
  touching in columns.
- The store still copies the rectangles' bounding box out of the image,
  but writes to guest memory, for each row, only the union of the
  column runs of the rectangles that cover that row.
- At most 16 rectangles wait for a completion point: the draw that
  brings a 17th stores the target right after it, with all of them.
- A target the rectangle store does not cover (attachment proxy, several
  mips or layers, 3D or DCC surface, results of a dispatch, fill or
  copy) is stored after each draw again, instead of whole at the next
  completion point.
- LinearTargetRectangleBound draws and waits once before its draws, so
  the target's upload runs before the CPU stores instead of in the same
  batch, adds CPU stores between the two scissors, and adds a case with
  17 one-row scissors and a CPU store between two of them.

Co-Authored-By: Claude <[email protected]>
2026-10-23 16:54:40 +07:00
thuanquangandClaude 24e2c28391 fix(agc): keep drawn linear target results through flush races and CPU-kept hooks
- MarkDrawn registers the scissor while any layer is pending instead of
  while the image is dirty. A flush on another thread can take the image
  out of the pending set between MarkSliceDirty and the registration;
  layerPending changes only under the GPU lock, so the flusher, which
  reads the drawn area after taking that lock, stores the widened area.
- AccessKeptByCpu no longer skips or evicts a drawn target. Its store
  writes CPU-stamped blocks inside the drawn rectangle, so the hook's
  CPU-kept rule would drop the draw's results.
- A drawn target that is stored whole keeps main's rule that CPU-written
  64 KiB blocks stay the CPU's.
- A linear target that is no longer cached is stored after its draw, as
  before: the pending registry holds raw pointers.
- LinearTargetCompletionPoints skips without host import, where the
  target is never resident. LinearTargetCpuWrites adds a driver read of
  the target between the CPU stores and the store.

Co-Authored-By: Claude <[email protected]>
2026-10-23 16:54:40 +07:00
thuanquangandClaude c7f9eaa30e fix(agc): close two ordering gaps of the drawn linear target stores
- A flush from a thread without the GPU lock takes the lock before it takes a drawn target out of the pending set, so a flip, label or interrupt on the queue worker cannot run between the two and get ahead of the target's store.
- A label written on the GPU stores the drawn targets first and submits that store with the label, so the label's end-of-pipe interrupt is not held back to a later submission.
- The pending-writer check skips the target's own earlier stores only when the flush stores that target alone.

Co-Authored-By: Claude <[email protected]>
2026-10-23 16:54:39 +07:00
Dean c188e01a42 Merge pull request #9315 from MarrasFederico/feat/ngs2-system-rate-grain-codes
fix(libSceNgs2.native): return the module's codes from sceNgs2SystemSetSampleRate and sceNgs2SystemSetGrainSamples
2026-10-23 22:54:32 +13:00
orezraey 4ef70cafab Merge remote-tracking branch 'origin/main' into fix/libkernel-sysctl-system-measured-ps5 2026-10-23 06:54:23 -03:00
orezraey 41829acd41 Merge remote-tracking branch 'origin/main' into fix/librtc-rfc3339-precise-measured-ps5 2026-10-23 06:54:18 -03:00
orezraey e2b87712dd Merge remote-tracking branch 'origin/main' into fix/libkernel-pthread-attr-measured-ps5 2026-10-23 06:54:13 -03:00
orezraey 82b3fedc95 Merge remote-tracking branch 'origin/main' into fix/libc-strftime-measured-ps5
# Conflicts:
#	docs/dev/debt/libc.md
2026-10-23 06:54:02 -03:00
Adrià e5d9c923db Merge pull request #6951 from alfalfa-star/perf/agc-span-mirror
perf(agc): memoize host import run bounds per lease snapshot
2026-10-23 11:52:55 +02:00
PacukaandClaude Opus 5.5 6edd825f14 fix(libSceAgcDriver): update MEM_SEMAPHORE words atomically
A type 0 signal read the semaphore, added one and wrote it back, so an
increment made by a CPU thread or another queue in between was lost.
Signals now store or add with atomic operations and a wait takes one
with a compare-exchange. The new test races two queues and a CPU thread
incrementing the same word.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-23 11:52:02 +02:00
thuanquangandClaude 0ec6032d23 fix(agc): store resident linear color targets at completion points, limited to their drawn rectangle
A recorded draw into a resident linear color target stored the whole
image to guest memory right after the draw. Every draw copied the full
surface, waited for the previous draw's store in the open batch (the
pending-writer check of FlushPending), and the recorded copy landed over
CPU stores made after Draw returned (#8152).

A draw now records its scissor, clipped to the image, as a union
rectangle in the target and lists the target as drawn. The listed
targets are stored before each point where the guest can first observe
the draws' completion: a flip (inside its locked block, before the
flip's submit, so the flip's end-of-pipe interrupt and the presenter
follow the store), a drain (which covers APS5_SYNC_FLIP=1),
VulkanDevice::WaitIdle, a label the GPU writes for the graphics queue
(WriteLabelOnGpu), and an interrupt-only RELEASE_MEM in
preparePacketMemory and in commitLabel, which submit the store's batch
before the interrupt can be delivered. The idle store, the access hooks
and the eviction store are unchanged and also store by rectangle.

A store of a drawn target copies the rectangle out of the image and
writes it row by row at the guest pitch into the host import, stamped
with one MarkWritten per run of 64 KiB blocks. A block that only other
driver stores wrote since the target's generation keeps the old rule.
In a block the CPU wrote, or that changed outside the write watch, only
the rectangle's rows are stored, so CPU stores outside the rectangle
stay, and the target re-uploads at its next use. A target with an
attachment proxy, several mips or layers, a 3D or DCC surface, or
results of a dispatch, fill or copy is stored whole at the same points.
A store no longer waits for the same target's previous store: the
pending-writer check skips the write notes of the target's own stores
when it has a host import.

APS5_PROFILE_DRAW adds the drawn targets' stores by reason and the
pending drawn targets (count, MiB, oldest) to the [storage] line.

The tests cover a target that stays pending across draws and labels
until WaitIdle without a submission, #8152's CPU stores after Draw
(ported from #8246, seeded and unseeded, inside and outside the write
watch), CPU stores outside the drawn rectangle and in the gap before a
target that starts past a 64 KiB boundary, and a flip, a drain, a label
and an interrupt-only RELEASE_MEM through AgcDriver::Submit with the
queue held by a WAIT_REG_MEM, inside and outside the write watch.

Co-Authored-By: Claude <[email protected]>
2026-10-23 16:51:34 +07:00
PacukaandClaude Opus 5.5 287e3812e7 feat(libSceAgcDriver): execute MEM_SEMAPHORE signals and waits
MEM_SEMAPHORE (0x39) threw "cooperative command-queue waits are not
implemented". A signal now writes 1 (signal type 1) or adds 1 (signal
type 0) to the 64-bit semaphore; a wait polls until it is non-zero and
takes one. Mailbox waits throw.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-23 11:48:36 +02:00
Dean ff191e29d1 Merge pull request #9382 from MarcZX10/codex/libkernel-sys-sched-interval
feat(libkernel_sys): implement sched_rr_get_interval
2026-10-23 22:47:27 +13:00
Dean 348157914f Merge pull request #6218 from harry-z-kang/codex/issue-6119-packed-storage
fix(agc): support packed 16-bit storage images
2026-10-23 22:44:30 +13:00
Dean Galvin 835c2995ed feat(libSceUserService): report the keyboard type of the system language
sceUserServiceGetKeyboardType now returns the keyboard type of the configured
system language from the repository owner's table (languages 0 to 29), with 20
(US English) for a language outside it. The input variants stay 0, the only
value the table gives for Japanese and Traditional Chinese.

sceConvertKeycodeGetImeKeyboardType takes the PS4 client rule from the title ID
prefix (CUSA is PS4); a missing or custom ID is treated as PS5. Tests walk the
owner's table through both calls and the title ID cases; both debt entries
updated.
2026-10-23 22:40:29 +13:00