D3D11: Note that the state object caches are deliberately never trimmed

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
This commit is contained in:
Henrik RydgårdandClaude Opus 5.5 committed 2026-09-29 12:43:12 -06:00
1 parent 1b8553956f
commit 74553bfa1a
1 file changed
+3
+3
View File
@@ -110,6 +110,9 @@ private:
PushBufferD3D11 *pushInds_ = nullptr;
// D3D11 state object caches. Previously had smart pointers but they were harder to deal with.
// These are never trimmed, although D3D11 allows only 4096 unique state objects per type and a
// failed create is fatal. That's deliberate: games use far fewer combinations, so it isn't an
// issue in practice, and eviction would cost more than it's worth.
DenseHashMap<uint64_t, ID3D11BlendState *> blendCache_;
DenseHashMap<uint64_t, ID3D11BlendState1 *> blendCache1_;
DenseHashMap<uint64_t, ID3D11DepthStencilState *> depthStencilCache_;