Threading in Unity

Single thread / direct -force-gfx-direct

  • Main thread
    • device
Multithread / client+worker pair -force-gfx-mt
default, and if GraphicsJobs checkbox is off

  • Main thread
    • device
    • client
  • Render thread
    • device
    • worker

Graphics Jobs / legacy -force-gfx-jobs legacy

Cpu command – run in linear
Render command – run in parallel

  • Main thread
  • Render thread
  • Job thread
  • client on each job thread
Graphics Jobs / native -force-gfx-jobs native
if GraphicsJobs checkbox is on.
if platform / API doesn’t support native then will fallback to legacy
only in player + Vulkan / DX12 / Metal

Cpu command – run in parallel
Render command – run in parallel

  • Main thread
    • device
    • client
  • Render thread
    • device
    • worker
  • Task execute
  • Job thread
    • N render thread

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s