Re: [Mesa-dev] [PATCH] glsl: Fix overflow of ImageAccess[] array.

2016-02-13 Thread Jordan Justen
Reviewed-by: Jordan Justen And for IVB: Tested-by: Jordan Justen For me, this fixed the error message from arb_shader_image_load_store-max-images, subtest "Compute shader max image uniforms test": Before: Failed to link: error: Too many compute shader image uniforms (35002 > 32) After: F

Re: [Mesa-dev] [PATCH] glsl: Fix overflow of ImageAccess[] array.

2016-02-13 Thread Timothy Arceri
On Sat, 2016-02-13 at 17:27 -0800, Kenneth Graunke wrote: > The ImageAccess array is statically sized to MAX_IMAGE_UNIFORMS: > >    GLenum ImageAccess[MAX_IMAGE_UNIFORMS]; > > There was no bounds checking ensuring we don't overflow.  Passing in > a > shader with too many uniforms would cause writ

Re: [Mesa-dev] [PATCH] glsl: Fix overflow of ImageAccess[] array.

2016-02-13 Thread Kenneth Graunke
On Saturday, February 13, 2016 8:30:51 PM PST Ilia Mirkin wrote: > On Sat, Feb 13, 2016 at 8:27 PM, Kenneth Graunke wrote: > > The ImageAccess array is statically sized to MAX_IMAGE_UNIFORMS: > > > >GLenum ImageAccess[MAX_IMAGE_UNIFORMS]; > > > > There was no bounds checking ensuring we don't

Re: [Mesa-dev] [PATCH] glsl: Fix overflow of ImageAccess[] array.

2016-02-13 Thread Ilia Mirkin
On Sat, Feb 13, 2016 at 8:27 PM, Kenneth Graunke wrote: > The ImageAccess array is statically sized to MAX_IMAGE_UNIFORMS: > >GLenum ImageAccess[MAX_IMAGE_UNIFORMS]; > > There was no bounds checking ensuring we don't overflow. Passing in a > shader with too many uniforms would cause writes to

[Mesa-dev] [PATCH] glsl: Fix overflow of ImageAccess[] array.

2016-02-13 Thread Kenneth Graunke
The ImageAccess array is statically sized to MAX_IMAGE_UNIFORMS: GLenum ImageAccess[MAX_IMAGE_UNIFORMS]; There was no bounds checking ensuring we don't overflow. Passing in a shader with too many uniforms would cause writes to extend into other fields, such as sh->NumImages. Later linker che