Commit Graph
548 Commits
Author SHA1 Message Date
Dean 865e06f1bc Merge pull request #7927 from whamre/feat/agc-depth-mips
feat(agc): render into depth mip levels
2026-10-22 19:09:06 +13:00
Adrià 0c6a5bd593 Merge pull request #8519 from MarrasFederico/fix/agc-zero-stride-oob-select
fix(agc): follow RDNA 2's range checks for zero-stride vertex fetches
2026-10-21 21:54:30 +02:00
Adrià f0de89a506 Merge pull request #9026 from milescoviello/perf/depth-plane-unit-stores
perf(agc): store only the depth plane units a read overlaps
2026-10-21 21:29:26 +02:00
Adrià FranchandClaude a3d739f170 docs(agc): record the all-past OOB_SELECT 1 throw and the gfx1010 measurement
Co-Authored-By: Claude <[email protected]>
2026-10-21 20:16:32 +02:00
Federico Marras 58afce1ad1 fix(agc): follow RDNA 2's range checks for zero-stride vertex fetches 2026-10-21 20:16:30 +02:00
Adrià d27d05ec14 Merge pull request #7883 from thuanquang/fix/strip-last-provoking-gs
fix(agc): draw triangle strips through a geometry program with the last provoking vertex
2026-10-21 20:10:30 +02:00
Dean 4ec064d29b Merge pull request #6887 from Amoenus/codex/test-msaa-reader-retile-main143
test(agc): connect MSAA sample readback to tiled layouts
2026-10-22 06:14:29 +13:00
thuanquangandClaude 0bd8f6188a fix(agc): draw triangle strips through a geometry program with the last provoking vertex
An RX 6700 XT hands a geometry shader odd strip triangle i as
(i+1, i, i+2) with the last provoking vertex, which is the order the
translator already uses, and since #7374 last mode takes the flat
outputs of the program's primitives from their last index. Keep the
last-mode refusal for fans only, which reach the program as
(i+1, i+2, 0) while the hardware gives (0, i+1, i+2). TEKKEN DARK
RESURRECTION (PPSA31371) stops on such a strip draw.

