Commit Graph
782 Commits
Author SHA1 Message Date
Adrià 6641f48356 Merge pull request #9789 from rooklz/fix/agc-uint-color-export
fix(libSceAgcDriver): export raw 32-bit values into UINT color targets as integers
2026-10-26 12:48:04 +01:00
davidamsellemandClaude Opus 5.5 6e5c1f041d docs: name the formats of the gfx1100 type-0 and type-1 measurement
GFX11 renumbers the image formats past 29, so the raw codes 10, 37 and 1
read as other formats on the console's GFX10 numbering (37 is
11_11_10_UNORM there, 2_10_10_10_SNORM on gfx1100). Name them, and say
why the TYPE 9 depth compare control only answers at 32_FLOAT: gfx1100
compares 16_UNORM and 32_FLOAT only and answers zero for the others.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-26 10:43:45 +01:00
davidamsellemandClaude Opus 5 dc81252d64 docs: measure type-0 and type-1 texture descriptors on gfx1100
The entry recorded TYPE 1 only from a gfx1010 measurement with format 22 and left other formats and
depth-compare reads open. Measured on a gfx1100 with the hardware oracle: image_sample_lz,
image_sample_b, image_load, image_sample_c_lz and image_get_resinfo return zero and no fault for
TYPE 0 and TYPE 1 over formats 22, 10, 37 and 1, with a nonzero base over readable memory and with a
zero base. A TYPE 9 control in the same kernel returns the stored texel, the raw dword, the declared
64 and 32, and 1.0 from image_sample_c_lz with an ALWAYS depth compare and format 22.

Co-Authored-By: Claude Opus 5 <[email protected]>
2026-10-26 10:43:45 +01:00
Dean b27cc8416f Merge pull request #7505 from AlxcBTW/pr/unwatch-hook-exits-v2
fix(agc): run the unwatch hook before an import whose range leaves the write watch whatever the import does
2026-10-26 21:31:22 +13:00
Dean 9d906c833c Merge pull request #10681 from PYTHONRETARDE/fix/d16-depth-take-storage-discard
fix(agc): discard a new depth surface's depth before taking storage writes
2026-10-26 21:29:52 +13:00
Dean 204c6747d0 Merge pull request #11197 from LeandroLP23/fix/agc-frame-recorder-settle-before-delta
fix(agc): read a frame capture's memory delta once the accepted submissions completed
2026-10-26 20:48:54 +13:00
Dean fdb3925940 Merge pull request #9913 from HQasper/claude/project-thread-75dvwh
fix(agc): draw stencil AND, OR, XOR and XNOR on the bits they change
2026-10-26 20:03:59 +13:00
Dean Galvin 72598e34c8 Merge branch 'main' into pr/unwatch-hook-exits-v2 2026-10-26 14:36:49 +13:00
Dean d31f372e33 Merge pull request #10062 from imellag/fix/agc-moltenvk-destroy-at-idle
fix(agc): destroy buffers and memory on MoltenVK only while the graphics queue is idle
2026-10-26 14:28:45 +13:00
Adrià acb900c194 Merge pull request #9737 from imellag/feat/agc-depth-bounds-emulation
feat(agc): emulate a one-sided depth bounds test without the depthBounds feature
2026-10-26 00:35:49 +01:00
LeandroLP23andClaude Opus 5.5 ada20294a6 fix(agc): read a frame capture's memory delta once the accepted submissions completed
A delta read its blocks with ReadCommittedUnsynced while GPU work
accepted before the call could still write them, so a capture could
hold a block from before a DMA copy that the replay then wrote back over
the copy's result. A delta with blocks to read now waits up to 10 s for
the accepted submissions and records the serials after the wait; the
capture stops with a warning when the work does not finish. The Windows
quarantine of agc_driver_frame_replay is removed.

