Low FPS without any obvious cause in profiling, am I missing something?

Hi!

I’m having bad performance (60 FPS on 3070; 8-10 ms draw) without an obvious reason.

This is on a landscape with some grass, the Brushify material, and some trees, so there is not a lot of optional complexity.

My profiling stats look like this:

Draw calls seem fine, but everything in stat gpu seems to be equally problematic:

  • Basepass is 8-10ms and the culprit is a ton of occlusion culling, probably because the scene contains trees, but I already reduced their cull distance as much as possible (256m).
  • 2ms for “LumenScreenProbeGather” and 1ms for “LumenSceneLighting” appear to be a Lumen tax I can’t get rid of. Using screen space lighting instead results in a small performance improvement but causes noise artifacts on trees and grass.
  • 2ms for “ShadowDepths” is a lot, I’m using Ultra Dynamic Sky with shadow cascades turned down to 1 and (for now) no other lighting.
  • 2M tris is a lot, but the scene contains landscapes (the open world is assembled at runtime out of 253x253 tiles).

Where should I be going from there? Nothing jumps out as being terribly bad, except the occlusion culling, but that seems to be a consequence of having trees?

Thanks for any help!

Hi Ravengild, Welcome to the Forums.

I’m curious to see what the simple GPU profile looks like. While playing press CTRL + Shift + Comma . (You can ignore anything that says ‘Slate’ that’s just editor stuff)

1 Like

Thanks!

I did some optimizations (virtual textures, forward rendering, screen space lighting instead of Lumen) and have good and bad news. The good news is that I got BasePass way down - only for Shadow Depths to shoot up and eat up most of the gains.

BasePass looks like this now:

And this is Shadow Depths, which now easily peaks at 5ms or more with all sorts of settings (shadow resolution, cascades) set all the way to minimum, grass dynamic/contact shadows disabled, and one light source (sun):

Ultra Dynamic Sky is involved, but I don’t think it is broken, rather it is currently the only light source. This is a weird shape for a shadow map (rectangular?) and I really don’t need 4K shadows but I don’t know how to reduce it.

And that’s 5ms with shadows set as low as I can set them. If I increase anything about shadows to sensible values, shadow depths skyrockets to 10ms or more.

This is regular shadow maps with a dynamic sun; virtual shadow maps are a total disaster.

Half of my total render time is lost to shadows. How on earth did I break this?

To be fair, my virtual texture is huge; I’m building a map at runtime and the virtual texture covers the whole map, close to the maximum dimensions of the virtual texture sampler box. But shadows aren’t drawn in most of that, and surely someone has been able to use trees without wrecking performance?