diff options
author | Samuel Pitoiset <[email protected]> | 2017-11-07 10:02:32 +0100 |
---|---|---|
committer | Samuel Pitoiset <[email protected]> | 2017-11-14 15:21:50 +0100 |
commit | 8a7d4092d260b3781a443171e20ba0d2c8772131 (patch) | |
tree | 8cdc6737571b7a34b8be86cc021e60a31f6d01be /src/amd/vulkan | |
parent | ecabe2280c4d3e59d6a6026dd0403d6dc60dc5da (diff) |
radv: force enable LLVM sisched for The Talos Principle
It seems safe and it improves performance by +4% (73->76).
A drirc based solution is not what we want for now, keep it
simple and improve later if it's really needed.
Signed-off-by: Samuel Pitoiset <[email protected]>
Reviewed-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/amd/vulkan')
-rw-r--r-- | src/amd/vulkan/radv_device.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/amd/vulkan/radv_device.c b/src/amd/vulkan/radv_device.c index 471cecdd6ab..50dbe061d50 100644 --- a/src/amd/vulkan/radv_device.c +++ b/src/amd/vulkan/radv_device.c @@ -341,6 +341,24 @@ radv_get_perftest_option_name(int id) return radv_perftest_options[id].string; } +static void +radv_handle_per_app_options(struct radv_instance *instance, + const VkApplicationInfo *info) +{ + const char *name = info ? info->pApplicationName : NULL; + + if (!name) + return; + + if (!strcmp(name, "Talos - Linux - 32bit") || + !strcmp(name, "Talos - Linux - 64bit")) { + /* Force enable LLVM sisched for Talos because it looks safe + * and it gives few more FPS. + */ + instance->perftest_flags |= RADV_PERFTEST_SISCHED; + } +} + VkResult radv_CreateInstance( const VkInstanceCreateInfo* pCreateInfo, const VkAllocationCallbacks* pAllocator, @@ -398,6 +416,8 @@ VkResult radv_CreateInstance( instance->perftest_flags = parse_debug_string(getenv("RADV_PERFTEST"), radv_perftest_options); + radv_handle_per_app_options(instance, pCreateInfo->pApplicationInfo); + if (instance->debug_flags & RADV_DEBUG_NO_SISCHED) { /* Disable sisched when the user requests it, this is mostly * useful when the driver force-enable sisched for the given |