diff options
author | Jason Ekstrand <[email protected]> | 2016-05-18 20:28:07 -0700 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2016-05-23 19:12:34 -0700 |
commit | 27b9481d03959a7bee6d906c62b4a519b6b1dc38 (patch) | |
tree | 4578aca510eef5c8e2e27a00f83d7791377e3dd4 /src/mesa/main | |
parent | ac242aac3d2c38fd6843d85363a455271b1348c2 (diff) |
glsl: Add an option to clamp block indices when lowering UBO/SSBOs
This prevents array overflow when the block is actually an array of UBOs or
SSBOs. On some hardware such as i965, such overflows can cause GPU hangs.
Reviewed-by: Ian Romanick <[email protected]>
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main')
-rw-r--r-- | src/mesa/main/mtypes.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index 6cd30e8c10c..b7b3ede57f1 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -2951,6 +2951,9 @@ struct gl_shader_compiler_options GLboolean LowerBufferInterfaceBlocks; /**< Lower UBO and SSBO access to intrinsics. */ + /** Clamp UBO and SSBO block indices so they don't go out-of-bounds. */ + GLboolean ClampBlockIndicesToArrayBounds; + GLboolean LowerShaderSharedVariables; /**< Lower compute shader shared * variable access to intrinsics. */ |