From b8a62adcf1034535353b4a1486a51a5775d209b5 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 15 Oct 2019 18:29:35 -0400 Subject: gl_shader_decompiler: Pass by reference to GenerateTextureArgument() Avoids an unnecessary atomic reference count increment and decrement. --- src/video_core/renderer_opengl/gl_shader_decompiler.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp index 970cd0c76..82228b55d 100644 --- a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp +++ b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp @@ -1158,8 +1158,8 @@ private: return expr + ')'; } - std::string GenerateTextureArgument(TextureArgument argument) { - const auto [type, operand] = argument; + std::string GenerateTextureArgument(const TextureArgument& argument) { + const auto& [type, operand] = argument; if (operand == nullptr) { return {}; } -- cgit v1.2.3