Commit Graph

23 Commits

Author SHA1 Message Date
Chad 402bc1cdfc feat(agc): implement sceAgcBranchPatchSetThenTarget_0300 and SetElseTarget_0300 2026-10-10 15:05:43 -05:00
ploysius 39191f905d refactor(libSceAgc): name exports after the versioned SDK names their NIDs hash to
Eight libSceAgc exports were published under a raw NID with a made-up
name. Each NID is the hash of a versioned SDK name (checked with
tools/nid_names.py compute_nid), so the functions now carry that name and
are exported from it directly:

  23LRUSvYu1M  sceAgcUnknownInitState          -> sceAgcInit_0090
  -KRzWekV120  sceAgcUnknown__MKRzWekV120      -> sceAgcDcbSetIndexSize_0600
  Ikfdt-rIqCE  sceAgcUnknown_Ikfdt_MrIqCE      -> sceAgcJumpPatchSetTarget_0300
  7Wa3aeJgeVU  sceAgcUnknown_7Wa3aeJgeVU       -> sceAgcBranchPatchSetThenTarget_0300
  rP5xLdOf26k  sceAgcUnknown_rP5xLdOf26k       -> sceAgcBranchPatchSetElseTarget_0300
  fd5Bp5tGTgo  sceAgcUnknownFuseShaderHalves   -> sceAgcFuseShaderHalves_0200
  qj7QZpgr9Uw  sceAgcDcbContextStateAnotherOp  -> sceAgcDcbContextStateOp_0100
  k0E7vkgqAuE  sceAgcCreateInterpolantMappingVsPs -> sceAgcUpdateInterpolantMapping_0100

The exported NIDs are unchanged; the extra exports under the hashes of the
made-up names are gone. Behaviour is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 13:55:45 -04:00
Dean 63e02557ef
Merge pull request #1026 from hugodearaujo/feat/agc-wait-reg-mem-patch-mask
feat(libSceAgc): implement sceAgcWaitRegMemPatchMask
2026-10-07 17:57:55 +13:00
Dean 6e2c1f8992
Merge pull request #965 from hugodearaujo/feat/agc-async-cond-exec-patch
feat(libSceAgc): implement the async COND_EXEC patches
2026-10-07 15:21:47 +13:00
hugodearaujo 54eeadb3a2 feat(libSceAgc): implement sceAgcWaitRegMemPatchMask
Patch the mask of a wait packet like sceAgcWaitRegMemPatchReference
patches its reference: a 32-bit value written to the low mask word of a
32- or 64-bit WAIT_REG_MEM, rejected above 32 bits.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 22:34:29 -03:00
hugodearaujo 47fa19e15c feat(libSceAgc): implement the async COND_EXEC patches
sceAgcAsyncCondExecPatchSetCommandAddress and
sceAgcAsyncCondExecPatchSetEnd patch the COND_EXEC packet like their
graphics counterparts, since sceAgcAcbCondExec writes the same packet
as sceAgcDcbCondExec. Both variants share one implementation, as the
REWIND patches do.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 17:32:52 -03:00
Claude 16e76301ab feat(libSceAgc): implement the WRITE_DATA destination and cache policy patches
sceAgcWriteDataPatchSetDst, sceAgcWriteDataPatchSetCachePolicy, their
Async forms and sceAgcAsyncWriteDataPatchSetAddressOrOffset threw. They
now rewrite a WRITE_DATA packet in place: the destination in the
graphics (sceAgcDcbWriteData) or compute (sceAgcAcbWriteData) encoding,
the cache policy in bits 25-26 and the address in dwords 2-3, so the
patched packet equals the one written with those values. A register
destination is rejected when the packet requests write confirmation,
as when the packet is written.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 14:51:07 +00:00
Adrià Franch 5f68999836 feat(agc): implement sceAgcCondExecPatchSetCommandAddress and sceAgcCondExecPatchSetEnd
Co-Authored-By: Claude <noreply@anthropic.com>
2026-10-06 00:44:59 +02:00
DotDebian 46b5d5d8b0 feat(agc): implement the sceAgcBranchPatch setters
sceAgcBranchPatchSetCompareAddress, sceAgcBranchPatchSetThenTarget and
sceAgcBranchPatchSetElseTarget rewrite the compare address and the two
buffer targets of the packet sceAgcCbBranch emits. The then target is
the first buffer and the else target the second, as in AMD's
COND_INDIRECT_BUFFER packet. The cache policy bits are kept.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 17:48:12 +02:00
carman24r da35dcd89b
Merge branch 'boykopovar:main' into main 2026-09-30 05:05:49 -04:00
carman24r 01f6311bd3
Update IndirectRegisters.cpp
three register-count setters.
2026-09-29 16:05:27 -04:00
STL1te 6b36c050fe style: drop the branch's code comments per CONVENTIONS.md
Only the lines this branch added lose their comments; the commits before
keep them, with the reasoning behind each change, for whoever digs into
that code later.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 21:25:29 +03:00
STL1te 59a6998f1a fix(agc): EOP PatchData takes (cmd, data); -KRzWekV120 sets the index size
sceAgcQueueEndOfPipeActionPatchData is called with the packet and the new
64-bit label value only; reading a context id and a data selector from the
unused argument registers wrote garbage into the RELEASE_MEM, so fences
signalled with wrong values.

