Commit Graph

113 Commits

Author SHA1 Message Date
938d360265 Merge pull request #3986 from nicolas
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 23:10:11 -05:00
2e3fd36d79 Merge pull request #3951 from Jan Trencansky
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

# Conflicts:
#	docs/d3d12_vulkan.md
2026-11-22 23:09:52 -05:00
64a1dcf16f Merge pull request #3913 from nicolas
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 23:09:31 -05:00
e549ac4c07 Merge pull request #3851 from Leonida local test
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 23:08:54 -05:00
6fffd7e56d Merge pull request #3819 from iurysf
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

# Conflicts:
#	runtime/README.md
2026-11-22 23:08:39 -05:00
44d705ce4b Merge pull request #3671 from kotorvr
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 23:08:12 -05:00
5fec4f2827 Test a scripted 600-frame headless scene from a mapped guest 2026-11-22 15:43:53 -07:00
34c130c36c docs: slot 67 passes the dispatch state on; what pipeline slot 11 does with 0, measured (RT-99)
- d3d12_command_objects.md section 3.5a: slot 67 now passes all four pairs; for slot 11, what the DLL does on failure
  and with 0 (measured in its code), the object's shape, why no program needs a scratch size (measured over the 29),
  what is implemented and what stays open.
- fspx.md: the slot-67 payload and its checks, and slot 11.
- d3d12_vulkan.md and runtime/README.md: the new parts of d3d12_fspx_compute_test; the DLL's own dispatch was not run
  here (fsr_dispatch_test needs MSVC structured exception handling).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 17:26:34 -05:00
3c7500b580 Exercise translated raster draws from a mapped synthetic guest 2026-11-22 15:22:19 -07:00
2fb013cd9b Merge origin/main into tls-existing-threads
Conflicts with #2070's later round (TLS generations, per-slot thread-event
errors, clone purge) in pe_loader.cpp/.h and loader_tls_test.cpp:
- install_thread_block keeps main's generation check and this branch's
  existing-thread check.
- on_host_thread_event keeps main's per-slot try/catch and calls this
  branch's existing-thread hooks first, each in its own try/catch.
- ~Loader resets the slot generation and removes the existing-thread blocks.
- The existing-thread records carry the module's TLS generation too.
- Both sides' tests stay. test_orphan_slot_generation_reuse now expects
  one DLL_THREAD_DETACH, not none: the worker was running when the second
  Loader mapped the module, so it gets that module's copy and its detach,
  as Windows does; a second detach would mean the orphaned record was taken
  for the new module's.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 22:19:40 +00:00
d7aa218648 runtime/README: device slots are partly measured; five QueryApiImpl classes
Review follow-up on #3819 (@Vonsek, @shdann), after rebasing onto main
4c52ce27:

- "the Xbox device vtable beyond slots 62, 67 and 76" is unmeasured was
  too broad: docs/d3d12_vulkan.md question 2 records device slots 14, 15,
  16, 18, 19, 27, 38, 62 and 76 confirmed by the FSR DLL's calls, with 67
  a console-only pipeline call. Say that, and point to question 2.
- main now serves XPersistentLocalStorageImpl from QueryApiImpl
  (runtime/shims/xgameruntime.cpp:491), so the list names five classes.

Written with AI assistance (Claude, via OpenBot).
Tested: python -I tests/test_docs_{design_rows,links,list_items,repo_paths}.py,
tests/test_i18n_index.py and tests/test_text_write_line_endings.py pass
(Windows 11, docs only).

Co-authored-by: OpenBot <335604065+openbotgit[bot]@users.noreply.github.com>
2026-11-22 19:06:04 -03:00
300f42965f runtime/README: say what the shims and the Vulkan device cover today
Two passages were out of date or vague.

The d3d12_xs bullet said the Vulkan device covers submission, heaps,
views, committed resources and copies. It also creates root signatures,
graphics and compute pipeline states, and records draws, dispatches and
ExecuteIndirect (shims/d3d12_vulkan_device.cpp, shims/d3d12_com.cpp).

"Current limits" listed what the missing executable blocks without saying
what exists. Now, per item, checked against the code:

- D3D12XboxCreateDevice exists (shims/d3d12_xs.cpp) and wraps the PC or the
  Vulkan device in the proxy; the params/flag layout and the Xbox vtable
  beyond slots 62, 67 and 76 are unmeasured (shims/d3d12_xs_device.h,
  docs/d3d12_vulkan.md);
