From 2f39ae792a9522186e14f41618a4597fb43fb1ae Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Wed, 31 Aug 2022 21:11:53 +0200 Subject: [PATCH] [dxvk] Change DXVK_PERF_EVENTS environment variable to DXVK_DEBUG --- README.md | 2 +- dxvk.conf | 2 +- src/dxvk/dxvk_instance.cpp | 3 +-- src/dxvk/dxvk_options.h | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 12260af6..bddaff16 100644 --- a/README.md +++ b/README.md @@ -124,7 +124,7 @@ The following environment variables can be used for **debugging** purposes. - `DXVK_LOG_LEVEL=none|error|warn|info|debug` Controls message logging. - `DXVK_LOG_PATH=/some/directory` Changes path where log files are stored. Set to `none` to disable log file creation entirely, without disabling logging. - `DXVK_CONFIG_FILE=/xxx/dxvk.conf` Sets path to the configuration file. -- `DXVK_PERF_EVENTS=1` Enables use of the VK_EXT_debug_utils extension for translating performance event markers. +- `DXVK_DEBUG=markers|validation` Enables use of the `VK_EXT_debug_utils` extension for translating performance event markers, or to enable Vulkan validation, respecticely. ## Troubleshooting DXVK requires threading support from your mingw-w64 build environment. If you diff --git a/dxvk.conf b/dxvk.conf index 5c123f57..5f64091f 100644 --- a/dxvk.conf +++ b/dxvk.conf @@ -558,7 +558,7 @@ # Debug Utils # # Enables debug utils as this is off by default, this enables user annotations like BeginEvent()/EndEvent(). -# Alternatively could be enabled with DXVK_PERF_EVENTS=1 environment variable. +# Alternatively could be enabled with DXVK_DEBUG=markers environment variable. # # Supported values: # - True/False diff --git a/src/dxvk/dxvk_instance.cpp b/src/dxvk/dxvk_instance.cpp index 8010e740..0fc2e0b6 100644 --- a/src/dxvk/dxvk_instance.cpp +++ b/src/dxvk/dxvk_instance.cpp @@ -98,8 +98,7 @@ namespace dxvk { // Hide VK_EXT_debug_utils behind an environment variable. This extension // adds additional overhead to winevulkan - if ((env::getEnvVar("DXVK_PERF_EVENTS") == "1") || - (m_options.enableDebugUtils)) { + if ((!env::getEnvVar("DXVK_DEBUG").empty()) || (m_options.enableDebugUtils)) { insExtensionList.push_back(&insExtensions.extDebugUtils); Logger::warn("DXVK: Debug Utils are enabled, perf events are ON. May affect performance!"); } diff --git a/src/dxvk/dxvk_options.h b/src/dxvk/dxvk_options.h index da5bf406..015fea0c 100644 --- a/src/dxvk/dxvk_options.h +++ b/src/dxvk/dxvk_options.h @@ -8,7 +8,7 @@ namespace dxvk { DxvkOptions() { } DxvkOptions(const Config& config); - /// Enable debug utils (alternative to DXVK_PERF_EVENTS=1) + /// Enable debug utils bool enableDebugUtils; /// Enable state cache