Commit Graph
8546 Commits
Author SHA1 Message Date
Adrià 462eb4d9f1 Merge pull request #5493 from Roojool/contrib/g14-kqueue-watch
fix(libkernel): name the failing vnode watch in the kqueue notification error
2026-10-15 00:27:23 +02:00
fdfawef324andClaude Opus 5.5 9f96444c4a feat(libSceNpManager): register NP state callbacks and report signed-out from sceNpCheckCallback
sceNpRegisterStateCallback and sceNpRegisterStateCallbackA stored nothing,
the unregister calls always succeeded and sceNpCheckCallback did nothing,
so a title that waits for its NP state callback never learned the user's
state. #1277 reports that Minecraft Preview (PPSA19639) needs the callback
(stop 2).

sceNpRegisterStateCallbackA now keeps up to 8 callbacks and returns the
slot plus 1. A null callback returns INVALID_ARGUMENT, a callback that is
already registered CALLBACK_ALREADY_REGISTERED and a ninth one
CALLBACK_MAX (0x8055001D). sceNpUnregisterStateCallbackA returns
INVALID_ARGUMENT for an id outside 1..8 and CALLBACK_NOT_REGISTERED for an
empty slot. The legacy sceNpRegisterStateCallback keeps one callback with
the same errors. The rules follow shadPS4
src/core/libraries/np/np_manager.cpp @15abf68c9b52 (RegisterStateCallbackA
and UnregisterStateCallbackAById L857-L901, the legacy pair L981-L1005,
ORBIS_NP_STATE_CALLBACK_MAX L36) and np_error.h L38.

Each registration is marked pending. sceNpCheckCallback takes the pending
registrations under the lock and calls them after releasing it, on the
calling thread, with SIGNED_OUT for the initial user 0x10000000. For the A
form this follows KytyPS5 src/libs/network.cpp @9e41d8320a27
(NpRegisterStateCallbackA L4021-L4034 marks the registration pending,
NpCheckCallback L3959-L3974 delivers it once). KytyPS5 never calls the
legacy callback (NpRegisterStateCallback and NpUnregisterStateCallback,
L4009-L4019, do nothing). The legacy callback is called as
(user, SIGNED_OUT, nullptr, userdata), as in shadPS4, which passes an NpId
only for SIGNED_IN (L823, L938-L940).

