r.DumpGPU.Explore
r.DumpGPU.Explore
#Overview
name: r.DumpGPU.Explore
This variable is created as a Console Variable (cvar).
- type:
Var
- help:
Whether to open file explorer to where the GPU dump on completion (enabled by default).
It is referenced in 3
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of r.DumpGPU.Explore is to control whether the file explorer should automatically open to display the location of the GPU dump upon completion. This setting is part of Unreal Engine’s GPU debugging and profiling system.
This setting variable is primarily used in the rendering subsystem of Unreal Engine, specifically in the RenderCore module. It’s referenced in the DumpGPU.cpp file, which suggests it’s related to GPU debugging and performance analysis features.
The value of this variable is set through a console variable (CVar) system. It’s initialized with a default value of 1 (enabled) when the GDumpExploreCVar is created.
The associated variable GDumpExploreCVar directly interacts with r.DumpGPU.Explore. They share the same value and purpose.
Developers should be aware that:
- This setting affects the behavior after a GPU dump is completed.
- When enabled (set to 1), it will automatically open the file explorer to show the location of the dump files.
- It’s enabled by default, which might not be desirable in all scenarios, especially in automated testing environments.
Best practices when using this variable include:
- Keep it enabled during development for easy access to GPU dump files.
- Consider disabling it (set to 0) in release builds or automated testing environments to prevent unexpected file explorer windows from opening.
- Use in conjunction with other GPU dumping settings for comprehensive debugging.
Regarding the associated variable GDumpExploreCVar:
- It’s the actual TAutoConsoleVariable object that controls the r.DumpGPU.Explore setting.
- It’s used in the BeginResourceDump function to determine whether to show the dump location in the file explorer.
- Developers can modify this variable at runtime using console commands, allowing for dynamic control over the GPU dump behavior.
- When working with this variable, ensure to use GetValueOnGameThread() to retrieve its current value, as demonstrated in the provided code snippet.
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Runtime/RenderCore/Private/DumpGPU.cpp:130
Scope (from outer to inner):
file
namespace anonymous
Source code excerpt:
static TAutoConsoleVariable<int32> GDumpExploreCVar(
TEXT("r.DumpGPU.Explore"), 1,
TEXT("Whether to open file explorer to where the GPU dump on completion (enabled by default)."),
ECVF_Default);
static TAutoConsoleVariable<int32> GDumpRenderingConsoleVariablesCVar(
TEXT("r.DumpGPU.ConsoleVariables"), 1,
TEXT("Whether to dump rendering console variables (enabled by default)."),
#Associated Variable and Callsites
This variable is associated with another variable named GDumpExploreCVar
. They share the same value. See the following C++ source code.
#Loc: <Workspace>/Engine/Source/Runtime/RenderCore/Private/DumpGPU.cpp:129
Scope (from outer to inner):
file
namespace anonymous
Source code excerpt:
ECVF_Default);
static TAutoConsoleVariable<int32> GDumpExploreCVar(
TEXT("r.DumpGPU.Explore"), 1,
TEXT("Whether to open file explorer to where the GPU dump on completion (enabled by default)."),
ECVF_Default);
static TAutoConsoleVariable<int32> GDumpRenderingConsoleVariablesCVar(
TEXT("r.DumpGPU.ConsoleVariables"), 1,
#Loc: <Workspace>/Engine/Source/Runtime/RenderCore/Private/DumpGPU.cpp:2114
Scope (from outer to inner):
file
function FString FRDGBuilder::BeginResourceDump
Source code excerpt:
}
NewResourceDumpContext->bShowInExplore = NewResourceDumpContext->bEnableDiskWrite && GDumpExploreCVar.GetValueOnGameThread() != 0 && !NewResourceDumpContext->bUpload;
check(GNextRDGResourceDumpContext == nullptr);
GNextRDGResourceDumpContext = NewResourceDumpContext;
if (GDumpGPUDelay.GetValueOnGameThread() > 0.0f)
{
GNextDumpingRemainingTime = GDumpGPUDelay.GetValueOnGameThread();