-KRzWekV120 is sceAgcDcbSetIndexSize with the per-instance object id flag
(VGT_INDEX_TYPE bit 14), as Kyty and SharpEmu build it. The no-op left the
previous index type in place, so 32-bit index buffers were read as 16-bit.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 21:22:16 +03:00
STL1te fd4700b909 feat(agc): packet sizes, register writes, GS/HS fusion, jump patches
- packet sizes for the existing builders and the tessellation ring
  config
- direct register writes and end-of-pipe action data, type and cache
  patches
- GS/HS shader halves fused by merging their registers, after Kyty
- jump target patches; reserved jumps are allowed

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 21:22:14 +03:00
devilismyfriend 9c2a75601d feat(libs): agc packet builders, savedata memory, offline service stubs
- libSceAgc: SetIndexCount, SetBaseIndirectArgs, DispatchIndirect, wait
  and write-data patch functions, relaxed checks for what titles send,
  NOP fillers for LOD stats and wait-until-safe, NotImplemented stubs.
- libSceSaveData.native: short mount points, backup events, save-data
  memory slots.
- user/system service, store dialog, video-out flip modes and queue-full
  error, pad read, fibers, offline behaviour for network/NP modules, and
  new export-only modules Ampr, JpegEnc, Json2, MsgDialog.native,
  NpCppWebApi, NpUtility.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0177gthrWEBBfBu5xJDXgBfo
2026-09-25 16:27:49 -07:00
boykopovar f5bc2d7649 feat(libs): add new sceAgc functions def 2026-09-24 07:54:15 +03:00
boykopovar bdff4874de feat(agc): add draw packets and register defaults with strict validation 2026-09-13 18:14:51 +03:00
boykopovar 888abd280f refactor(libSceAgc): add subdirs + new separated src 2026-09-13 15:06:31 +03:00
boykopovar 114c11aa88 feat(libSceAgc): implement command packet functions 2026-09-13 14:34:15 +03:00
boykopovar 8400150f80 feat(libs): add new declarations to libSceAgc 2026-09-10 09:09:08 +03:00
boykopovar abc72da741 feat(libs): define vabi macros + add to declarations 2026-09-10 08:07:03 +03:00
boykopovar e62c08f625 feat(libs): add new functions declarations 2026-09-09 09:12:30 +03:00
boykopovar 8730fa1e6e refactor(libSceAgc): create libSceAgc cmake project structure 2026-09-08 11:03:13 +03:00