Search Issue Tracker

Active

Votes

0

Found in

6000.0.60f1

6000.2.8f1

6000.3.0b6

6000.4.0a2

Issue ID

UUM-122634

Regression

No

Constant buffers are redundantly uploaded when consecutive compute dispatches are executed on DirectX11

-

Reproduction steps:
1. Open the attached project "ReproProj"
2. Open the “/Assets/Scenes/SampleScene.unity” Scene
3. Right-click on the Game view tab and select “Load RenderDoc“
4. Enter the Play mode
5. Select the “Camera“ icon at the top of the Game view to take a RenderDoc Capture
6. Load Capture in RenderDoc
7. In the Event Browser, filter by term “ExecuteSetPositionsBuffer“
8. Expand “UIR.DrawChain“
9. Expand “SceneCamera.Render“
10. Select “ExecuteSetPositionsBuffer“
11. Remove the search term and press the “Enter” key
12. Expand “ExecuteSetPositionsBuffer“
13. Observe the first and second dispatch

Expected result: The second Map/Unmap/CSSetConstantBuffers sequence is skipped
Actual result: CSConstantBuffer-0-16 is being Map/Unmap twice between two consecutive Dispatch calls

Reproducible with: 6000.0.60f1, 6000.2.8f1, 6000.3.0b6, 6000.4.0a2

Reproducible on:
Play Mode

Could not test on:
Windows Standalone Player (Assets\Scripts\MeshSaverEditor.cs(7,40): error CS0246: The type or namespace name 'MenuCommand' could not be found)

Testing environment: Windows 10 Enterprise 21H2
Not reproducible on: No other environment tested

Notes:
- Reproducible with DX11
- Not reproducible with DX12
- Reproduction code is present in “RedundantConstantBufferTest.cs”
- Forum threads: https://discussions.unity.com/t/redundant-constant-buffer-writes-between-compute-shader-dispatches/1681303 , https://discussions.unity.com/t/3-questions-about-compute-shader-performance/857993

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.