Hi,
We’re upgrading to 5.6 and noticed that in Unreal Insights, the GPU events recorded with macros like RDG_EVENT_SCOPE have their text not formatted properly if they are using printf-like arguments (%s, %i etc). For example in TemporalSuperResolution.cpp line 1973:
RDG_EVENT_SCOPE_STAT(GraphBuilder, TemporalSuperResolution, "TemporalSuperResolution(sg.AntiAliasingQuality=%d%s) %dx%d -> %dx%d", CVarAntiAliasingQuality->GetInt(), bSupportsAlpha ? TEXT(" AlphaChannel") : TEXT(""), InputRect.Width(), InputRect.Height(), OutputRect.Width(), OutputRect.Height());
Produces an event with the text:
“TemporalSuperResolution(sg.AntiAliasingQuality=%d%s) %dx%d -> %ds%d”
So the arguments are not inserted in the string.
We have several RDG_EVENT_SCOPE_STAT in our own code and most suffer from the same issue, although there is at least one case where it’s properly formatted. I’m not sure why yet.
I’ve been able to reproduce easily on a vanilla project (First Person Template) with the EGS version of UE 5.6, both editor and on a Win64 Dev package. I’m joining a trace, and you should be able to reproduce easily on your side.
As a side question, i was wondering if the macro RDG_GPU_STAT_SCOPE() is doing anything at all in 5.6 now that the new GPU profiler is active. In most GPU stat events in Unreal code, i see RDG_EVENT_SCOPE_STAT macros are followed by RDG_GPU_STAT_SCOPE macros, but when i look in its definition (RenderGraphEvent.h line 544) it doesn’t appear to do anything.
Thank you !
Titouan