Huge performance lost switching from Built-in Render Pipeline (BiRP) to HDRP

Hi,

I’m using 2019.4.1.17f1 and already turned off everything I don’t need on HDRP Asset and Frame Settings.

The scene is an interior one and really simple, with BiRP it takes ~2ms (~1ms for GPU). Well, it is CPU bound, but both CPU and GPU durations are very small, so neither is considered a problem.

However, after switching to HDRP, it take 10+ times long. It is now more severely CPU bound.

I don’t really understand what the costly functions in the Profiler mean:

  • RenderPipelineManager.DoRenderLoop_Internal
  • Inl_HDRenderPipelineAllRenderRequest
  • Inl_HDRenderPipeline::Render New Game Object
  • SRPBRender.ApplyShader

GPUView shows there are ~15 D3D11 submissions, between each 2 of them there is ~50% GPU idle (There is GPU works immediately after submissions, in later half GPU is idle). With D3D12, there is only 1 frame’s work every 4 VSync’s, many many small works on Copy queue, even more and smaller rendering submissions each with some KMD work.

I know someone says HDRP has some base cost, but how can the GPU idles so often? Even if HDRP is considered scaling well, it should be able to handle small scene with just a few lights.

Thanks.

But it doesn’t scale well. It also does have notably bigger initial overhead compared to built-in renderer.

Then how can it be used?..

The GPUView trace shows a simple interior scene with 15 D3D11 command buffer submissions, each with substantial GPU idle… Engine programming practices not followed?

An engine, no matter how well it scales, or how much initial base cost, should be able to eliminate the cost if you don’t need extra features and run really, really fast on simple scenes. In most cases, games are GPU-bound. Games might be slightly CPU-bound and even in those cases, GPU idle should be continuous within a frame and only appear before all GPU work instead of scattered in every submissions.

1 Like

HDRP is more targeted to high end visualization, high end pc gaming and game consoles (minus weaker ones like Switch). I’d love it to scale down better as well. If you need this, URP or Built-in is better pick today.

In addition, atm HDRP can get CPU bound easily.

Good use of graphics API should not result in large GPU bubbles…

HDRP D3D12: a simple scene with 7 boxes, I can see:

  • VSync off: many small command buffer submissions & GPU bubbles
  • VSync on: No Graphics queue bubble but many small Copy queue works are still there (Turning on VSync fixes command buffer submissions is definitely a BUG.)

My scenes are due to some reflection probes are converted to realtime ones in HDRP.

But the sample scene of the default HDRP template project still show many GPU bubbles.

This is literally the only hit on Google for “Render New Game Object” - did you work out what that was? I’m apparently doing 12 of them per frame. If I pause Unity, my framerate is in the hundreds; if I hit ‘Play’, the FPS drops to 12, most of the time being spent in “Render New Game Object”

1 Like

I found what it was in my project - a planar reflection probe. If set to update mode ‘On Enable’ rather than ‘Every Frame’ it fixes the issue but the reflections remains as desired.

1 Like

Hdrp has way more features than birp and most of them are enabled by default. Also, Hdrp has more complex lighting model and light loop. Because of it’s complexity, Hdrp is for the game that target 60 fps only.