Просмотр исходного кода

gl_shader_decompiler: Pass by reference to GenerateTextureArgument()

Avoids an unnecessary atomic reference count increment and decrement.
Lioncash 6 лет назад
Родитель
Сommit
b8a62adcf1
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      src/video_core/renderer_opengl/gl_shader_decompiler.cpp

+ 2 - 2
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 {};
         }