verify_translation_completeness compares only the number of entries, so on a
resumed shader stage an index left by other inputs with as many entries as the
carve passed for this folder's finished translation and no step ran.
A shader keeps its carved file's stem through unpacking, disassembly and
translation, so the stage now compares the index's names with the carve's: on
resume a stranger drops the index and its shard plan and translates again, and
after a translation a stranger fails the stage and removes the index and its
shard plan, so that a later run of the pipelines stage alone does not take the
index as finished and the next run of this stage does not merge the same parts
again. The names are checked before the counts. The disk-space check no longer
counts such a folder as reusable.
The index is read with read_translation_index and the carve with shader_stems,
as the other steps read them (a UTF-8 BOM included).
The fixture in test_make_game_empty_translation.py named its carved shader
"shader" and its translated one "shader_0"; it now uses one name.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
- `Host::new` takes the high-performance adapter first
(`EnumAdapterByGpuPreference`), then the default as before. On a laptop
the default adapter is the integrated GPU, so the GPU tests ran there.
- `TIME_REPEATS` (tests only): `Host::dispatch` runs the dispatch n times
between two GPU timestamps, each behind a UAV barrier, and leaves the
microseconds of one.
- `packing_times` (ignored, run by hand): the 32-thread console program of
the pack tests, unpacked and packed 2, 4 and 8, over 1,024, 8,192 and
57,600 groups, every run's stores checked against the console's.
Measured on an RTX 4060 Laptop GPU (8 GB, Ada), driver 621.01, Windows 11
build 26300, four runs, least of three per point, us a dispatch:
shape groups unpacked packed 4 gain
32x1x1 1,024 1.9-2.7 1.5-2.2 1.2x
32x1x1 8,192 9.7-11.9 5.4-8.1 1.5-1.8x
32x1x1 57,600 119-143 119-122 1.0-1.2x
8x4x1 8,192 9.2-9.9 5.2-5.5 1.8x
8x4x1 57,600 119-125 119-126 1.0x
Packed 4 was never slower than unpacked; packed 8 is worse than 4 for
32x1x1. At 57,600 groups the program writes 29.5 MB in about 120 us
(about 240 GB/s, the card's memory bandwidth), so that point measures
memory, not launch.
This is the best case: a program of 16 VGPRs and next to no arithmetic.
In the game on an RTX 3070 Ti (Wine, VKD3D-Proton), `LEONIDA_GROUP_PACK=4`
made the GPU wait longer (8.7-14.5 -> 25-52 ms; djrolfes in #1608, who
suspects the register pressure of the packed programs that use many
VGPRs: 554 of the 1,396 packed use over 128). So this does not turn
packing on. What it gives is a way to measure a packing rule on a card
before a game run, for example packing only programs under some VGPR
count.
leonida-shader --features host --lib: 365 passed, 0 failed, 5 ignored, on
that card. AI-assisted (Claude).
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
- Shader translator: a float maximum or minimum with a constant that is not a zero leaves out the test for two
zeros (LEONIDA_MINMAX_NONZERO), and the median of a value and two normal constants is a clamp
(LEONIDA_MED3_CLAMP), from trustno1-coder/VIctory-NVIDIA d08360e3 (mizzied). Both store the same bits: test
float_max_min_and_med3_with_constants_store_the_same_bits_rewritten, on the card and on WARP, over signed zeros,
denormals, NaNs and infinities. Retranslated and warmed in run d53 with no failure.
- play-nvidia.ps1 sets LEONIDA_PORT_GUARD=1 (renderer port 6): in turns of 4 s standing (runs d50, 147 phases) the
frame's median -0.47 +-0.18 ms, the submitting thread -0.58 +-0.11.
- DirectStorage requests are told apart in a timeline: reading the source, inflating, unpacking BCPack.
- findings: the present smoother costs nothing by turns (runs d52: frame median -0.14 +-0.42 and -0.33 +-0.34 ms,
the jitter of the title's presents from a median of 8.7 ms to 6.6 and 7.5); where the two walls stand.
AI-assisted (Claude). Tested on an RTX 4060 Ti, driver 616.64, Ryzen 5 7600X, Windows 11 (Series X profile, 1440p).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main routes UAVs through image_descriptor (storage); the PR's test expects a
UAV of a typeless texture without a view format to stay a null descriptor,
as D3D12 refuses it.
Co-authored-by: justr4mzi <243612488+justr4mzi@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
runtime/shims/d3d12_vulkan_device.cpp: main made image_descriptor serve
unordered-access views too (storage), added the title texture registry
beside it and moved the buffer SRV encoding into write_buffer_srv. Main's
code is kept and the PR's checks are applied to shader-resource views only
(!storage): the component mapping and ResourceMinLODClamp at the start, the
typeless view format checks before the format path, the mip and layer
range checks after main's layer bounds; and the buffer SRV mapping check
before CreateShaderResourceView calls write_buffer_srv.
Co-authored-by: justr4mzi <243612488+justr4mzi@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
From the review of old upstream PR 4578: nothing tested the fix in `follow`, so removing it failed no test. tests/cancel.rs
starts a stand-in that would run for half a minute, as the launcher starts a command (its own process group;
a tree `taskkill /T` ends on Windows), presses Cancel while `running` has no pid yet and checks the stand-in runs
on, then sends `Process(Started(pid))` and checks it ends within 10 s.
With the fix's lines removed the test fails ("a Cancel before Started left the process running"); with them it
passes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
.github/workflows/launcher.yml builds and tests launcher/ on Windows and Ubuntu: `cargo fmt --check`,
`cargo clippy --locked --all-targets -- -D warnings` and `cargo test --locked`. It needs no GPU, no display and no
game files, as the tests draw the window offscreen on the CPU and run a stand-in script for make_game.py.
It runs on pushes to main and on pull requests that touch launcher/**, assets/logo.png (built into the launcher)
or the workflow itself, as the Runtime workflow lists what can break it. Actions pinned to a commit as elsewhere,
Rust from the runners' own rustup, read-only permissions, a concurrency group and a timeout.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Two points from the review of old upstream PR 4578:
- A Cancel pressed before the process's Started event arrived set `cancelled` but had no pid to stop, and
Started then stored the pid without looking, so the command ran on. Started now stops it when Cancel came
first (launcher/src/app.rs).
- tests/test_docs_cli_flags.py was red: launcher/README.md quotes cargo's `--all-targets` and the test runner's
`--ignored` and `--nocapture`, which no scanned source names. They join FOREIGN, the other programs' flags the
docs quote.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- The main action's fill in dark is the logo's orange with the logo's shadow as its ink, as in
light, so it stands out on the purple page; its hover glow was orange already. Pressed, its
line is the main purple where the secondary would vanish on the fill.
- The buttons beside the main one (Check, Build) are large too, so the row lines up.
- The veil over the scene holds full strength to 0.35 of the way (was 0.15), still at 0.85.
- Its color is the background tinted toward the logo's purple in dark (18%) and its orange in
light (12%), Palette::veil; every ink keeps 4.5:1 on it, and a test checks it.
- On a mode change the old veil now fades out as the new one fades in. It stayed whole under
the new one, and as both are see-through it showed through to the end and then vanished at
once.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Focus rings appeared and vanished at once on the switch, the header bar's pill, the sidebar,
text fields, the output area and the choice cards; on buttons and the close button the ring's glow
faded in but the ring was dropped the moment focus left, so it never faded out. Each now keeps
its ring in a Lit and draws it, line and glow together, at that share, while it fades out too
(paint::outline_lit and outline_faded).
The Performance page's choice cards faded nothing: their hover glow, chosen glow and the radio
circle's glow now each have their own fade, and the hover glow gives way to the chosen one as a
card is chosen.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The status line sent the player to "Settings", a page the window doesn't
have; it names the Game files page now.
A test draws every page and the Play page's states, in both modes, at
the smallest window, the default and 1920x1080, for a look over the
whole launcher, and checks that none is blank.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Text fields took the control radius (10) while buttons took 8; fields
now take the buttons' radius, so a field and the button beside it match.
Every glow fades in over motion::GLOW_IN and out over motion::GLOW_OUT,
as the buttons' do: a switch's glow while on had ridden its knob's
150 ms slide, and a text field's hover glow came at once; both have their
own fade now.
Tests: a button and a text field under the pointer, and a switch turned
on, are part lit halfway through GLOW_IN and whole at its end, in both
modes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The scene's picture is the scene alone again, its sun's glow back; the
fade that was baked into it, which followed the text column and so
looked wrong on small windows, is gone, and with it the column's width
from the scene's key.
Over the scene the window lays a veil: the page's background at 0.85,
held a little in from the top left (0.15 of the way), then thinning on
a straight line to nothing at the bottom right corner, the bend rounded
over 0.10. It is a 512 by 512 picture, dithered against banding, made
once per mode at start and stretched over the page as it is drawn, so
it follows a resize at once. A mode switch crossfades the two veils
with the theme (Chrome::theme_fade).
Tests: the veil holds, then falls in equal steps with no jump or step
in slope; its picture is the background at the veil's opacity in each
mode.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Play page's scene didn't appear after launch: nothing scheduled the
first tick at boot, and later ticks came only when the scene's key
changed, which at scale 1.0 and the default size it never did. The scene
cache is rebuilt so that no wanted picture is stranded:
- Launcher::boot, which main uses, schedules the first tick at once; after
every message, a wanted picture that isn't made, isn't in flight and has
no tick due gets one.
- At start both modes' pictures are made at once, the current one first,
off the interface's thread; only after a resize does the size have to
hold for 150 ms, while the last picture shows, scaled to cover.
- A picture fades in when it's ready (motion::SCENE_IN, 500 ms), a mode
switch crossfades between the two made pictures, a resize's new picture
crossfades over the old; frames are asked for only while a fade runs.
- The sun's radial glow is gone from the scene.
Glows fade in over motion::GLOW_IN (500 ms) and out over
motion::GLOW_OUT (700 ms): hover on buttons and window buttons, and their
focus rings' glow. The waiting status chip's ring and small light are the
secondary colour in dark, the logo's orange, instead of muted purple.
Tests: a real launch as main boots it, its tasks run on threads, at the
default size and scale, on another page, folded and with the frame off;
two generations per page, none on mode switches; the fade starts only
once a picture is ready and asks for nothing once it's whole; every chip's
word on its tint at 4.5:1.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- tests/keyboard.rs drives the window by keys alone, offscreen: Tab and
Shift+Tab through the header bar, sidebar and pages; Enter and Space on
the main and close buttons and the switches; arrows in the sidebar and
the pill; typing into a field; Ctrl+Page Down and Up, Ctrl+L.
- tests/backdrop.rs counts the scene's generations with a stand-in: one
per distinct final key through redraws, pointer and focus moves, page
switches, a burst of resizes and mode switches back and forth (3 in
all); and the last scene stays on the page while a resize goes on.
- tests/screenshots.rs draws every page in both modes on tiny-skia (CPU,
no display), the Play page's states, the scene at two window sizes and
the folded window. The renderer can be chosen with
LEONIDA_TEST_RENDERER.
- launcher/README.md: building and running, the pages and the flag or
variable each control drives, the keys, the window frame on Linux and
Windows, the scene, the design system, the licence, and what isn't done.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
One window: the header bar with the app's name, the light and dark pill
and the close button; a sidebar with five pages that folds below 640
pixels; one focus scope round all of it; Ctrl+Page Down and Ctrl+Page Up
step through the pages, Ctrl+L switches light and dark with a crossfade.
- Play: the logo, the launcher's and the game copy's versions, the status
line and one big main button (Check, Build, Play or Cancel) in the text
column over the scene; the progress bar and the output on an opaque
panel.
- Game files: the package, output and work folders, each a field with the
native folder picker; the full check.
- Build: the stages and WAV audio, as switches.
- Performance: LEONIDA_VK_DEVICE, LEONIDA_VK_VALIDATION, --wave64-emulate
and --jobs.
- Diagnostics: gta6rt --trace-d3d12, LEONIDA_UNIMPLEMENTED and
gta6rt --overlay.
The scene is generated off the interface's thread, once per page size,
scale, theme, mode and column, after the size has held for 150 ms, and
cached for both modes; drawing a frame only shows the cached picture.
The logo is decoded once.
`leonida-launcher [--repo PATH]`.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
src/scene.rs draws a dusk (dark) or a morning (light) over water, with a
shore and two palms in silhouette, as one RGBA picture of the page's size,
from the theme alone: its gradient's six stops, its background, its mode,
and its outline and shadow colours. No image files.
The soft layers (sky, water, glow, clouds, sun, reflection, horizon line)
are computed per pixel; the shore and palms are filled as anti-aliased
paths with tiny-skia, the version iced already builds. The scene's 16:10
frame covers the page from its bottom right. The page's background lies
at 0.97 over the text column and fades out beside it, so the muted ink
keeps 4.5:1 there; however narrow the page, the scene stays. A floating
window's rounded corner is cleared in the picture.
About 30-34 ms for a 1040x754 page in a release build.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Buttons' and window buttons' glows fade in and out with the pointer
(transition::Lit).
- The light and dark pill drags as a switch does: its highlight follows
the pointer, slides into place, and the choice changes when it's let go;
a click or a key slides it too. The header bar leaves that drag to it.
- The sidebar's chosen-row mark is the logo's orange in both modes, for
contrast against the purple-tinted row.
- The gap between the pill and the close button is the close button's
own margin, as at the window's edge.
- The app's name in capitals sits on the bar's middle.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>