Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17560

short cmdlist vs. long cmdlist

$
0
0

Hey Guys,

 

For recommendations of building commandlist in dx12, I remembered one which said that a good strategy is to have 12~20 draw calls per commandlist. Without wondering the reason behind it, I blindly target to fill around 12 draw/dispatch calls before submit my cmdlist to GPU in my 'single-thread' renderer.... Today after I fixed a GPU time stamp bug, I realized that my GPU always idled half of frame time.... GPU is waiting CPU 'accumulating enough draw calls' to hand the cmdlist to GPU...

 

Now I totally changed my strategy: as long as I know some draw/dispatch will take reasonable time for GPU, I submit it immediately to GPU even there may only be 1 draw/dispatch in that cmdlist, so while GPU is working on the job, CPU is building new jobs for GPU... (please let me know if that strategy is also not recommended...)

 

But why it is recommend to have 12~20 draw/dispatch per commandlist?   what's the difference between short and long cmdlist in terms of CPU/GPU overhead?

 

Thanks in advance 


Viewing all articles
Browse latest Browse all 17560

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>