Fixes #10711

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-25 22:36:36 +01:00
Adrià cceb6c3c41 Merge pull request #9961 from daviaaze/fix/agc-dcc-sliced-array-window
fix(agc): serve sampled DCC array views from their viewed slices
2026-10-25 21:53:47 +01:00
Adrià 5d48c6233e Merge pull request #9401 from tibzejoker/perf/grow-pipeline-store
perf(agc): size the pipeline store to the title's working set
2026-10-25 19:07:59 +01:00
Davi Azevedo b166232c72 fix(agc): refresh DCC sampled array windows 2026-10-25 14:13:27 -03:00
Dean 79f061ba5b Merge pull request #9685 from thuanquang/fix/linear-target-completion-stores
fix(agc): store resident linear color targets at completion points, limited to their drawn rectangles
2026-10-26 05:44:21 +13:00
Adrià 0658bc8749 Merge pull request #9186 from fma-rc/fix/agc-retire-undrawn-filled-msaa
fix(agc): retire an undrawn filled multisampled color target that a guest access overlaps
2026-10-25 14:25:07 +01:00
Adrià a8b199d103 Merge pull request #7618 from mrfelek/perf/stage-swept-write-only
perf(agc): stage written-only buffer elements a dispatch sweeps on discrete GPUs
2026-10-25 13:19:08 +01:00
Adrià 3eb0770ae9 Merge pull request #9361 from thuanquang/docs/debt-sweep-agc-cb-passes
docs(agc): correct multisampled DCC acceptance in the CB passes debt entry
2026-10-25 11:46:13 +01:00
Adrià ce29789faa Merge pull request #9352 from thuanquang/docs/debt-force-degamma-variant-names
docs(agc): name the 10_11_11 and 2_10_10_10 variants that FORCE_DEGAMMA leaves unchanged
2026-10-25 11:40:07 +01:00
Adrià 8e9cadc1fe Merge pull request #9275 from xXPBSXx/docs-agc-storage-image-uncommitted
docs(debt): record the storage image refusal over uncommitted guest memory
2026-10-25 11:37:52 +01:00
Adrià acbfd7c7fe Merge pull request #9941 from EagleBearerYS/fix/agc-sync-settle-initial-dcc-main2
fix(agc): settle a pending import synchronously before an initial multisampled DCC import
2026-10-25 10:50:05 +01:00
Adrià f4f1160614 Merge pull request #9670 from winstrex/perf/agc-present-queue
perf(agc): present on a queue of its own outside the GPU mutex
2026-10-25 10:28:27 +01:00
Adrià 1240b5da19 Merge pull request #9597 from milescoviello/fix/mipmapped-dcc-target-keys
fix(agc): keep a mipmapped DCC color target's keys on its resident image
2026-10-25 09:29:51 +01:00
Adrià 811ffe10af Merge pull request #9514 from EagleBearerYS/fix/agc-address-copy-evict-main
fix(agc): an address-based build evicts idle imports instead of copying past the cap
2026-10-25 08:40:37 +01:00
slopgobblercobbler f23ef99699 feat(libSceAgcDriver): cover payload packing in sceAgcDriverNopDataWritePacket 2026-10-25 02:36:47 +01:00
milescovielloandClaude Opus 5.5 52f36c8aa2 fix(agc): keep a mipmapped DCC color target's keys on its resident image
DecodeColorBuffer dropped the DCC address of a color target with more than
one mip, so the target's resident image had no keys: it was uploaded from
guest memory under the game's fast-clear keys, and no draw into it marked
them uncompressed. The game's textures over the same chain name the keys,
so they kept sampling the clear (0000 reads as (0,0,0,0)) whatever was
drawn. MXGP 26, Borderlands 4 and Forspoken render such targets.

- ColorTarget.chainDccAddress keeps the keys of a 2D single-layer chain;
  dccAddress stays 0, so the per-draw single-mip key handling is unchanged.
- SurfaceForTarget gives the resident surface those keys, and the image
  then treats them as a multi-mip storage image does: a uniform clear is
  cleared on the GPU at upload, and the first write marks every key
  uncompressed.
