Skip to content

HW ray query is opt-in — a stray DLL no longer costs 40% frame rate#111

Merged
proggeramlug merged 1 commit into
mainfrom
fix/hw-gi-opt-in
Jul 16, 2026
Merged

HW ray query is opt-in — a stray DLL no longer costs 40% frame rate#111
proggeramlug merged 1 commit into
mainfrom
fix/hw-gi-opt-in

Conversation

@proggeramlug

@proggeramlug proggeramlug commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Granting EXPERIMENTAL_RAY_QUERY converts a game to the HW GI path (SSGI/WSRC flip once the TLAS exists; every skinned draw pays per-frame pre-skin + BLAS). Measured on the shooter: 14.4 vs 20.3 fps, PT off. Now the feature is requested only on explicit opt-in (BLOOM_HW_GI=1, BLOOM_PT, or --pt) — PT workflows unchanged. Boot prints the decision, and the SW path's runtime tiering (hiz-screen → sdf-clipmap) prints too.

Also recorded: the tempting "HW loses sun shadows" screenshot finding was retracted — the drifting cloud deck confounds captures minutes apart. Clouds-off same-scene A/B is the prerequisite for any future HW default.

Summary by CodeRabbit

  • New Features

    • Hardware ray-query global illumination is now opt-in on Windows through supported environment variables or the --pt argument.
    • Startup logs now show whether hardware GI or software GI is active.
    • Software GI reports its runtime tier during startup and after baking.
  • Documentation

    • Added guidance for comparing hardware and software GI performance, including warm-up timing recommendations.
    • Documented unresolved cloud-shadow differences and requirements for repeatable A/B comparisons.

…anted-by-default

Measured on the shooter (760M, PT off, 60 s gameplay averages): merely
granting EXPERIMENTAL_RAY_QUERY costs +20 ms/frame (14.4 vs 20.3 fps),
because ssgi/wsrc flip to the HW trace the moment the TLAS exists and
every skinned draw starts paying per-frame pre-skin + BLAS builds.
Nobody should get that by accident because dxcompiler.dll sits beside
the exe. Existing PT workflows keep working: --pt and BLOOM_PT request
the feature at device creation as before.

Boot now prints the decision (hw-gi opt-in: want_hw=/force_sw_gi=),
closing part of the 'boot line lies' gap - and the run that verified
the gate also showed the SW path is tiered (hiz-screen -> sdf-clipmap
once baked; both print).

Registry notes the retraction discipline: an apparent 'HW loses sun
shadows' screenshot difference did NOT survive scrutiny - the drifting
cloud deck confounds captures taken minutes apart. A real GI quality
A/B needs clouds off and is recorded as the prerequisite for ever
defaulting HW on.
@proggeramlug
proggeramlug merged commit ffb7d23 into main Jul 16, 2026
@proggeramlug
proggeramlug deleted the fix/hw-gi-opt-in branch July 16, 2026 12:20
@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 8a2c707a-a2de-4ea7-ab4a-9caf52432320

📥 Commits

Reviewing files that changed from the base of the PR and between 580dc17 and 66dad5b.

📒 Files selected for processing (2)
  • docs/tickets.md
  • native/windows/src/lib.rs

📝 Walkthrough

Walkthrough

Windows hardware GI ray queries are now opt-in through environment variables or --pt, with startup logging of the decision. Documentation records software GI runtime tiers, timing guidance, and unresolved cloud-free A/B verification.

Changes

Windows GI opt-in

Layer / File(s) Summary
Ray-query gating and verification
native/windows/src/lib.rs, docs/tickets.md
Windows computes hardware GI opt-in from BLOOM_HW_GI, BLOOM_PT, or --pt, honors forced software GI, logs the decision, and documents runtime-tier verification details.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/hw-gi-opt-in

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant