The frame is not the card's: with every scissor empty it took as long (97.8 ms against 97.3), with
every mesh draw of no group 85.7, with every dispatch left out 77.0 (LEONIDA_AB over the three
LEONIDA_EXP_* switches, 9,300 draws a frame, 2026-11-27). A profile of the submitting thread alone
(LEONIDA_PROFILE_ONLY, new: 17,711 rounds in 35 s where the 28 busiest threads gave 125) had a quarter
of its running time in the system heap. Built with the mimalloc feature the same view takes 78 ms a
frame against 93-98, so scripts/build-nvidia.ps1 builds with it.
LEONIDA_PLACED_TITLE=1 (off by default): a copy at its place in a list into bytes that flights have
declared but no shader wrote lately is taken by title memory at submission, so the fill that reads it in
the same submission does not wait for every flight to land (44-48 ms once a frame at the save, named in
the frame line now); a landing leaves alone what title memory holds already (LEONIDA_LAND_SAME), so that
such a copy is not noted as a shader's write to its page. The wait went from 1.00 to 0.08-0.36 a frame;
the frame's length did not change measurably with the system heap in the way.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Upstream's four commits past 6a31e43 (5b36758, 9e7ab9d, 6395727, b190242;
GPL-3.0), brought in as a three-way merge: upstream's trees before and after
written under Leonida's names (crates leonida-*, LEONIDA_* settings) and the
difference merged onto Leonida's own changes. What comes with it, by its
authors:
- the renderer of codec-d/cool_fox f4b48ad (CGBJ) with trustno1-coder's NVIDIA
fixes on top (residency.rs, stretch.rs, the title's upscale dispatch);
- DLSS for the title's upscale, from avatarmanz/VIctory-7900XTX pull request
203 (feature dlss, LEONIDA_UPSCALE=dlss): the game renders its own 720p and
DLSS takes it to 1080p on the Series S profile;
- DLSS frame generation through NVIDIA Streamline (streamline.rs, fg.rs), an
F1 settings menu (host/menu.rs), LEONIDA_FPS_CAP, real ray tracing as an
option (LEONIDA_BVH_BUILDER=1: the structure builder runs on NVIDIA).
NVIDIA's own files (DLSS, Streamline) are not part of the repository:
d3d12/Get-NVIDIA-DLSS.cmd fetches them from NVIDIA's GitHub into
d3d12/nvidia-sdk/ (git-ignored).
Where both sides had changed the same lines:
- compose.rs is upstream's (planes drawn by a pixel shader into the back
buffer); Leonida's LEONIDA_SHARPEN lived in the compute pass it replaces
and is not in this commit (DLSS has its own sharpness setting).
- draw.rs keeps Leonida's slow-beat texture re-check (300 frames by default);
upstream's switch of the same name is dropped.
- ambient.rs keeps LEONIDA_AMBIENT_MOST and the reflection guard.
- play-nvidia.ps1 is upstream's with Leonida's defaults put back while rays
are off: strict indirect batches (INDIRECT_BATCH=1), the light stand-in
(AMBIENT=0.8, AMBIENT_MOST=2), ray walks ended at the root and the
ray-resolve skip list. With upstream's defaults (stand-in off, no skip
list) shade was black and the sky white in the world, and the card worked
33-50 ms a frame (run n1).
- scripts/play-d3d12.ps1 follows the new launcher: DLSS by default, a shader
cache of its own (cache-2), -NoDlss, -RayTracing, -Capture, -Log.
Builds with and without the dlss feature (cargo build --profile diag
-p leonida --features diagnostics[,dlss]). In the world on an RTX 4060 Ti 16 GB
(driver as installed) and a Ryzen 5 7600X: DLSS starts (1280x720 to
1920x1080), about 14 fps where it was 13.4. The picture is not right yet: a
posterized look in run n2 is being traced. AI-assisted.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>