- A draw recipe's key check uses the surface's keys.
- sizeof(State) is 840: the recipe codec and CanonicalPipelineState do not
  copy the field.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-25 00:31:53 +00:00
thibautandClaude Opus 5.5 ad047899bb perf(agc): grow the pipeline store from 1024 up to 4096 entries
The graphics pipeline store kept a fixed 1024 entries and the pipeline journal replayed at most
1024 records, and a replayed pipeline that found the store full was dropped. A title whose
working set is larger rebuilt the rest at the draw on every run, and evicted pipelines it kept
using were rebuilt again and again.

The bound now starts at 1024 and doubles up to 4096: a journal replay that does not fit grows it
instead of dropping the pipeline, and so does eviction churn (a ghost list of evicted keys, checked
every bound/32 evictions: more than half of them came back). It never shrinks during a run;
APS5_PIPELINE_STORE_ENTRIES still fixes it. The journal loads its last 4096 records by default
(APS5_PIPELINE_JOURNAL_ENTRIES). Resident pipelines are bounded by count, not bytes.

agc_driver_recorder_tests --benchmark-pipeline-store-memory [count] (opt-in, not registered)
builds count graphics pipelines with one fragment module each through CachedPipeline and prints
process private bytes and VK_EXT_memory_budget heap usage before and after: with the triangle
shaders about 59 KiB host and no device memory per pipeline on an RTX 4090, 100 KiB host and
8 KiB device-local on a UHD 770.