Co-Authored-By: Claude <[email protected]>
2026-10-21 21:41:01 +07:00
Dean 2c4b116da9 Merge pull request #7729 from milescoviello/fix/one-sample-depth-iter
fix(agc): draw a PS_ITER_SAMPLE program once per pixel into a one-sample depth target
2026-10-22 03:14:54 +13:00
Adrià 5bd9912658 Merge pull request #8317 from hypermoist/feat/agc-static-buffers
feat(libSceAgc): implement static buffers and qwords
2026-10-21 15:32:19 +02:00
Romans Pokrovskis b4fbf24d1e feat(agc): upload individual multisample image samples 2026-10-21 16:06:59 +03:00
Romans Pokrovskis b8297adab9 feat(agc): add fragment-preserving R_X and Z_X layouts 2026-10-21 16:06:32 +03:00
Dean fdf22f9546 Merge pull request #7911 from savvaniss/fix/agc-release-mem-system-counter
fix(agc): name the RELEASE_MEM system counter instead of GDS data
2026-10-22 01:54:27 +13:00
Dean ce7d547175 Merge pull request #8856 from klosixgaming-arch/feat/agc-point-list-geometry-output
feat(agc): draw point-list output of NGG geometry programs as mesh points
2026-10-22 01:46:18 +13:00
Dean 0c83831421 Merge pull request #8975 from milescoviello/rebase/5499-db-depth-copy
feat(agc): run DB depth copies into a single-sample R32 float target
2026-10-22 01:20:22 +13:00
Savvanis Spyros 123768abcd Merge branch 'main' of https://github.com/boykopovar/AnyPS5 into fix/agc-release-mem-system-counter
# Conflicts:
#	docs/dev/debt/libSceAgcDriver.md
2026-10-21 14:15:53 +03:00
Adrià 98145b48d8 Merge pull request #7426 from DavidSamir/feat/shader-barycentric-tessellation-last-vertex
feat(agc): draw the last provoking vertex through the barycentric tessellation stages
2026-10-21 13:08:47 +02:00
Adrià 2cca5c0fd6 Merge pull request #7600 from milescoviello/feat/msaa-dcc-comp-to-single
feat(agc): take RADV's comp-to-single clear of a multisampled DCC target
2026-10-21 13:07:42 +02:00
Adrià 275e896797 Merge pull request #7696 from MaxLikesCode/feat/agc-set-index-indirect-args
feat(libSceAgc): implement sceAgcDcbSetIndexIndirectArgs
2026-10-21 12:52:39 +02:00
Adrià 27fabb6b7d Merge pull request #7869 from savvaniss/feat/agc-polygon-mode
feat(agc): draw point and line polygon modes
2026-10-21 12:48:05 +02:00
milescovielloandClaude Opus 5.5 f57bbc936a perf(agc): store only the depth plane units a flush overlaps
A read of memory inside a stale D32 Z_X depth plane (FlushDepthPlanes) stored
the whole plane: a copy of the depth image into the mirror, MarkWholeWritten
and a write-back of every byte. In Super Meat Boy 3D (#8840) a read-only
buffer ending about 3 KiB inside a stale 3840x2160 plane makes
ShaderResources::Revalidate flush ~1000 times per 5 s, each one moving
31.9 MiB, bound by transfer bandwidth.

A depth surface now tracks its plane as 64 KiB units, each one 128x128 tile
of the mirror's block units: a stale bit and a write generation per unit
replace memoryStale and the plane-wide syncedGeneration.

- FlushDepthPlanes stores only the stale units the range overlaps: the depth
  to mirror copy takes one region per unit rectangle (UnitRects, from the
  mirror's slice windows), the mirror marks just those units written
  (MarkUnitsWritten) and the write-back covers their hull. The other units
  stay stale and the plane stays registered. Stale bits are cleared only
  after the copy was recorded, and the stored units' generations advance
  only when FlushPending stored them. A depth fast clear still pending at
  the store rewrites the whole image, so it makes every unit stale first.
- SyncFromMemory copies from the mirror only the units the guest wrote since
  their own generation (one ChangedBlocks scan; untracked memory counts as
  unwritten, as WrittenSince did), so a guest write into one unit no longer
  replaces GPU depth that is still unstored in the others.
- Flushes followed by a retire keep the whole-plane store: the color target
  flush in Draw and a written storage view (DepthPlaneScope::Whole). The
  retire of an overwritten surface in DepthSurfaceTexture first stores its
  remaining stale units the guest did not write.
- A mirror without block units (APS5_NO_BLOCK_TRACKING, unaligned base)
  falls back to the whole-plane copy, and APS5_DEPTH_PLANE_WHOLE_STORE=1
  tracks the plane as one unit, the previous behaviour.
- DepthPlaneStoreCounts reports stores, units and bytes stored.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-21 10:03:00 +00:00
Dean aa37bc7aef Merge pull request #6683 from EagleBearerYS/fix/agc-sample-location-grid-exact
fix(agc): keep the guest's sample order where pixel (0,0)'s locations stand in for a 2x2 grid
2026-10-21 23:00:12 +13:00
Dean 27c88a8d75 Merge pull request #8224 from savvaniss/fix/agc-strided-overhang-render-target
fix(agc): bind a strided buffer's last record only up to the render target it runs into
2026-10-21 21:32:49 +13:00
codingreapermapsandClaude Opus 5.5 191c8a8d2b feat(agc): run DB depth copies into a single-sample R32 float target
A draw with DB_RENDER_CONTROL.DEPTH_COPY copies one sample of the
Z_32_FLOAT depth surface into color target 0. It now runs as a compute
pass that fetches that sample and stores it into the R32 float target,
when the draw covers the whole surface without depth or stencil tests.
With COPY_CENTROID the sample is the first one the draw covers, which is
sample 0 under the full sample mask the driver requires, as radeonsi
programs its per-sample DB to CB copies.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-21 08:03:33 +00:00
Dean fb8b15c886 Merge pull request #8933 from xdCloudy/feat/ps5-agcdriver-exports
feat(libSceAgcDriver): declare PS5 AGC driver exports
2026-10-21 20:46:48 +13:00
Savvanis SpyrosandClaude Opus 5.5 ffb782739b docs(debt): name no title in the polygon mode entry
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-21 10:13:32 +03:00
Savvanis SpyrosandClaude Opus 5.5 e61d31d287 feat(agc): draw point and line polygon modes
PA_SU_SC_MODE_CNTL with POLY_MODE set to a point or line type was refused,
and every triangle was drawn filled. The state decode now takes the polygon
type of the faces that are not culled into State::polygonMode, ignores the
types when POLY_MODE is clear or the primitives are points or lines, and
keeps refusing front and back types that differ while both faces are drawn.

Points are drawn one pixel wide (PA_SU_POINT_SIZE 0x00080008 inside
PA_SU_POINT_MINMAX), the size VK_KHR_maintenance5 gives a point whose
shader does not write PointSize, and lines one pixel wide (PA_SU_LINE_CNTL).
The device enables fillModeNonSolid and maintenance5 when they are
available. The polygon mode joins the pipeline, library and draw keys and
the pipeline journal (format 5).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-21 10:13:32 +03:00
Savvanis SpyrosandClaude Opus 5.5 1c0e23afc5 fix(agc): trim a strided overhang at the render target only for read-only buffers
A store to the trimmed tail of a written buffer would be dropped instead
of failing as an alias of the render target, so only read-only buffers,
such as per-attribute vertex fetches, are trimmed.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-21 10:09:17 +03:00
xdCloudy 44c36055a2 docs(debt): place AGC driver note by related entries 2026-10-21 08:05:46 +01:00
xdCloudy 6b33ef1bd1 docs(debt): isolate AGC driver unknown signatures 2026-10-21 08:04:36 +01:00
xdCloudy b95a10c920 docs(libSceAgcDriver): record unknown export signatures 2026-10-21 08:04:36 +01:00
Yunus Shaikh 8c9c8eb5b5 Merge main into fix/agc-sample-location-grid-exact
main 7ce3b1df3e took disk-cache format 43 (#8295) for its own layout, so this
branch's format moves to 44. The request serializer stays at 42: main
still writes 41.
2026-10-20 23:48:14 -07:00
Celegans12 952ddb7844 feat(agc): skip draws whose graphics stage the recompiler refuses behind APS5_SKIP_REFUSED_DRAWS
When a draw's stage fails to prepare, capture or recompile, the packet
worker fails the queue and the next Submit or WaitIdle rethrows the
error, which ends the title. With APS5_SKIP_REFUSED_DRAWS set,
materializeDrawStage rethrows that error as a RefusedDraw; the packet
loop skips the draw, counts it as a thrown skip, logs the shader once
per address and runs the rest of the submission. The frame then lacks
that draw. Compute refusals and errors outside the stage build fail as
before, and without the switch nothing changes.

agc_driver_draw_unsupported_buffer_type_skip_refused submits a draw
whose pixel shader is refused twice with the switch: the WRITE_DATA
after it lands both times and the color target stays untouched.

AI-assisted: yes
2026-10-21 08:17:59 +02:00
Dean 630f8d5da2 Merge pull request #7912 from Rajkamalcode/fix/agc-storage-writeback
fix(agc): skip storage write-back units that lie in no tiled slice
2026-10-21 18:43:29 +13:00
Yunus Shaikh 6d09797d6b Merge main into fix/agc-sample-location-grid-exact 2026-10-21 05:39:42 +00:00
Dean a07e985c8f Merge pull request #8889 from oneandonlydean/docs/neutral-title-names
docs(dev): name retail titles by ID instead of by title
2026-10-21 18:10:11 +13:00
Dean GalvinandRajkamalcode da0ae843ac Merge origin/main into PR 7912
Co-authored-by: Rajkamalcode <[email protected]>
2026-10-21 18:05:58 +13:00
Dean Galvin bc87535cb0 docs(dev): name retail titles by ID instead of by title
Debt entries name the titles they were measured on. Use the title ID, or "a retail title" where the sentence needs no identification. No technical content changes.
2026-10-21 17:34:40 +13:00
xXPBSXxandClaude Sonnet 5.5 7f877b7581 docs(debt): point the DrawPipeline link at its header in include
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-21 05:50:48 +02:00
klosixgaming-arch ee81c5112d feat(agc): draw point-list output of NGG geometry programs as mesh points
A geometry program with VGT_GS_OUT_PRIM_TYPE 0 (point list) was refused
as an unsupported output assembly, halting Cocoon (PPSA08766) on boot
with "VGT_GS_OUT_PRIM_TYPE other than a triangle strip, or a line strip
from a geometry program, is unsupported".

Each primitive export of an NGG point-list geometry program outputs one
point whose vertex index is stored directly in PrimitivePointIndicesEXT,
so the mesh module now declares OutputPoints with PrimitivePointIndicesEXT
for it when outputPrimitiveSize is 1. The point primitive export extracts
the 9-bit vertex index from the packed primitive export word and stores
it to the output array. A subgroup gets up to maxVertices points, with
provoking vertex 0 and point raster primitive topology.

Tested with Cocoon (PPSA08766) which now progresses past pipeline
creation and initial frame draws into gameplay.

AI-assisted: yes. Written with AI assistance and reviewed by me.
2026-10-20 22:26:30 -05:00
Dean 05f9995704 Merge pull request #8469 from hypermoist/feat/agcdriver-firmware-constants
feat(libSceAgcDriver): add the retail debug, capture and GPU reset results
2026-10-21 16:23:27 +13:00
Dean 51a30d567a Merge pull request #8297 from thuanquang/docs/trunc-coord-debt
docs(agc): record that the host sampler replaces TRUNC_COORD's rounding
2026-10-21 16:09:49 +13:00
Dean 394170059f Merge pull request #8069 from thuanquang/fix/force-degamma-unchanged-formats
fix(agc): sample formats that FORCE_DEGAMMA leaves unchanged without it
2026-10-21 15:44:22 +13:00
Dean d686bb0b19 Merge pull request #8046 from klosixgaming-arch/fix/agc-clip-disable-no-depth-clamp
fix(agc): accept PA_CL_CLIP_CNTL CLIP_DISABLE without depth clamp
2026-10-21 14:27:32 +13:00
Dean 926ed2eda1 Merge pull request #7480 from Scramblrrrr/codex/videoout-force-sdr-main
feat(videoout): allow forcing SDR output
2026-10-21 12:28:40 +13:00
hypermistandClaude Opus 5.5 07ed40b7ce docs(agc): drop the stale zero-slot clause from the FS table entry
Slots 1-5 are now written by sceAgcSetStaticBuffer and the
sceAgcSetStaticQword family, so staying zero until a title writes them
is the modelled console behaviour.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01RbLgECLQ2bpDM7oe2urGZK
2026-10-21 12:12:08 +13:00
Dean 50e0624d7a Merge pull request #7154 from XairRrR/fix/agc-depth-plane-buffer-coherence
fix(agc): keep depth planes coherent with buffer reads and writes of their memory
2026-10-21 09:38:25 +13:00
Adrià 4cfcb003de Merge pull request #7862 from parl0v/fix/storage-budget-sampled-reserve
fix(agc): reserve only the sampled textures alive from the storage image budget
2026-10-20 16:45:56 +02:00
XairRrR 4a2aecc21c Merge main into pr-7154 2026-10-20 15:57:09 +02:00
Werner cd1efc9fca feat(agc): render into depth mip levels
Decode DB_Z_INFO.MAXMIP and DB_DEPTH_VIEW.MIPID and render into the
selected level of a 64 KiB Z_X mip chain as a surface of its own, at
the level's offset and extent from ComputeElementMipLayout, as color
target mips do. Slices of a mip chain step by the size of the whole
chain. Multisampled depth mips, other swizzles, levels in the packed
mip tail and HTILE on a mip chain still throw. LEGO Builder's
Journey (PPSA05496) stopped at its first scene on
"depth mips (DB_DEPTH_VIEW MIP_LEVEL) is unsupported".
2026-10-20 15:20:31 +02:00