- the queue and fence proxies forward the public slots and refuse the
  console's PresentX/SuspendX/ResumeX slots, which are unknown; PresentX and
  the frame events are implemented in shims/xbox_present.* and tested
  (xbox_present_test) but not reachable through those slots yet;
- xgameruntime: QueryApiImpl serves XThreadingImpl, XErrorImpl,
  XNetworkingImpl and XSystemImpl and refuses other classes with a log
  (shims/xgameruntime.cpp, xgameruntime_test).

Say that none of this was measured against the real executable.

Claimed in #3574. Written with AI assistance (Claude, via OpenBot).
Tested: python -I tests/test_docs_{design_rows,links,list_items,repo_paths}.py,
tests/test_i18n_index.py and tests/test_text_write_line_endings.py pass;
git diff --check is clean (Windows 11, docs only; no GPU involved).

Co-authored-by: OpenBot <335604065+openbotgit[bot]@users.noreply.github.com>
2026-11-22 19:05:33 -03:00
8fe1256fd9 Merge pull request #3819 from iurysf
# Conflicts:
#	runtime/README.md
2026-11-22 17:04:03 -05:00
59aa22ff0c gameinput: drive a constant force from gameinput_probe (RT-160)
`--force-feedback` creates a constant effect at magnitude 1.0 on motor 0 and
holds it for a second, so the wheel owner the RT-160 finding asks for can feel
the magnitude and the axis instead of only reading `forcefeedback=`; a pad with
no force-feedback motor is skipped with the reason printed. Docs and the probe
comment name the flag.

AI-assisted
2026-11-22 23:03:41 +01:00
221b8922d6 Merge pull request #3686 from kotorvr 2026-11-22 17:03:25 -05:00
0a53e623a8 Merge pull request #3488 from kotorvr
# Conflicts:
#	runtime/README.md
2026-11-22 17:02:16 -05:00
db85b6ebb6 Merge pull request #3351 from ICUMADETHIS 2026-11-22 17:01:36 -05:00
9dc0287ffa Merge pull request #2401 from Sc4ros 2026-11-22 16:59:13 -05:00
cf4a8752b8 Merge pull request #2152 from mz 2026-11-22 16:59:04 -05:00
18024dd3a4 runtime/README: say what the shims and the Vulkan device cover today
Two passages were out of date or vague.

The d3d12_xs bullet said the Vulkan device covers submission, heaps,
views, committed resources and copies. It also creates root signatures,
graphics and compute pipeline states, and records draws, dispatches and
ExecuteIndirect (shims/d3d12_vulkan_device.cpp, shims/d3d12_com.cpp).

"Current limits" listed what the missing executable blocks without saying
what exists. Now, per item, checked against the code:

- D3D12XboxCreateDevice exists (shims/d3d12_xs.cpp) and wraps the PC or the
  Vulkan device in the proxy; the params/flag layout and the Xbox vtable
  beyond slots 62, 67 and 76 are unmeasured (shims/d3d12_xs_device.h,
  docs/d3d12_vulkan.md);
- the queue and fence proxies forward the public slots and refuse the
  console's PresentX/SuspendX/ResumeX slots, which are unknown; PresentX and
  the frame events are implemented in shims/xbox_present.* and tested
  (xbox_present_test) but not reachable through those slots yet;
- xgameruntime: QueryApiImpl serves XThreadingImpl, XErrorImpl,
  XNetworkingImpl and XSystemImpl and refuses other classes with a log
  (shims/xgameruntime.cpp, xgameruntime_test).

Say that none of this was measured against the real executable.

Claimed in #3574. Written with AI assistance (Claude, via OpenBot).
Tested: python -I tests/test_docs_{design_rows,links,list_items,repo_paths}.py,
tests/test_i18n_index.py and tests/test_text_write_line_endings.py pass;
git diff --check is clean (Windows 11, docs only; no GPU involved).

Co-authored-by: OpenBot <335604065+openbotgit[bot]@users.noreply.github.com>
2026-11-22 18:49:18 -03:00
8e5b781d8a runtime/README.md: LEONIDA_CONTENT_PACKAGES, a path longer than 259 characters is ERROR_INSUFFICIENT_BUFFER
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-22 21:22:04 +00:00
b37028eb9c runtime/README.md: document the five xgameruntime environment overrides, with a docs test
LEONIDA_DEVICE_TYPE, LEONIDA_ANALYTICS_FORM, LEONIDA_PACKAGE_ID,
LEONIDA_CONTENT_PACKAGES and LEONIDA_PACKAGED are read by
runtime/shims/xgameruntime.cpp and were named in no document, while the
README documents the runtime's other variables one by one.