shadPS4 queues SIGNED_OUT from the user service login event instead
(DispatchPendingNpStateCallbacks L903-L962), and the same event calls the
reachability callback once with UNAVAILABLE (L922-L931, L959-L961). The
reachability callback is still not called here. These differences and the
unmeasured console behaviour are recorded in
docs/dev/debt/libSceNpManager.md.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-14 18:12:19 -04:00
fdfawef324andClaude Opus 5.5 0ee7af6f5f feat(agc): accept SAMPLE_STREAMOUTSTATS events without a destination in EVENT_WRITE
EVENT_WRITE (PM4 opcode 0x46) with event type SAMPLE_STREAMOUTSTATS1-3
(0x01-0x03) or SAMPLE_STREAMOUTSTATS (0x20) failed submission validation
with "EVENT_WRITE event type 1 is not implemented". Minecraft Preview
(PPSA19639, discussion #1277, stop 9) submits a 2-dword type-1 packet
while entering a world, and the GPU thread aborted intermittently.

The four values are VGT_EVENT_TYPE entries in Linux
drivers/gpu/drm/amd/include/navi10_enum.h L14155-14188 at
0fcb05b72344f40806cbe810de8872f1698bf053.
drivers/gpu/drm/amd/amdgpu/nvd.h L326-347 at the same commit documents
these events only with the sampling index (3, or
EVENT_INDEX__SAMPLE_STREAMOUTSTATS* 8-11 on gfx10), followed by
ADDRESS_LO/HI. The 2-dword index-0 packet has no destination dwords, and
what the CP does with it is neither documented nor measured. AnyPS5 does
not emulate the VGT stream-out counters, so there is nothing to sample.
Packet execution already skips EVENT_WRITE.

These event types are now accepted on the graphics queue as 2-dword
packets with event index 0. The sampling indices 3 and 8-11 throw that
stream-out statistics sampling to memory is not implemented, before the
size and reserved-bit checks. Other indices, other sizes and the compute
queue still throw.

sceAgcDcbEventWrite ignores the address for every event type except 0x38
and 0x39, so a call with one of these event types and an address now
builds a packet that validates and writes nothing. This is recorded in
docs/dev/debt/libSceAgcDriver.md with the unmeasured hardware behaviour.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-14 18:12:16 -04:00
Adrià 922abe6a4e Merge pull request #5892 from WallisSkill/fix/cat-quest-3-ppsa15065
perf(agc): compare sampled snapshots outside the write watch only after a write-watch mark
2026-10-15 00:05:10 +02:00
Adrià 596a0d70aa Merge pull request #5472 from eljackjoestar-cmd/codex/rgba8-uint-force-degamma
fix(shader): decode forced degamma on biased RGBA8_UINT samples
2026-10-15 00:01:33 +02:00
David 84f72fc057 docs(debt): record that guest GS accesses trap in Windows output 2026-10-15 01:57:53 +04:00
Dean 8ae436891a Merge pull request #5181 from ThatsLeo/perf/shader-compact-resource-plans
perf(shader): keep only evaluable branch conditions in resource plans
2026-10-15 10:56:57 +13:00
Adrià 6870cc26ba Merge pull request #5492 from billythemenace2/fix/shader-lds-add-f32-denormals
fix(shader): flush ds_add_f32 denormals and NaNs as the hardware does
2026-10-14 23:53:34 +02:00
Adrià 038c83b9ba Merge pull request #5446 from Nesyth/fix/agc-depth-surface-from-storage-writes
fix(agc): start a new depth surface from the storage writes over its plane
2026-10-14 23:51:42 +02:00
KauaandClaude 6f5f176aa6 fix(psml): name two exports that only had NIDs
Co-Authored-By: Claude <[email protected]>
2026-10-14 23:48:29 +02:00
Dean 9bec202332 Merge pull request #5517 from ps54all/feat/libsceajm-opus-family255-multistream
feat(ajm): decode Opus mapping family 255 with several channels
2026-10-15 10:48:06 +13:00
Adrià FranchandClaude de0cd00eb1 docs(build): document APS5_TRACE_DRAW_PROGRAMS
Co-Authored-By: Claude <[email protected]>
2026-10-14 23:39:27 +02:00
Adrià Franch 1df5ae9a33 docs(debt): cube faces read through DIM 2D blend neighbouring faces near the edges 2026-10-14 23:39:07 +02:00
billythemenace2andClaude Opus 5.5 3b96840e68 fix(shader): read cube T#s through DIM 2D image_sample and image_load as face 0
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-14 23:37:33 +02:00
Ondra97 241053ad9f fix(libkernel): preserve condition signals across cancellation 2026-10-14 23:34:45 +02:00
Dean Galvin d16745be14 docs(agc): record the accepted VGT_SHADER_STAGES_EN 0x02002008 as debt 2026-10-15 10:33:50 +13:00
mitul72 e52e140f5c fix(shader): read explicit-LOD 2D samples through 1D T#s as measured
A 2D image_sample_l through a 1D T# now takes the 1D runtime mode, as
image_sample_lz already does, instead of failing the runtime image
interface. Measured on RDNA2 (gfx1036) with tools/hw-oracle against the
same sample with DIM 1D: u inside, on and past the edges, v of 0, 0.5, 1,
-0.25 and 3, LOD -1 to 6 on a 5-level R32_FLOAT texture, point, linear and
linear-mip filtering, wrap, clamp and border addressing, and HEIGHT or
DEPTH 3. All 4725 rows matched: the 1D T# decides the addressing and v is
ignored.

The execution test samples a 5-level 1D T# with distinct mip contents at
LODs -1 to 6, fractional ones included, with u inside, on and past the
edges, under point filtering with wrap and clamp and linear filtering with
linear mips and wrap, clamp and border addressing. Every result must match
the same image_sample_l with DIM 1D bit for bit; point-filtered results
must also be the expected texel of the expected level, and linear-mip
results the blend of the two levels the LOD selects.
2026-10-15 10:33:22 +13:00
SorabandClaude Opus 5.5 404075b0a6 perf(agc): compare sampled snapshots outside the write watch only after a write-watch mark
On Windows every direct host import leaves the write watch, and a sampled
texture snapshot over it was compared with guest memory at every lookup:
its generation stays 0, so UnchangedSince never holds. ASTRO BOT
(PPSA21564) compared about 31 GB per 10 s at the title.

The lookup now keys such a snapshot by UntrackedHint, NewestStamp,
ForgetSerial and the recorder's newest write note, taken before the
snapshot is read or compared, as StorageTexture::compareUntracked does,
and skips the compare while the key is unchanged and no recorded work
writes the surface. The byte compare still decides after any mark.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-14 23:30:29 +02:00
eljackjoestar-cmd 76eb60af61 fix(shader): decode forced degamma on biased RGBA8_UINT samples 2026-10-14 23:25:53 +02:00
Yossi Yadgar e4d0e2dc77 docs(debt): narrow the last-vertex strip entry to vertex slot reads 2026-10-15 00:15:10 +03:00
Adrià 0ae1deb850 Merge pull request #5906 from TheAggie/perf/agc-draw-snapshot-reuse
perf(agc): reuse draw snapshots across draws that nothing wrote between
2026-10-14 23:10:06 +02:00
snipeTRandClaude Opus 5.5 5b697f8c47 feat(opus): decode at 8, 12, 16 and 24 kHz
Accept every creation rate listed by the public decoder research in
libSceOpusDec and libSceOpusCeltDec, resampling FFmpeg's 48 kHz output.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-15 00:06:48 +03:00
milescovielloandClaude Opus 5.5 d47651847d fix(pad): accept vibration mode 5
Crimson Desert (PPSA25286) calls scePadSetVibrationMode(handle, 5)
at start-up, and main rejects any mode above 3 with
SCE_PAD_ERROR_INVALID_ARG (0x80920001). The title then carries on
with the call failed.

The modes are not documented. SharpProspero names 1 (advanced) and 2
(compatible); mode 3 was accepted for PPSA21480. The call now also
accepts 5, which a shipped title passes, and keeps rejecting the values
no title has been seen to use (4, 6 and above). The mode is stored as
before and has no other effect.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-14 21:05:40 +00:00
notaxeltvandCursor 784cb4d3db feat(libScePlayerSelectionDialog): run common-dialog state machine without UI
Co-authored-by: Cursor <[email protected]>
2026-10-14 23:00:30 +02:00
Adrià f2aa48a8e2 Merge pull request #5402 from codingreapermaps/feat/agc-fractional-even-partitioning
fix(agc): accept fractional-even tessellation partitioning
2026-10-14 22:57:20 +02:00
JAB-devandClaude Sonnet 5.5 cd95f1a426 perf(libSceSysmodule): cache the unwind region of loaded images on Windows
sceSysmoduleGetModuleInfoForUnwind called VirtualQuery and GetMappedFileNameA on every call. VirtualQuery on a large image section costs time proportional to the section (2 us for 16 KiB, 51 us for 8 MiB, 167 us for 32 MiB), and a title that unwinds exceptions while loading calls it for every frame of every throw.

The region and file name of an address inside an image of the Windows loader's module list are kept per region and used while the loader still reports the same image (base, time stamp and size). Other addresses are queried every time.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-14 22:57:08 +02:00
Adrià ffbc26c7d0 Merge pull request #5264 from hugodearaujo/fix/pad-vibration-mode-errors
fix(libScePad): check scePadSetVibrationMode's arguments in the console's order
2026-10-14 22:56:29 +02:00
Adrià 799982fac6 Merge pull request #5236 from David-cmrg/fix/systemservice-loadexec-exit-like-shell
fix(libSceSystemService): end LoadExec exit without running guest exit handlers
2026-10-14 22:54:40 +02:00
Adrià 6a8ba98b50 Merge pull request #5176 from n-delic/feat/ds-ordered-count
feat(shader): add GDS ordered counts and ordered-append dispatches
2026-10-14 22:52:36 +02:00
Leonardo 4b34a6d5a7 feat(libkernel): support microsecond timeout in size-0 _umtx_op 2026-10-14 22:51:54 +02:00
Adrià 6ff02d2119 Merge pull request #5477 from LeandroLP23/fix/agc-copy-data-register-source
fix(agc): copy a shader, context or user config register to memory with COPY_DATA
2026-10-14 22:50:24 +02:00
Adrià 33001cebda Merge pull request #5466 from fdfawef324/codex/stencil-export-emulation
feat(agc): replay proven finite stencil reference exports
2026-10-14 22:49:30 +02:00
Adrià 0a9a32646e Merge pull request #5461 from eljackjoestar-cmd/codex/single-level-volume-bias
fix(shader): sample single-level volumes through biased 2D accesses
2026-10-14 22:49:08 +02:00
billythemenace2andClaude Opus 5.5 731575c802 fix(shader): flush ds_add_f32 denormals and NaNs as the hardware does
ds_add_f32 and ds_add_rtn_f32 now follow the measured hardware: both
operands are flushed to a signed zero when bit 0 of the f32 denormal field
is clear and the result when bit 1 is clear, the sum is rounded to nearest
even, a NaN data operand is stored quieted, else a NaN old value is stored
quieted, and +inf + -inf stores 0xffc00000. Measured on gfx1010 and, in
#5492, on gfx1031.

The new MemoryInfo field is stored in the shader disk cache (field count
31, minimum record 79 bytes, FormatVersion 34). The parts that depend only
on the data operand are computed once, before the CAS loop.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-14 22:48:34 +02:00
Adrià 2077b5383a Merge pull request #5456 from billythemenace2/fix/shader-2d-compare-on-1d-tsharp
fix(shader): compare through 2D image_sample_c on 1D T#s
2026-10-14 22:48:28 +02:00
notaxeltvandCursor 27b3753260 feat(libSceNpPartner001): answer sceNpHasEAAccessSubscription without an EA Access server
Co-authored-by: Cursor <[email protected]>
2026-10-14 22:48:13 +02:00
Adrià 03f49fcf2e Merge pull request #5445 from nicolasabosch/fix/agc-sample-undrawn-msaa
fix(agc): sample a multisampled texture no draw rendered to from its uniform color memory
2026-10-14 22:47:11 +02:00
Ondra97 e60dd9d5a7 fix(ajm): preserve live decoder handles across ID wrap 2026-10-14 22:45:37 +02:00
Scott SchusterandClaude Opus 5.5 98ce8af56d perf(agc): reuse draw snapshots and moved word buffers across draws that nothing wrote between
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-14 22:45:17 +02:00
Adrià 4e210a1064 Merge pull request #5314 from XairRrR/fix/shader-front-face-all-bits
fix(shader): honour SPI_BARYC_CNTL.FRONT_FACE_ALL_BITS for the front-face input
2026-10-14 22:43:51 +02:00
Adrià FranchandClaude 970ff0c795 fix(libkernel): keep sem_timedwait debt entry on its own line, include <algorithm>/<cctype> in the kqueue test
Co-Authored-By: Claude <[email protected]>
2026-10-14 22:43:43 +02:00
Rujul Talekar e9d367776d fix(libkernel): name the failing vnode watch in the kqueue notification error
The Windows error for a refused FindFirstChangeNotification was one string shared
by WatchParent and WatchContents, so the log could not tell which handle or path
was denied. Build it from the watcher, the path the API was given and
GetLastError instead.

Still throws: the EVFILT_VNODE attach path is vfs_kqfilter, which returns only
EINVAL, ENOMEM or 0, with EBADF from fget before it, and consults no directory
permission, so no FreeBSD errno stands for a host that refuses to notify.
2026-10-14 22:43:39 +02:00
Muhammad Wasif Ali WasifandClaude Opus 5.5 cf780ffe7e docs(progress): the README links the history page, not its chart
The README no longer embeds history.svg; it links history.html, which the progress page also links.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-15 01:22:40 +05:00
Muhammad Wasif Ali WasifandClaude Opus 5.5 895061ca62 docs(build): list the ANYPS5_BUILD_WASM flag
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-15 01:22:39 +05:00
Adrià FranchandClaude 5d9def64e4 docs(debt): record COPY_DATA from a register and the dispatch registers it reads
Co-Authored-By: Claude <[email protected]>
2026-10-14 22:11:52 +02:00
Adrià FranchandClaude d8e97a7697 fix(recompiler): move stencil artifacts to cache format 35
Main's flatVolumeLineCompatible change also took format 34 with another layout, so entries of either would load as the other.

Co-Authored-By: Claude <[email protected]>
2026-10-14 22:09:03 +02:00
fdfawef324andCodex 97a0a4d098 refactor(agc): separate stencil replay from its follow-up topics
Move bounded vertex folding and empty-image feedback into separate topics. Keep the replay coverage proof, stage contracts, finite-reference tests and mapped cache regressions; version the stencil layout separately as format 34.

Co-Authored-By: Codex <[email protected]>
2026-10-14 22:08:48 +02:00
fdfawef324andCodex 77521f7ad2 feat(agc): replay proven finite stencil reference exports
Preserve instance and triangle order with one dynamic-reference shader pipeline. Require bounded references, complete export coverage, replay-safe mask control and resources; refuse unsupported side effects and feedback.

Co-Authored-By: Codex <[email protected]>
2026-10-14 22:08:35 +02:00
billythemenace2andClaude Opus 5.5 c63281824f fix(agc): rasterize a multisampled target without MSAA_ENABLE at the pixel center
A draw with PA_SC_AA_CONFIG.MSAA_NUM_SAMPLES > 0 and
PA_SC_MODE_CNTL_0.MSAA_ENABLE clear threw. On GFX10 and later the bit
is what makes the rasterizer use the programmed sample locations; with
it clear the draw now keeps the target's sample count with every sample
at the pixel center. Points, lines, a depth target and
alpha-to-coverage still throw.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-14 21:00:53 +01:00
Adrià FranchandClaude ade067251c docs(debt): move the single-level volume bias line off the end of the section
Co-Authored-By: Claude <[email protected]>
2026-10-14 21:58:28 +02:00