Tests: agc_pipeline_store_growth (fails on main), agc_pipeline_store_fixed_bound,
agc_pipeline_store_replay_growth (replays on one thread: the mock Vulkan is not thread-safe).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_017SNUYRd7sRKZrMYpquAsnU
2026-10-25 02:02:41 +02:00
Dean Galvin f139561693 Merge main into fix/linear-target-completion-stores 2026-10-25 12:57:20 +13:00
Adrià Franch b6bfc78286 docs(agc): keep main's stencil replay debt line 2026-10-24 22:41:08 +02:00
fma-rc a8706b22ba docs(agc): record when an undrawn multisampled target is retired on guest access 2026-10-24 22:41:08 +02:00
Dean Galvin 8807b0e235 test(agc): do not build agc_driver_frame_replay_tests while the test is quarantined (#10711)
The Windows registration check fails when a test executable is built but no ctest test runs it. Put the executable under ANYPS5_RUN_QUARANTINED_FRAME_REPLAY as well, so OFF neither builds nor registers it and ON does both.
2026-10-25 08:22:42 +13:00
Rookie b15a58d802 fix(libSceAgcDriver): export raw 32-bit values into UINT color targets as integers 2026-10-24 20:14:50 +01:00
Yunus Shaikh 02f6f8e66f Merge main into fix/agc-sync-settle-initial-dcc-main2 2026-10-24 11:49:50 -07:00
Dean Galvin a875c2cc1e test(agc): quarantine agc_driver_frame_replay on Windows until the recorder fix (#10711)
The recorder reads a delta block with ReadCommittedUnsynced while the second DMA copy into it is still in flight, so the capture can hold zeros and the replay then does not reproduce the second copy. The test failed intermittently on the Windows lane. Do not register it on Windows unless ANYPS5_RUN_QUARANTINED_FRAME_REPLAY is ON, and list it in the libSceAgcDriver technical debt.
2026-10-25 07:46:42 +13:00
Adrià Franch 4e35ece5a3 Merge remote-tracking branch 'upstream/main' into HEAD 2026-10-24 20:42:36 +02:00
Adrià 6b23aaf129 Merge pull request #9159 from EagleBearerYS/fix/agc-rewatched-imports-compared-when-shared
fix(agc): keep a rewatched import's memory compared once it is shared
2026-10-24 20:26:38 +02:00
Adrià c035bd5b70 Merge pull request #9424 from hugodearaujo/fix/agc-unset-index-limit
fix(agc): resolve indexed indirect draws on a queue that never set INDEX_BUFFER_SIZE
2026-10-24 20:23:28 +02:00
Adrià 24581200ad Merge pull request #9450 from fma-rc/fix/agc-eqaa-one-fragment
fix(agc): draw a one-fragment multisampled color target as one sample with sample 0's coverage
2026-10-24 20:22:28 +02:00
PYTHONRETARDEandClaude Opus 5.5 d84a94e6d2 fix(agc): discard a new depth surface's depth before taking storage writes
TakeStorage copies a pending or live storage image over the whole depth
plane of a new single-sample surface, after the creation clear. On AMD's
Windows driver 32.0.31041.1004 (RX 7800 XT), one or two 8x8 blocks of a
D16 surface then tested as the clear value in about 1 of 10 runs of
agc_driver_depth_surface_from_storage, although a copy back of the image
read the copied values (#6630).

Without a stencil plane the copy now goes through an UNDEFINED to
TRANSFER_DST_OPTIMAL barrier on the depth aspect and back to GENERAL, so
the clear's state is discarded before the copy writes every texel. A
surface with a stencil plane keeps the previous path.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-24 17:55:56 +00:00
Dean 1009187128 Merge pull request #9348 from klosixgaming-arch/feat/agc-color-logic-op
feat(agc): apply the color logic operation of CB_COLOR_CONTROL
2026-10-25 06:36:03 +13:00
Yunus Shaikh df89dd1041 Merge main into fix/agc-rewatched-imports-compared-when-shared 2026-10-24 09:51:13 -07:00
Adrià af45c3030e Merge pull request #9406 from JJenkx/fix/depth-plane-unmapped
fix(agc): drop stale depth-plane results whose guest memory was unmapped
2026-10-24 18:43:45 +02:00
Adrià 6da7e42704 Merge pull request #9652 from JJenkx/perf/agc-join-from-run-start
perf(agc): join the imports of a buffer bound from the start of adjacent ranges
2026-10-24 18:28:15 +02:00
Adrià 43768fa237 Merge pull request #8999 from milescoviello/feat/db-depth-copy-draw
feat(agc): draw DB depth copies with a driver pixel program
2026-10-24 17:29:23 +02:00
Dean b607bfdc8b Merge pull request #8213 from milescoviello/fix/journal-stream-modules
fix(agc): read the pipeline journal's modules at replay instead of holding the file
2026-10-25 04:18:44 +13:00
Adrià Franch af673ae694 docs(agc): record the one-fragment color target's unmeasured console behaviour and refused cases 2026-10-24 16:59:57 +02:00
Adrià d098eca3d6 Merge pull request #9185 from janzezno/fix/pixel-interlock-monolithic
fix(agc): build a pipeline with a fragment shader interlock whole, not from libraries
2026-10-24 16:29:56 +02:00
Dean 8e039f083f Merge pull request #9988 from frankea/fix/one-sample-ancillary-unsampled
fix(agc): accept ANCILLARY without PS_ITER_SAMPLE for a one-sample depth target without MSAA_ENABLE
2026-10-25 01:54:06 +13:00
Adrià 6e85617080 Merge pull request #9856 from Pacuka/feat/agc-driver-mem-semaphore
feat(libSceAgcDriver): execute MEM_SEMAPHORE signals and waits
2026-10-24 14:52:55 +02:00
milescovielloandClaude Opus 5.5 88718239a7 fix(agc): read the pipeline journal's modules at replay instead of holding the file
The journal was read whole into one buffer that the decoded modules
viewed, so a replay held the entire file (1 GiB at the default
APS5_PIPELINE_JOURNAL_MAX_MIB) until its last entry was built. The load
now parses the file a record at a time through positioned reads and keeps
it open; a replay thread reads an entry's modules again when it builds the
entry and rejects it when a record no longer reads back as loaded. The
replay report gains the peak module bytes held at once.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-24 14:18:09 +02:00