summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_opengl/gl_shader_decompiler.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* shader: Remove old shader managementReinUsesLisp2021-07-231-69/+0
|
* video_core: Reimplement the buffer cacheReinUsesLisp2021-02-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Reimplement the buffer cache using cached bindings and page level granularity for modification tracking. This also drops the usage of shared pointers and virtual functions from the cache. - Bindings are cached, allowing to skip work when the game changes few bits between draws. - OpenGL Assembly shaders no longer copy when a region has been modified from the GPU to emulate constant buffers, instead GL_EXT_memory_object is used to alias sub-buffers within the same allocation. - OpenGL Assembly shaders stream constant buffer data using glProgramBufferParametersIuivNV, from NV_parameter_buffer_object. In theory this should save one hash table resolve inside the driver compared to glBufferSubData. - A new OpenGL stream buffer is implemented based on fences for drivers that are not Nvidia's proprietary, due to their low performance on partial glBufferSubData calls synchronized with 3D rendering (that some games use a lot). - Most optimizations are shared between APIs now, allowing Vulkan to cache more bindings than before, skipping unnecesarry work. This commit adds the necessary infrastructure to use Vulkan object from OpenGL. Overall, it improves performance and fixes some bugs present on the old cache. There are still some edge cases hit by some games that harm performance on some vendors, this are planned to be fixed in later commits.
* video_core: Rewrite the texture cacheReinUsesLisp2020-12-301-2/+2
| | | | | | | | | | | | | | The current texture cache has several points that hurt maintainability and performance. It's easy to break unrelated parts of the cache when doing minor changes. The cache can easily forget valuable information about the cached textures by CPU writes or simply by its normal usage.The current texture cache has several points that hurt maintainability and performance. It's easy to break unrelated parts of the cache when doing minor changes. The cache can easily forget valuable information about the cached textures by CPU writes or simply by its normal usage. This commit aims to address those issues.
* video_core: Resolve more variable shadowing scenarios pt.3Lioncash2020-12-051-2/+2
| | | | | Cleans out the rest of the occurrences of variable shadowing and makes any further occurrences of shadowing compiler errors.
* video_core: Resolve more variable shadowing scenariosLioncash2020-12-041-6/+6
| | | | | | Resolves variable shadowing scenarios up to the end of the OpenGL code to make it nicer to review. The rest will be resolved in a following commit.
* glsl: Squash constant buffers into a single SSBO when we hit the limitReinUsesLisp2020-06-011-2/+4
| | | | | Avoids compilation errors at the cost of shader build times and runtime performance when a game hits the limit of uniform buffers we can use.
* shader_ir: Turn classes into data structuresReinUsesLisp2020-04-231-25/+8
|
* gl_shader_decompiler: Add identifier to decompiled codeReinUsesLisp2020-03-091-1/+2
|
* shader/registry: Store graphics and compute metadataReinUsesLisp2020-03-091-4/+2
| | | | | Store information GLSL forces us to provide but it's dynamic state in hardware (workgroup sizes, primitive topology, shared memory size).
* gl_shader_cache: Rework shader cache and remove post-specializationsReinUsesLisp2020-03-091-9/+6
| | | | | Instead of pre-specializing shaders and then post-specializing them, drop the later and only "specialize" the shader while decoding it.
* gl_state_tracker: Implement dirty flags for clip distances and shadersReinUsesLisp2020-02-281-1/+1
|
* video_core: Unify ProgramType and ShaderStage into ShaderTypeReinUsesLisp2019-11-231-14/+3
|
* shader/node: Unpack bindless texture encodingReinUsesLisp2019-10-301-2/+1
| | | | | | | | | Bindless textures were using u64 to pack the buffer and offset from where they come from. Drop this in favor of separated entries in the struct. Remove the usage of std::set in favor of std::list (it's not std::vector to avoid reference invalidations) for samplers and images.
* gl_shader_decompiler: Move entries to a separate functionReinUsesLisp2019-10-251-5/+4
|
* shader/image: Implement SULD and remove irrelevant codeReinUsesLisp2019-09-211-1/+0
| | | | | * Implement SULD as float. * Remove conditional declaration of GL_ARB_shader_viewport_layer_array.
* gl_rasterizer: Implement compute shadersReinUsesLisp2019-07-151-5/+17
|
* gl_shader_decompiler: Implement gl_ViewportIndex and gl_Layer in vertex shadersReinUsesLisp2019-07-081-0/+1
| | | | | | | | | | | | | This commit implements gl_ViewportIndex and gl_Layer in vertex and geometry shaders. In the case it's used in a vertex shader, it requires ARB_shader_viewport_layer_array. This extension is available on AMD and Nvidia devices (mesa and proprietary drivers), but not available on Intel on any platform. At the moment of writing this description I don't know if this is a hardware limitation or a driver limitation. In the case that ARB_shader_viewport_layer_array is not available, writes to these registers on a vertex shader are ignored, with the appropriate logging.
* gl_shader_decompiler: Implement image binding settingsReinUsesLisp2019-06-211-0/+2
|
* Merge pull request #2383 from ReinUsesLisp/aoffi-testbunnei2019-04-231-2/+6
|\ | | | | gl_shader_decompiler: Disable variable AOFFI on unsupported devices
| * gl_shader_decompiler: Use variable AOFFI on supported hardwareReinUsesLisp2019-04-141-2/+6
| |
* | Merge pull request #2348 from FernandoS27/guest-bindlessbunnei2019-04-181-1/+2
|\ \ | | | | | | Implement Bindless Textures on Shader Decompiler and GL backend
| * | Unify both sampler types.Fernando Sahmkow2019-04-081-1/+2
| |/
* / shader_ir: Implement STG, keep track of global memory usage and flushReinUsesLisp2019-04-141-2/+13
|/
* video_core/renderer_opengl: Remove unnecessary includesLioncash2019-04-041-1/+0
| | | | | | | Quite a few unused includes have built up over time, particularly on core/memory.h. Removing these includes means the source files including those files will no longer need to be rebuilt if they're changed, making compilation slightly faster in this scenario.
* gl_shader_disk_cache: Address miscellaneous feedbackReinUsesLisp2019-02-071-4/+4
|
* gl_shader_disk_cache: Save GLSL and entries into the precompiled fileReinUsesLisp2019-02-071-60/+5
|
* gl_shader_decompiler: Remove name entriesReinUsesLisp2019-02-071-23/+7
|
* shader_decode: Implement LDG and basic cbuf trackingReinUsesLisp2019-02-071-0/+33
|
* gl_shader_cache: Use explicit bindingsReinUsesLisp2019-01-301-12/+0
|
* shader_decode: Implement LDG and basic cbuf trackingReinUsesLisp2019-01-301-0/+34
|
* video_core: Rename glsl_decompiler to gl_shader_decompilerReinUsesLisp2019-01-151-0/+88
|
* video_core: Replace gl_shader_decompilerReinUsesLisp2019-01-151-25/+0
|
* global: Use std::optional instead of boost::optional (#1578)Frederic L2018-10-301-4/+4
| | | | | | | | | | | | | | | | * get rid of boost::optional * Remove optional references * Use std::reference_wrapper for optional references * Fix clang format * Fix clang format part 2 * Adressed feedback * Fix clang format and MacOS build
* renderer_opengl: Namespace OpenGL codeLioncash2018-08-221-2/+2
| | | | | | | Namespaces all OpenGL code under the OpenGL namespace. Prevents polluting the global namespace and allows clear distinction between other renderers' code in the future.
* video_core: Use nested namespaces where applicableLioncash2018-07-211-4/+2
| | | | Compresses a few namespace specifiers to be more compact.
* gl_shader_gen: Implement dual vertex shader mode.bunnei2018-07-131-1/+2
| | | | - When VertexA shader stage is enabled, we combine with VertexB program to make a single Vertex Shader stage.
* renderer_opengl: Add missing header guardsLioncash2018-04-201-0/+2
|
* shaders: Expose hints about used const buffers.bunnei2018-04-151-2/+2
|
* gl_shader_decompiler: Add shader stage hint.bunnei2018-04-141-1/+5
|
* gl_shader_decompiler: Basic impl. for very simple vertex shaders.bunnei2018-04-141-8/+4
| | | | - Tested with Puyo Puyo Tetris and Cave Story+
* gl_shader_decompiler: Add skeleton code from Citra for shader analysis.bunnei2018-04-141-11/+8
|
* renderer_gl: Port over gl_shader_decompiler module from Citra.bunnei2018-03-201-0/+27