Adds a table read from the code (default, accepted values, which call each
one changes) and tests/test_docs_env_vars.py: every LEONIDA_*/GTA6RT_*
variable that appears as a string literal in runtime/src, runtime/shims
or make_game.py is named in some tracked Markdown file, except the two the
runtime sets for itself.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-22 21:13:11 +00:00
mz
b40df7a58d RT-115: hold --run to the Windows sequence under Wine
run_tiny_atexit compared `gta6rt --run` with the native run. Under Wine the
native leg uses Wine's own CRT, which differs from Windows in two places
(it drops a handler registered while handlers run, and its _exit from a
second thread does not wait for the exit lock), so the test failed there
although --run gave the Windows sequence (reported on #2152).

--run is now held to the expected sequence directly. On Windows this is the
same check, since the native run must match that sequence too. With RUNNER
set (Wine), a native difference is reported without failing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 21:09:55 +00:00
b418319ae9 loader: static TLS for threads that were running before load()
load() installed the image's TLS block on its caller, and the helper DLL's
DLL_THREAD_ATTACH covers threads started later. A thread that was already
running kept the helper's one-byte block in the reserved slot, so mapped
__declspec(thread) code on it read and wrote past it. The process thread
pool's workers are such threads, and the task queue runs a title's
callbacks on them.

load() now gives every other running thread its own copy of the template
through that thread's TEB, as Windows does for a DLL it loads itself: a
block, no DLL_THREAD_ATTACH. The block comes out in the thread's own
DLL_THREAD_DETACH (after the module's TLS callbacks) or in ~Loader.

loader_tls_test: a thread and a pool worker that exist before load(),
across two mappings of the fixture.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-22 20:40:54 +00:00
debda7e15d runtime tests: run a mapped stand-in through gta6rt --run into the Vulkan D3D12 device
tiny_frame imports d3d12_xs.dll!D3D12XboxCreateDevice from a link-time stub
and does the least a title does before its first frame: queue, allocator,
list, fence, an RTV heap with its start handle read in the console shape, a
committed target, a clear, a copy to a readback buffer, a fence wait, and a
check of every pixel. It returns from main with the device still alive.

run_tiny_frame runs it under gta6rt --run --trace-d3d12 with
LEONIDA_D3D12=vulkan; check_tiny_frame.py checks the verdict, the shim
binding and the call order, and exits 77 when d3d12_com_test, its probe,
finds no usable Vulkan device. tests/test_check_tiny_frame.py covers the
checker on synthetic output.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-22 20:24:40 +00:00
mz
39d3ab8c7d RT-115: gta6rt --run runs the game's atexit handlers and static destructors
The mapped EXE registered atexit handlers and static destructors with the
host CRT's process-wide table, which gta6rt never runs, so they were lost.
They now go to a table of the run's own: exit() and a return from main run
it newest first (including handlers registered during exit), _cexit() runs
it and returns, and _exit/_Exit/quick_exit/ExitProcess/abort skip it, as
natively. exit/_exit/_Exit/quick_exit share an exit lock like the CRT's,
each run starts with an empty table, and a failed registration returns an
error instead of throwing into the game.

New run_tiny_atexit compares a stand-in program run natively and through
--run for 8 termination paths. Not covered yet: at_quick_exit and the
thread_local destructor callback.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 20:21:20 +00:00
c92424d3f5 Runtime: record each distinct XMemAlloc/XMemFree attribute word in --trace
xmem.cpp ignores the attributes argument, and the bits of the Scarlett
XALLOC_ATTRIBUTES word are not known yet. With gta6rt --trace FILE, the first
XMemAlloc and the first XMemFree for each distinct raw attribute word now
write an "xmem_attributes" event (api, the word, the size for an allocation,
the caller as module+RVA), so the bits can be decoded from a real run without
logging every allocation. Off: one relaxed load per call.

xmem_test opens a trace and checks one event per word and API, the size of the
first call, a caller on every event, and nothing recorded while the trace is
off. README.md documents the event.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-22 21:18:43 +01:00
c6341775fb Merge pull request #3321 from HAMADA 2026-11-22 15:16:57 -05:00
bf576586b3 d3d12: place 1D and 3D textures like 2D ones
CreatePlacedResource answered E_NOTIMPL for every non-tiled texture that
was not 2D, while the host places 1D and 3D textures. A placed texture
already gets its own image from create_texture, which handles 1D and 3D
for committed textures, so the 2D-only branch goes. The checks before it
(size and room in the heap, an invalid dimension, no output pointer)
stay as they are and now cover 1D and 3D too.

d3d12_placed_dimensions_test compares the answers and GetDesc with the
host (default adapter and WARP) for 1D, 1D arrays, 3D, BC1 3D, UAV and
render-target 1D/3D textures, and round-trips a pattern through every
subresource of a placed 3D texture and a placed 1D array.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 20:12:16 +00:00
94ff85fdf7 Merge pull request #2784 from SuarezPM 2026-11-22 15:11:58 -05:00
00f9ebd672 Merge pull request #2070 from jaybeebabageyus 2026-11-22 15:10:09 -05:00
38df0fb43f d3d12: measure 96-bit resource tiling 2026-11-22 20:04:08 +00:00
50e9dd32fa Merge remote-tracking branch 'upstream/main' into 2070-lifecycle-fix
# Conflicts:
#	runtime/src/pe_loader.cpp
#	runtime/src/pe_loader.h
#	runtime/test/loader_tls_test.cpp
2026-11-22 20:57:07 +01:00
1188e6406e runtime: scope the TLS clone purge to ownerless files, clean clones before ExitProcess, per-slot thread-event errors
The startup purge deleted every leonida_tls_host_*.dll in the temp directory, so it could remove the
clone of a concurrent process that had copied its helper but not reached LoadLibraryExW yet. Clones
are now copied to a staging name and renamed into place while the copy step's guard handle is open, so
a final-name clone never exists without a handle, and the purge skips files that fail an exclusive
open or whose owner process (from the file name) is still alive.

std::atexit cleanup never ran on the --run path because main ends with ExitProcess; the loader now
exposes cleanup_tls_clones() and main calls it before ExitProcess (atexit still covers normal exits).

on_host_thread_event wrapped the whole slot loop in one try/catch, so one throwing slot killed the
events for every other module. The catch is now per slot, and the detach path releases the slot even
when the callbacks threw, instead of leaking the block to the OS loader.

README and the initialize_tls comment no longer claim only one mapped TLS module can be live; the
loader_tls_test gained purge-ownership and explicit-cleanup checks.
2026-11-22 20:54:47 +01:00
f495169092 boot: the first-boot runbook and the two-trace summary
tools/boot_trace.py reads the `--trace` JSONL and the `[d3d12-trace]`
stderr lines and prints the units a first boot needs: modules, unimplemented
imports with their callers, DllMain/TLS results, exceptions with their
stack, the exit, and the D3D12 calls by outcome and first call per method.
It counts debug strings instead of printing them, so a real trace stays on
the player's machine; the tests use synthetic fixtures only.

docs/boot.md is the runbook around it: the Windows and Wine commands, the
LEONIDA_UNIMPLEMENTED and validation switches, the first-failure triage
order, and the Q1-Q22 table mapping each open question to the event to look
for. docs/README.md and runtime/README.md point at both.
2026-11-22 15:16:15 -03:00
a3b1719c61 gameinput: report and drive force-feedback and haptic motors through SDL3 haptics (RT-160)
IGameInputDevice answered the force-feedback and haptic half of the API with
nothing: no motors in GameInputDeviceInfo, E_INVALIDARG from
CreateForceFeedbackEffect, false from IsForceFeedbackMotorPoweredOn, a no-op
SetForceFeedbackMotorGain and E_INVALIDARG from SetHapticMotorState. A pad SDL
opens as a haptic device now reports one force-feedback motor with the effect
kinds SDL lists, and a pad with trigger motors reports two haptic motors.

Force feedback goes to SDL_CreateHapticEffect/RunHapticEffect on the poll
thread, so title calls still never touch SDL; the eleven GameInput effect kinds
are SDL's eleven force-feedback effects. The trigger haptic motors play their
one waveform as an intensity on the existing trigger output. A pad with neither
keeps the old answers, and LEONIDA_RUMBLE=0 silences both. gameinput_test drives
all of it through a fake haptic backend, because SDL's virtual joysticks report
no haptics.

AI-assisted.
2026-11-22 18:26:28 +01:00
96dcddb6fb Merge pull request #1911 from Jan Trencansky 2026-11-22 10:39:21 -05:00
98e9acfb91 Merge pull request #1908 from Jolymmiles 2026-11-22 10:39:19 -05:00
d6443b1524 Startup trace: never replace an existing file; write UTF-8 only
Review on #1756 (Vonsek):
- The trace is opened before the loader reads the image, so `wb` could
  truncate an input named by mistake (the image itself). open() now
  uses "x" mode and fails with EEXIST on an existing path; gta6rt says
  so and exits with 2.
- OutputDebugStringA text is in the ANSI code page. It is converted
  to UTF-8 before quoting, so a byte such as 0xE9 no longer breaks the
  JSON lines. Host module names now come from GetModuleFileNameW,
  converted to UTF-8, for the same reason.

startup_trace_test: an existing file is refused with EEXIST and its
bytes survive, the trace stays off; an ANSI debug string with 0xE9
appears as its UTF-8 form and the whole file is valid UTF-8.
2026-11-22 12:06:49 -03:00
2dca597bd9 Runtime: opt-in startup trace (gta6rt --trace FILE)
Writes one JSON object per line, flushed per event: module maps, TLS
callbacks, DllMain results, the first call of each unimplemented import
with its caller as module+RVA, OutputDebugString text, exceptions with
module+RVA and a short unwind, and the exit code. A vectored handler
records and returns EXCEPTION_CONTINUE_SEARCH, so behaviour is unchanged.
Off by default.

startup_trace_test builds a synthetic DLL image (no game data) and
checks each event kind.
2026-11-22 12:03:22 -03:00
17a27f23cc d3d12_present_test: check the presented images through the capture, GDI screen read only where it works
Under Wine's macOS driver the test failed at its last step, the GDI read of the screen: GetPixel on the screen DC
returns CLR_INVALID there for every pixel, even one GDI painted itself (BitBlt from the screen DC fails too), and
the window's own DC holds Wine's GDI surface (white), not the image presented through the Metal layer. The
presenter itself was fine: all the injected-failure checks passed, MoltenVK made 320x240 and 400x300 swapchains
at contents scale 1.0, and the driver reported no out-of-date presents. The "present failed" lines in that log
(VkResult -1000001004 twice, then -1 = VK_ERROR_OUT_OF_HOST_MEMORY) are the test's own injections; markers around
them showed each line inside its injection.

The test now enables the presenter's capture and checks the whole presented image for the clear colour at the
swapchain's size after the first 60 frames, after the resize and at the end, on every platform. The screen check
stays where GDI can read the screen; a CLR_INVALID there is reported and skipped instead of failing. The test also
says on stderr that the next three "present failed" lines are expected, since they were read as faults twice.
Checked under CrossOver's Wine 11 with MoltenVK 1.4.3 on an Apple M3 Max: the test passes, and with the clear
colour changed the capture check fails at the first 60 frames.
2026-11-22 18:59:21 +04:00
7886972a6b Merge upstream main
# Conflicts:
#	docs/d3d12_command_objects.md
2026-11-22 09:48:41 -05:00
c7801ac6fb Merge upstream main
# Conflicts:
#	docs/d3d12_vulkan.md
#	runtime/README.md
2026-11-22 09:35:55 -05:00
088447e117 FSPX programs: translated by the shaders stage, found at run time by their kind-6 bytes (RT-99)
The FidelityFX DLL creates its compute pipelines from FSPX programs (docs/fspx.md): through slot 67 with the bare
kind-6 program, then through slot 62 with the DXBC container whose ACCC part holds the payload. Both ended in
E_INVALIDARG: the layer took only FSSM bytecode, the build never translated the DLL and the index had no key for it.

- make_game.py: the shaders stage unpacks the package's DLL with tools/fspx_unpack.py --disasm into
  <work>/shaders/fspx and translates it into <work>/shaders/spirv/fspx, with the same wave64 mode and fallback
  flags. The step is redone as a whole when the DLL, its tools, llvm-mc or the flags change (fspx_build.json,
  written last) and never makes the game's shaders run again.
- tools/shader_meta.py: an entry of a program without an FSSM blob gets fspx_code_sha256, the SHA-256 of
  fspx/<name>.code.
- runtime/src/shader_library.h: the library also loads <dir>/fspx/index.json and finds entries by
  fspx_code_sha256. compute_program() takes an FSSM program as before, the kind-6 bytes of an ACCC container or of a
  bare FSPX payload, and a bare kind-6 program recognized by its prologue; the directory is parsed with the DLL
  reader's rules and bounds-checked, so a malformed one is refused.
- create_compute: looks the program up by the key of its kind and uses those bytes as the code base.
- Tests: shader_library_test (parsing, malformed directories, lookup, the fspx folder), d3d12_fspx_compute_test
  (PSOs from both forms, a dispatch each, refused inputs) and tests/test_fspx_shaders_stage.py.
- Docs: the lookup in docs/fspx.md; slots 62 and 67 in d3d12_command_objects.md and d3d12_vulkan.md. The size the
  slot-67 description carries at +0x30 is kind 6's own size, read from the DLL's code.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 09:22:54 -05:00
a3263e79e6 Merge pull request #1757 from Vonsek 2026-11-22 09:15:07 -05:00
22888d4e65 Runtime: test the shader lookup against a translated corpus
shader_library_corpus_test runs src/shader_library.h over the work folder
make_game.py builds from the player's copy (LEONIDA_SHADERS=<work>/shaders/spirv,
containers from <work>/shaders/dxbc or LEONIDA_SHADER_DXBC), as the D3D12
layer does with a PSO's bytecode: inflate the FSSM program, hash it and look
it up under the stage the DXIL program header names. Every container must
find its own index.json entry and a readable .spv, every entry must be
reached, and in containers with more than one 0x0D payload no earlier
payload may be the indexed program.

Without LEONIDA_SHADERS it prints SKIP and exits 77 (SKIP_RETURN_CODE).
On the 1.0.2.1 corpus: 26,503 containers, all resolve, 195 with more than
one program. With fssm_program switched to the first payload it fails
(391 failures, 26,308 of 26,503 entries reached).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 14:54:56 +01:00
705a40bda9 Tests: a compute dispatch that samples through set 0 (d3d12_set0_compute_test)
Since #1489 the layer binds the device's bindless set at every dispatch as well as at every draw, but only the
draw has a test (d3d12_m2_textured_test): d3d12_compute_test takes the binding-free index entry on purpose, and
d3d12_descriptor_test samples through set 0 with a Vulkan pipeline of its own.

This test covers the compute bind point through D3D12 alone: a compute PSO whose index entry lists set-0
bindings, two SRVs, bytes no view was made for, and a wrapping and a clamping sampler. Four dispatches of
test/glsl/cs_set0_sample.comp (GLSL written to the translator's contract) load the T# and the S# from the
descriptor tables, find them in the hash table and sample: the two textures texel for texel, the fallback image
for the unknown bytes, and the right edge with the clamping sampler. A device without the bindless set refuses
the PSO. Registered with ctest like its neighbours (exit 77 is a skip).

With the vkCmdBindDescriptorSets call of the compute bind point removed from replay, this test fails
(VUID-vkCmdDispatch-None-08600, on llvmpipe).

Checked with a mingw-w64 build under Wine on llvmpipe, an RDNA2 integrated GPU and an RX 7900 XTX (RADV), with
the validation layer: exact, no validation errors. Not built with MSVC.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-22 08:19:04 -05:00
a0acd33d77 Docs: one Other languages line, and runtime/README links docs/runtime_imports.md
Two i18n PRs merged as "both" left docs/README.md with two quickstart lines (test_i18n_index); #1551's link in
runtime/README.md pointed at runtime/runtime_imports.md instead of docs/ (test_docs_links).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 08:02:25 -05:00
41557027b6 Merge pull request #1551 from HQasper 2026-11-22 07:38:08 -05:00
a98f9925b0 gta6rt: map GAME: console paths, and send writes to an overlay (RT-97)
A mapped title names its files on the console's drives, but nothing mapped them: the file calls went
straight to the host and --game-dir was only used to find modules, so the first file a title opens at boot
would fail. New shims for CreateFile*, FindFirstFile*/FindNextFile*/FindClose, GetFileAttributes*/
GetFileAttributesEx* and DeleteFile* (kernel32, kernelbase and the api-ms-win-core-file sets) map a GAME:
path under --game-dir, and send every open that can write and every delete to --overlay (default
<game-dir>\overlay), which reads and listings prefer. A write-open copies the package file into the overlay
first, so OPEN_EXISTING keeps its bytes, and a delete of a package file leaves a marker instead of removing
it, so the package is never modified. A path that climbs above GAME: with ".." or names another drive is
refused with ERROR_INVALID_NAME. A path without the prefix is still a host path.

The prefixes and the overlay come from ivall/xcl (GPL-2.0-only), as facts only, no code.

file_system ctest: 43 checks over folders in %TEMP%, covering mapping and case, copy-up and read
preference, a new file in folders the package lacks, delete and re-create, the merged listing, host-path
passthrough, the escape refusal and the narrow variants.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <noreply@codebuff.com>
2026-11-22 13:11:57 +01:00