summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar Morph2020-05-31 03:12:21 -0400
committerGravatar Morph2020-05-31 03:21:07 -0400
commitbb8ef381526cd9cc0a52f00383c755913a20aa43 (patch)
treec213d64efd56fc2084d66e86e20691e7407e2869 /src
parentMerge pull request #3982 from ReinUsesLisp/membar-cts (diff)
downloadyuzu-bb8ef381526cd9cc0a52f00383c755913a20aa43.tar.gz
yuzu-bb8ef381526cd9cc0a52f00383c755913a20aa43.tar.xz
yuzu-bb8ef381526cd9cc0a52f00383c755913a20aa43.zip
gl_device: Enable compute shaders for Intel proprietary drivers
Previously we were disabling compute shaders on Intel's proprietary driver due to broken compute. This has been fixed in the latest Intel drivers. Re-enable compute for Intel proprietary drivers and remove the check for broken compute.
Diffstat (limited to 'src')
-rw-r--r--src/video_core/renderer_opengl/gl_device.cpp4
-rw-r--r--src/video_core/renderer_opengl/gl_device.h5
-rw-r--r--src/video_core/renderer_opengl/gl_rasterizer.cpp4
3 files changed, 0 insertions, 13 deletions
diff --git a/src/video_core/renderer_opengl/gl_device.cpp b/src/video_core/renderer_opengl/gl_device.cpp
index 466a911db..e1b245288 100644
--- a/src/video_core/renderer_opengl/gl_device.cpp
+++ b/src/video_core/renderer_opengl/gl_device.cpp
@@ -166,8 +166,6 @@ Device::Device() : base_bindings{BuildBaseBindings()} {
166 166
167 const bool is_nvidia = vendor == "NVIDIA Corporation"; 167 const bool is_nvidia = vendor == "NVIDIA Corporation";
168 const bool is_amd = vendor == "ATI Technologies Inc."; 168 const bool is_amd = vendor == "ATI Technologies Inc.";
169 const bool is_intel = vendor == "Intel";
170 const bool is_intel_proprietary = is_intel && std::strstr(renderer, "Mesa") == nullptr;
171 169
172 uniform_buffer_alignment = GetInteger<std::size_t>(GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT); 170 uniform_buffer_alignment = GetInteger<std::size_t>(GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT);
173 shader_storage_alignment = GetInteger<std::size_t>(GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT); 171 shader_storage_alignment = GetInteger<std::size_t>(GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT);
@@ -182,7 +180,6 @@ Device::Device() : base_bindings{BuildBaseBindings()} {
182 has_variable_aoffi = TestVariableAoffi(); 180 has_variable_aoffi = TestVariableAoffi();
183 has_component_indexing_bug = is_amd; 181 has_component_indexing_bug = is_amd;
184 has_precise_bug = TestPreciseBug(); 182 has_precise_bug = TestPreciseBug();
185 has_broken_compute = is_intel_proprietary;
186 has_fast_buffer_sub_data = is_nvidia; 183 has_fast_buffer_sub_data = is_nvidia;
187 use_assembly_shaders = Settings::values.use_assembly_shaders && GLAD_GL_NV_gpu_program5 && 184 use_assembly_shaders = Settings::values.use_assembly_shaders && GLAD_GL_NV_gpu_program5 &&
188 GLAD_GL_NV_compute_program5; 185 GLAD_GL_NV_compute_program5;
@@ -206,7 +203,6 @@ Device::Device(std::nullptr_t) {
206 has_image_load_formatted = true; 203 has_image_load_formatted = true;
207 has_variable_aoffi = true; 204 has_variable_aoffi = true;
208 has_component_indexing_bug = false; 205 has_component_indexing_bug = false;
209 has_broken_compute = false;
210 has_precise_bug = false; 206 has_precise_bug = false;
211} 207}
212 208
diff --git a/src/video_core/renderer_opengl/gl_device.h b/src/video_core/renderer_opengl/gl_device.h
index e915dbd86..683ed9002 100644
--- a/src/video_core/renderer_opengl/gl_device.h
+++ b/src/video_core/renderer_opengl/gl_device.h
@@ -80,10 +80,6 @@ public:
80 return has_precise_bug; 80 return has_precise_bug;
81 } 81 }
82 82
83 bool HasBrokenCompute() const {
84 return has_broken_compute;
85 }
86
87 bool HasFastBufferSubData() const { 83 bool HasFastBufferSubData() const {
88 return has_fast_buffer_sub_data; 84 return has_fast_buffer_sub_data;
89 } 85 }
@@ -109,7 +105,6 @@ private:
109 bool has_variable_aoffi{}; 105 bool has_variable_aoffi{};
110 bool has_component_indexing_bug{}; 106 bool has_component_indexing_bug{};
111 bool has_precise_bug{}; 107 bool has_precise_bug{};
112 bool has_broken_compute{};
113 bool has_fast_buffer_sub_data{}; 108 bool has_fast_buffer_sub_data{};
114 bool use_assembly_shaders{}; 109 bool use_assembly_shaders{};
115}; 110};
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp
index 716d43e65..61cf99b9d 100644
--- a/src/video_core/renderer_opengl/gl_rasterizer.cpp
+++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp
@@ -655,10 +655,6 @@ void RasterizerOpenGL::Draw(bool is_indexed, bool is_instanced) {
655} 655}
656 656
657void RasterizerOpenGL::DispatchCompute(GPUVAddr code_addr) { 657void RasterizerOpenGL::DispatchCompute(GPUVAddr code_addr) {
658 if (device.HasBrokenCompute()) {
659 return;
660 }
661
662 buffer_cache.Acquire(); 658 buffer_cache.Acquire();
663 current_cbuf = 0; 659 current_cbuf = 0;
664 660