Re: [Mesa-dev] [PATCH 1/3] dri_interface: Introduce __DRI_IMAGE_USE_SCANOUT_ROTATION_* flags (v3)

2015-11-25 Thread Michel Dänzer
On 26.11.2015 11:01, Vivek Kasireddy wrote: > On Wed, 25 Nov 2015 18:38:50 +0900 > Michel Dänzer wrote: > >> On 21.11.2015 12:38, Vivek Kasireddy wrote: >>> These flags can be used by the DRI driver to set additional >>> requirements such as tiling while creating buffers. >>> >>> v2: Added a brie

Re: [Mesa-dev] [PATCH v2 08/42] i965/hsw: Enable L3 atomics.

2015-11-25 Thread Samuel Iglesias Gonsálvez
On 18/11/15 06:54, Jordan Justen wrote: > From: Francisco Jerez > > Improves performance of the arb_shader_image_load_store-atomicity > piglit test by over 25x (which isn't a real benchmark it's just heavy > on atomics -- the improvement in a microbenchmark I wrote a while ago > seemed to be ev

[Mesa-dev] [Bug 92945] [llvmpipe] [softpipe] piglit fs-ldexp-dvec4 regression

2015-11-25 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=92945 Vinson Lee changed: What|Removed |Added CC||bri...@vmware.com, |

[Mesa-dev] [PATCH 1/2] gallium/util: Fix util_blitter_clear_render_target() for num_layers>1

2015-11-25 Thread Edward O'Callaghan
Previously util_blitter_clear_render_target() could not clear more than the first layer. We need to generalise this so that ARB_clear_texture can pass the 3d piglit test. Signed-off-by: Edward O'Callaghan --- src/gallium/auxiliary/util/u_blitter.c | 15 --- 1 file changed, 12 inserti

[Mesa-dev] [PATCH 2/2] gallium/util: Fix util_blitter_clear_depth_stencil() for num_layers>1

2015-11-25 Thread Edward O'Callaghan
Previously util_blitter_clear_depth_stencil() could not clear more than the first layer. We need to generalise this as we did for util_blitter_clear_render_target(). Signed-off-by: Edward O'Callaghan --- src/gallium/auxiliary/util/u_blitter.c | 16 1 file changed, 12 insertions(

[Mesa-dev] Generalise util_blitter_clear_{render_target, depth_stencil}()

2015-11-25 Thread Edward O'Callaghan
The following patches generalise the blitter_clear functions such that they may work with multiple layers: Changes since v1: - Directly calc num_layers over using util_framebuffer_get_num_layers() on the framebuffer state. ___ mesa-dev mailing list me

Re: [Mesa-dev] [PATCH v2 8/8] mesa: rework the meaning of gl_debug_message::length

2015-11-25 Thread Timothy Arceri
On Thu, 2015-11-26 at 00:36 +, Emil Velikov wrote: > Currently it stores strlen(buf) whenever the user originally provided > a > negative value for length. > > Although I've not seen any explicit text in the spec, CTS requires > that > the very same length (be that negative value or not) is re

[Mesa-dev] [PATCH 10/10] vc4/nir: Use the new unified io intrinsics

2015-11-25 Thread Jason Ekstrand
Cc: Eric Anholt --- src/gallium/drivers/vc4/vc4_nir_lower_io.c | 20 src/gallium/drivers/vc4/vc4_program.c | 25 ++--- 2 files changed, 26 insertions(+), 19 deletions(-) diff --git a/src/gallium/drivers/vc4/vc4_nir_lower_io.c b/src/gallium/drivers/

[Mesa-dev] [PATCH 06/10] i965/fs: Get rid of load/store_foo_indirect

2015-11-25 Thread Jason Ekstrand
--- src/mesa/drivers/dri/i965/brw_fs.h | 3 +- src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 145 ++- src/mesa/drivers/dri/i965/brw_nir.c | 36 ++-- 3 files changed, 92 insertions(+), 92 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs.h b/src

[Mesa-dev] [PATCH 07/10] i965/vec4: Get rid of load/store_foo_indirect

2015-11-25 Thread Jason Ekstrand
--- src/mesa/drivers/dri/i965/brw_vec4_gs_nir.cpp | 8 +-- src/mesa/drivers/dri/i965/brw_vec4_nir.cpp| 98 ++- 2 files changed, 40 insertions(+), 66 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_vec4_gs_nir.cpp b/src/mesa/drivers/dri/i965/brw_vec4_gs_nir.cp

[Mesa-dev] [PATCH 09/10] ir3/nir: Use the new unified io intrinsics

2015-11-25 Thread Jason Ekstrand
Cc: Rob Clark --- .../drivers/freedreno/ir3/ir3_compiler_nir.c | 75 -- 1 file changed, 42 insertions(+), 33 deletions(-) diff --git a/src/gallium/drivers/freedreno/ir3/ir3_compiler_nir.c b/src/gallium/drivers/freedreno/ir3/ir3_compiler_nir.c index 156bb0b..eb0ed60 10

[Mesa-dev] [PATCH 08/10] tgsi_to_nir: Get rid of load/store_foo_indirect

2015-11-25 Thread Jason Ekstrand
Cc: Eric Anholt --- src/gallium/auxiliary/nir/tgsi_to_nir.c | 48 + 1 file changed, 25 insertions(+), 23 deletions(-) diff --git a/src/gallium/auxiliary/nir/tgsi_to_nir.c b/src/gallium/auxiliary/nir/tgsi_to_nir.c index 86c2ffa..642fbc2 100644 --- a/src/gallium/a

[Mesa-dev] [PATCH 05/10] nir/lower_io: Get rid of load/store_foo_indirect

2015-11-25 Thread Jason Ekstrand
--- src/glsl/nir/nir.h | 2 +- src/glsl/nir/nir_lower_io.c | 105 ++-- 2 files changed, 43 insertions(+), 64 deletions(-) diff --git a/src/glsl/nir/nir.h b/src/glsl/nir/nir.h index 524717a..1bf2c3f 100644 --- a/src/glsl/nir/nir.h +++ b/src/glsl/n

[Mesa-dev] [PATCH 05/10] nir/lower_io: Get rid of load/store_foo_indirect

2015-11-25 Thread Jason Ekstrand
--- src/glsl/nir/nir.h | 2 +- src/glsl/nir/nir_lower_io.c | 105 ++-- 2 files changed, 43 insertions(+), 64 deletions(-) diff --git a/src/glsl/nir/nir.h b/src/glsl/nir/nir.h index 524717a..1bf2c3f 100644 --- a/src/glsl/nir/nir.h +++ b/src/glsl/n

[Mesa-dev] [PATCH 03/10] nir: Get rid of *_indirect variants of input/output load/store intrinsics

2015-11-25 Thread Jason Ekstrand
There is some special-casing needed in a competent back-end. However, they can do their special-casing easily enough based on whether or not the offset is a constant. In the mean time, having the *_indirect variants adds special cases a number of places where they don't need to be and, in general

[Mesa-dev] [PATCH 04/10] nir/glsl: Stop handling UBO/SSBO load/stores differently depending on indirect

2015-11-25 Thread Jason Ekstrand
--- src/glsl/nir/glsl_to_nir.cpp | 47 +++- 1 file changed, 7 insertions(+), 40 deletions(-) diff --git a/src/glsl/nir/glsl_to_nir.cpp b/src/glsl/nir/glsl_to_nir.cpp index 45d045c..ba23b91 100644 --- a/src/glsl/nir/glsl_to_nir.cpp +++ b/src/glsl/nir/glsl_to

[Mesa-dev] [PATCH 01/10] nir/lower_io: Pass the builder and type_size into get_io_offset

2015-11-25 Thread Jason Ekstrand
--- src/glsl/nir/nir_lower_io.c | 30 +++--- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/glsl/nir/nir_lower_io.c b/src/glsl/nir/nir_lower_io.c index 5683e69..f64ac69 100644 --- a/src/glsl/nir/nir_lower_io.c +++ b/src/glsl/nir/nir_lower_io.c @@ -87,17

[Mesa-dev] [PATCH 02/10] i965/vec4: Get rid of the nir_inputs array

2015-11-25 Thread Jason Ekstrand
It's not really buying us anything at this point. It's just a way of remapping one offset namespace onto another. We can just use the location namespace the whole way through. --- src/mesa/drivers/dri/i965/brw_nir.c| 28 src/mesa/drivers/dri/i965/brw_vec4.h

[Mesa-dev] [PATCH 00/10] nir: Get rid of the *_indirect load/store intrinsics

2015-11-25 Thread Jason Ekstrand
This has been bothering me for quite some time. We have both regular and *_indirect forms of all of the load/store intrinsics. Unfortunately, these lead to large number of unneeded special-cases. Another downside is that core NIR has no way of turning _indirect load/store operations into their d

Re: [Mesa-dev] [PATCH v2 6/8] mesa: accept TYPE_PUSH/POP_GROUP with glDebugMessageInsert

2015-11-25 Thread Timothy Arceri
On Thu, 2015-11-26 at 00:36 +, Emil Velikov wrote: > These new (relative to ARB_debug_output) tokens, have been explicitly > separated from the existing ones in the spec text. With the reference > to glDebugMessageInsert was dropped. > > At the same time, further down the spec says: >"The

Re: [Mesa-dev] [PATCH v2 4/8] mesa: return the correct value for GroupStackDepth

2015-11-25 Thread Timothy Arceri
On Thu, 2015-11-26 at 00:36 +, Emil Velikov wrote: > We already have one group (the default) as specif iced in the spec. With the commit message fix. Reviewed-by: Timothy Arceri > So > lets return its size, rather than the index of the current group. > > Signed-off-by: Emil Velikov > ---

Re: [Mesa-dev] [PATCH v2 3/8] mesa: rename GroupStackDepth to CurrentGroup

2015-11-25 Thread Timothy Arceri
Reviewed-by: Timothy Arceri ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH v2 1/8] glapi: add GetPointervKHR to the ES dispatch

2015-11-25 Thread Timothy Arceri
On Thu, 2015-11-26 at 00:36 +, Emil Velikov wrote: > The KHR_debug extension implements this. > > Strictly speaking it could be used with ES 1.0, although as the > original > function is available on ES 1.1, I'm inclined to lift the KHR_debug > requirement to ES 1.1. > > Bugzilla: https://bug

[Mesa-dev] [PATCH] nv50/ir: fix moves to/from flags

2015-11-25 Thread Ilia Mirkin
Noticed this when looking at a trace that caused flags to spill to/from registers. The flags source/destination wasn't encoded correctly according to both envydis and nvdisasm. Signed-off-by: Ilia Mirkin --- Untested. Will try a few things before pushing this... hopefully it fixes some stubborn

Re: [Mesa-dev] [PATCH v2 2/8] mesa: do not enable KHR_debug for ES 1.0

2015-11-25 Thread Timothy Arceri
On Thu, 2015-11-26 at 00:36 +, Emil Velikov wrote: > The extension requires (cough implements) GetPointervKHR (alias of > GetPointerv) which in itself is available for ES 1.1 enabled mesa. > > Anyone willing to fish around and implement it for ES 1.0 is more > than > welcome to revert this com

Re: [Mesa-dev] [PATCH 12/12] mesa: Drop the blacklisting of new GL enums.

2015-11-25 Thread Ilia Mirkin
On Wed, Nov 25, 2015 at 10:10 PM, Eric Anholt wrote: > index bff425a..4c89849 100644 > --- a/src/mesa/main/tests/enum_strings.cpp > +++ b/src/mesa/main/tests/enum_strings.cpp > @@ -71,7 +71,7 @@ const struct enum_info everything[] = { > * see go farther. Disabled for the moment since Mesa do

[Mesa-dev] [PATCH 07/12] mesa: Remove the python mode bits from gl_enums.py.

2015-11-25 Thread Eric Anholt
emacs whines at me every time I open the file about these unsafe variables, and the file was reformatted from 8 space to 4 space long ago. --- src/mapi/glapi/gen/gl_enums.py | 1 - 1 file changed, 1 deletion(-) diff --git a/src/mapi/glapi/gen/gl_enums.py b/src/mapi/glapi/gen/gl_enums.py index 041

[Mesa-dev] [PATCH 06/12] mesa: Drop apparently typoed GL_ALL_CLIENT_ATTRIB_BITS.

2015-11-25 Thread Eric Anholt
GL_ALL_ATTRIB_BITS is a thing, and GL_CLIENT_ALL_ATTRIB_BITS, but I don't see GL_ALL_CLIENT_ATTRIB_BITS in my grepping of khronos XML, GL extension specs, GL 1.1, GL 2.2, and GL 4.4. --- src/mapi/glapi/gen/gl_API.xml| 1 - src/mesa/main/tests/enum_strings.cpp | 4 +--- 2 files changed, 1 i

[Mesa-dev] [PATCH 02/12] mesa: Add a copy of the Khronos gl.xml (SVN #31705).

2015-11-25 Thread Eric Anholt
The intention here is to keep a pristine copy of the upstream gl.xml that can be updated at any time with a new version, and use that to generate Mesa code from instead of our private XML. --- Contents trimmed, because it's 2.5MB. You can find the whole branch at: https://github.com/anholt/mesa/

[Mesa-dev] [PATCH 10/12] mesa: Prefer newer names to older ones among names present in core.

2015-11-25 Thread Eric Anholt
Sometimes GL likes to rename an old enum when it grows a more general purpose, and we should prefer the new name. Changes from this: GL_POINT/LINE_SIZE_* (1.1) -> GL_SMOOTH_POINT/LINE_SIZE_* (1.2) GL_FOG_COORDINATE_* (1.4) -> GL_FOG_COORD_* (1.5) GL_SOURCE[012]_RGB/ALPHA (1.3) -> GL_SRC0_RGB (1.5

[Mesa-dev] [PATCH 12/12] mesa: Drop the blacklisting of new GL enums.

2015-11-25 Thread Eric Anholt
Now when people need new extensions, they can skip the entire enum-definition process, and we can stop reviewing new extension XML for its enum content. This also brings in a new enum that I wanted to use in enum_strings.cpp for testing the code generator. --- src/mapi/glapi/gen/gl_enums.py

[Mesa-dev] [PATCH 01/12] mesa: Cut enum_strings.cpp test down to a few hand-chosen enums.

2015-11-25 Thread Eric Anholt
The previous contents appeared to be the output of some form of code generation for all enums, with a few entries hand-edited to deal with oddness. The downside to this was that when an enum gets promoted from vendor to _EXT or _EXT to _ARB or _ARB to core, make check starts failing even when the

[Mesa-dev] [PATCH 09/12] mesa: Drop bitfield "enums" from the enum-to-string table.

2015-11-25 Thread Eric Anholt
Asking the table for bitfield names doesn't make any sense. For 0x10, do you want GL_GLYPH_HORIZONTAL_BEARING_ADVANCE_BIT_NV or GL_COLOR_BUFFER_BIT4_QCOM or GL_POLYGON_STIPPLE_BIT or GL_SHADER_GLOBAL_ACCESS_BARRIER_BIT_NV? Giving a useful answer would depend on a whole lot of context. This also

[Mesa-dev] [PATCH 08/12] mesa: Switch to using the Khronos registry for generating enums.

2015-11-25 Thread Eric Anholt
I've used a bunch of python code to cut out new enums so that the two generated files can be diffed. I'll remove all that hardcoding in the following commits. All remaining differences between the generated code: - GL_TEXTURE_BUFFER_FORMAT didn't appear in GL3 when TBOs got merged to core, so

[Mesa-dev] [PATCH 11/12] mesa: Use a 32-bit offset for the enums.c string offset table.

2015-11-25 Thread Eric Anholt
With GLES 3.1, GL 4.5, and many new vendor extensions about to get their enums added, we jump up to 85k of table. --- src/mapi/glapi/gen/gl_enums.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/mapi/glapi/gen/gl_enums.py b/src/mapi/glapi/gen/gl_enums.py index d37eb5c.

[Mesa-dev] [PATCH 05/12] mesa: Drop enums that had been removed in later revs of specs.

2015-11-25 Thread Eric Anholt
Mesa hasn't been using these enums and the finalized specs don't reference them, so losing them from our generated enum-to-string code should be fine. Reduces diffs to generating from Khronos XML, which has these enums noted defined but commented out from any consumers. --- src/mapi/glapi/gen/ARB

[Mesa-dev] [PATCH 04/12] mesa: Fix a typo in AMD_performance_monitor enum.

2015-11-25 Thread Eric Anholt
--- src/mapi/glapi/gen/AMD_performance_monitor.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mapi/glapi/gen/AMD_performance_monitor.xml b/src/mapi/glapi/gen/AMD_performance_monitor.xml index 41b5208..b29dc5d 100644 --- a/src/mapi/glapi/gen/AMD_performance_monitor.xml

[Mesa-dev] [PATCH 03/12] mesa: Fix enum definition of CULL_VERTEX_EYE/OBJECT_POSITION

2015-11-25 Thread Eric Anholt
In converting to using the Khronos XML, I found that our XML had these two swapped, and the text spec agreed. --- src/mapi/glapi/gen/gl_API.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mapi/glapi/gen/gl_API.xml b/src/mapi/glapi/gen/gl_API.xml index ec83cd4..faf92

Re: [Mesa-dev] [RFC 3/5] i965/fs: Plumb separate surfaces and samplers through from NIR

2015-11-25 Thread Jason Ekstrand
On Wed, Nov 25, 2015 at 4:13 PM, Kenneth Graunke wrote: > On Tuesday, November 03, 2015 01:26:02 PM Jason Ekstrand wrote: >> --- >> src/mesa/drivers/dri/i965/brw_blorp_blit_eu.cpp | 2 +- >> src/mesa/drivers/dri/i965/brw_fs.cpp| 47 >> +++-- >> src/mesa/drivers/d

Re: [Mesa-dev] [RFC 1/5] nir: Separate texture from sampler in nir_tex_instr

2015-11-25 Thread Jason Ekstrand
On Wed, Nov 25, 2015 at 3:57 PM, Kenneth Graunke wrote: > On Tuesday, November 03, 2015 01:26:00 PM Jason Ekstrand wrote: >> This commit adds the capability to NIR to support separate textures and >> samplers. As it currently stands, glsl_to_nir only sets the sampler and >> leaves the texture alo

[Mesa-dev] [PATCH] i965: Don't mark dead instructions' sources live.

2015-11-25 Thread Matt Turner
Removes dead code from glsl-mat-from-int-ctor-03.shader_test. Reported-by: Juan A. Suarez Romero --- src/mesa/drivers/dri/i965/brw_fs_dead_code_eliminate.cpp | 4 src/mesa/drivers/dri/i965/brw_vec4_dead_code_eliminate.cpp | 4 2 files changed, 8 insertions(+) diff --git a/src/mesa/d

Re: [Mesa-dev] [PATCH 1/3] dri_interface: Introduce __DRI_IMAGE_USE_SCANOUT_ROTATION_* flags (v3)

2015-11-25 Thread Vivek Kasireddy
On Wed, 25 Nov 2015 18:38:50 +0900 Michel Dänzer wrote: > On 21.11.2015 12:38, Vivek Kasireddy wrote: > > These flags can be used by the DRI driver to set additional > > requirements such as tiling while creating buffers. > > > > v2: Added a brief comment to explain the rotation orientation. > >

[Mesa-dev] [Bug 93103] llvm symbols leak through, cause trouble with software rendering in llvm-linked software

2015-11-25 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=93103 --- Comment #4 from Michel Dänzer --- Also note that as of version 3.6, LLVM uses versioned symbols, which may help for this issue. -- You are receiving this mail because: You are the QA Contact for the bug. You are the assignee for the bug. __

Re: [Mesa-dev] [PATCH v2 4/8] mesa: return the correct value for GroupStackDepth

2015-11-25 Thread Emil Velikov
On 26 November 2015 at 00:57, Ilia Mirkin wrote: > On Wed, Nov 25, 2015 at 7:36 PM, Emil Velikov > wrote: >> We already have one group (the default) as specif iced in the spec. So > > what's a "specif iced"? is that like iced tea? > The very same :-P More of pressed the wrong button (suggestion)

Re: [Mesa-dev] [RFC 5/5] i965/vec4: Plumb separate surfaces and samplers through from NIR

2015-11-25 Thread Jason Ekstrand
On Nov 25, 2015 4:18 PM, "Kenneth Graunke" wrote: > > On Tuesday, November 03, 2015 01:26:04 PM Jason Ekstrand wrote: > > --- > > src/mesa/drivers/dri/i965/brw_vec4.h | 4 +++- > > src/mesa/drivers/dri/i965/brw_vec4_nir.cpp | 27 ++ > > src/mesa/drivers/dri/

Re: [Mesa-dev] [PATCH v2 4/8] mesa: return the correct value for GroupStackDepth

2015-11-25 Thread Ilia Mirkin
On Wed, Nov 25, 2015 at 7:36 PM, Emil Velikov wrote: > We already have one group (the default) as specif iced in the spec. So what's a "specif iced"? is that like iced tea? > lets return its size, rather than the index of the current group. > > Signed-off-by: Emil Velikov > --- > src/mesa/main

[Mesa-dev] [PATCH v2 8/8] mesa: rework the meaning of gl_debug_message::length

2015-11-25 Thread Emil Velikov
Currently it stores strlen(buf) whenever the user originally provided a negative value for length. Although I've not seen any explicit text in the spec, CTS requires that the very same length (be that negative value or not) is returned back on Pop. So let's push down the length < 0 checks, tweak

[Mesa-dev] [PATCH v2 2/8] mesa: do not enable KHR_debug for ES 1.0

2015-11-25 Thread Emil Velikov
The extension requires (cough implements) GetPointervKHR (alias of GetPointerv) which in itself is available for ES 1.1 enabled mesa. Anyone willing to fish around and implement it for ES 1.0 is more than welcome to revert this commit. Until then lets restrict things. Bugzilla: https://bugs.freed

[Mesa-dev] [PATCH v2 6/8] mesa: accept TYPE_PUSH/POP_GROUP with glDebugMessageInsert

2015-11-25 Thread Emil Velikov
These new (relative to ARB_debug_output) tokens, have been explicitly separated from the existing ones in the spec text. With the reference to glDebugMessageInsert was dropped. At the same time, further down the spec says: "The value of must be one of the values from Table 5.4" ... and these

[Mesa-dev] [PATCH v2 7/8] mesa: errors: validate the length of null terminated string

2015-11-25 Thread Emil Velikov
We're about to rework the meaning of gl_debug_message::length to store the user provided data. Thus we should add an explicit validation for null terminated strings. Signed-off-by: Emil Velikov --- src/mesa/main/errors.c | 20 +--- 1 file changed, 17 insertions(+), 3 deletions(-)

[Mesa-dev] [PATCH v2 1/8] glapi: add GetPointervKHR to the ES dispatch

2015-11-25 Thread Emil Velikov
The KHR_debug extension implements this. Strictly speaking it could be used with ES 1.0, although as the original function is available on ES 1.1, I'm inclined to lift the KHR_debug requirement to ES 1.1. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93048 Signed-off-by: Emil Velikov --

[Mesa-dev] [PATCH v2 5/8] mesa: add SEVERITY_NOTIFICATION to default state

2015-11-25 Thread Emil Velikov
As per the spec quote: "All messages are initially enabled unless their assigned severity is DEBUG_SEVERITY_LOW" We already had MEDIUM and HIGH set, let's toggle NOTIFICATION as well. Signed-off-by: Emil Velikov Reviewed-by: Timothy Arceri --- src/mesa/main/errors.c | 5 +++-- 1 file

[Mesa-dev] [PATCH v2 3/8] mesa: rename GroupStackDepth to CurrentGroup

2015-11-25 Thread Emil Velikov
The variable is used as the actual index, rather than the size of the group stack - rename it to reflect that. Suggested-by: Ilia Mirkin Signed-off-by: Emil Velikov --- src/mesa/main/errors.c | 32 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/

[Mesa-dev] [PATCH v2 4/8] mesa: return the correct value for GroupStackDepth

2015-11-25 Thread Emil Velikov
We already have one group (the default) as specif iced in the spec. So lets return its size, rather than the index of the current group. Signed-off-by: Emil Velikov --- src/mesa/main/errors.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/main/errors.c b/src/mesa/ma

[Mesa-dev] [PATCH v2 0/8] GL_KHR_debug fixes

2015-11-25 Thread Emil Velikov
Hi all, A bit of an update from last time around: - Renamed GroupStackDepth to CurrentGroup, as Ilia suggested - No more hacks - Validate the length on null terminated strings - Return the correct total length in GetDebugMessageLog With these in place CTS test now passes. A full spin is ongoi

Re: [Mesa-dev] [RFC 0/5] nir: Separate Textures and Samplers

2015-11-25 Thread Kenneth Graunke
On Tuesday, November 03, 2015 01:25:59 PM Jason Ekstrand wrote: > Separate textures and samplers are something that a lot of hardware > supports. Our hardware in particular has done this ever since the original > i965 chips. Part of this is because DX has made it a requirement for some > time now

Re: [Mesa-dev] [RFC 5/5] i965/vec4: Plumb separate surfaces and samplers through from NIR

2015-11-25 Thread Kenneth Graunke
On Tuesday, November 03, 2015 01:26:04 PM Jason Ekstrand wrote: > --- > src/mesa/drivers/dri/i965/brw_vec4.h | 4 +++- > src/mesa/drivers/dri/i965/brw_vec4_nir.cpp | 27 > ++ > src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp | 12 > 3 files chang

Re: [Mesa-dev] [PATCH 2/2] i965: run brw_vec4 optimizations in loop

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 5:36 AM, Juan A. Suarez Romero wrote: > When analyzing output for glsl-mat-from-int-ctor-03 piglit test, found > that the following piece of generated asm code: > > mov(8) g19<1>.xyzF g6<4,4,1>.xyzzD { align16 1Q > }; > dp4(8) g115<1>.

Re: [Mesa-dev] [PATCH 0/2] Run post opt_vector_float() opts in a loop

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 5:36 AM, Juan A. Suarez Romero wrote: > > When checking output VS in glsl-mat-from-int-ctor-03 piglit, I got the > following > (part of) code. > > mov(8) g19<1>.xyzF g6<4,4,1>.xyzzD { align16 > 1Q }; > dp4(8) g115<1>.wF g

Re: [Mesa-dev] [RFC 3/5] i965/fs: Plumb separate surfaces and samplers through from NIR

2015-11-25 Thread Kenneth Graunke
On Tuesday, November 03, 2015 01:26:02 PM Jason Ekstrand wrote: > --- > src/mesa/drivers/dri/i965/brw_blorp_blit_eu.cpp | 2 +- > src/mesa/drivers/dri/i965/brw_fs.cpp| 47 > +++-- > src/mesa/drivers/dri/i965/brw_fs.h | 4 ++- > src/mesa/drivers/dri/i

Re: [Mesa-dev] [PATCH 1/2] i965: Do not apply CSE opt to MOV immediate

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 5:36 AM, Juan A. Suarez Romero wrote: > If the shader asm code is something like: > > mov vgrf2767.0:F, [13F, 14F, 15F, 16F] > mov vgrf2768.0:F, [9F, 10F, 11F, 12F] > mov m8:F, [13F, 14F, 15F, 16F] > mov m7:F, [9F, 10F, 11F, 12F] > > And we apply Common Subexpresion Elimina

Re: [Mesa-dev] [Mesa-stable] [PATCH] swrast: Fix the coordinates passed to _mesa_regions_overlap()

2015-11-25 Thread Anuj Phogat
On Wed, Nov 25, 2015 at 10:44 AM, Matt Turner wrote: > On Wed, Nov 25, 2015 at 10:22 AM, Ian Romanick wrote: >> Is this related to a bugzilla or a failing test case? If not, could we >> get it piglit for it? >> >> Either way, looking at _mesa_regions_overlap (which could use a comment >> saying

Re: [Mesa-dev] [RFC 1/5] nir: Separate texture from sampler in nir_tex_instr

2015-11-25 Thread Kenneth Graunke
On Tuesday, November 03, 2015 01:26:00 PM Jason Ekstrand wrote: > This commit adds the capability to NIR to support separate textures and > samplers. As it currently stands, glsl_to_nir only sets the sampler and > leaves the texture alone as it did before and nir_lower_samplers assumes > this. Ho

Re: [Mesa-dev] [PATCH 23/24] i965/vec4: Replace src_reg(imm) constructors with brw_imm_*().

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 2:48 PM, Matt Turner wrote: > The code seems fine to me. Here's what I see: > > We start with remaining_channels = WRITEMASK_XYZW. We initialize an > element of imm[] for each enabled bit of inst->dst.writemask, and then > we disable those bits from remaining_channels. When

Re: [Mesa-dev] [PATCH 23/24] i965/vec4: Replace src_reg(imm) constructors with brw_imm_*().

2015-11-25 Thread Matt Turner
On Tue, Nov 3, 2015 at 10:58 AM, Emil Velikov wrote: > On 3 November 2015 at 18:20, Matt Turner wrote: >> On Tue, Nov 3, 2015 at 8:09 AM, Emil Velikov >> wrote: >>> On 3 November 2015 at 00:29, Matt Turner wrote: >>> @@ -387,7 +342,9 @@ vec4_visitor::opt_vector_float() re

Re: [Mesa-dev] [PATCH 4/9] compiler: introduce a libcompiler static library

2015-11-25 Thread Emil Velikov
On 25 November 2015 at 21:54, Matt Turner wrote: > On Wed, Nov 25, 2015 at 1:31 PM, Emil Velikov > wrote: >> From: Emil Velikov >> >> Currently it's an empty library, although it'll be used to store common >> code between GLSL and NIR that is compiler specific (rather than generic >> as the one

Re: [Mesa-dev] [PATCH v2 22/42] glsl: Don't lower_variable_index_to_cond_assign for shared variables

2015-11-25 Thread Jordan Justen
On 2015-11-25 00:12:15, Iago Toral wrote: > On Tue, 2015-11-17 at 21:54 -0800, Jordan Justen wrote: > > Signed-off-by: Jordan Justen > > --- > > src/glsl/lower_variable_index_to_cond_assign.cpp | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/src/glsl/lower_variable_index_to_con

Re: [Mesa-dev] [PATCH 8/9] nir: move to compiler

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 1:32 PM, Emil Velikov wrote: > From: Emil Velikov > > Signed-off-by: Emil Velikov > --- > Android.mk | 1 + > configure.ac | 1 + > src/Makefile.am| 1

Re: [Mesa-dev] [PATCH 4/9] compiler: introduce a libcompiler static library

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 1:31 PM, Emil Velikov wrote: > From: Emil Velikov > > Currently it's an empty library, although it'll be used to store common > code between GLSL and NIR that is compiler specific (rather than generic > as the one in src/util). > > XXX: strictly speaking we could add a pyt

Re: [Mesa-dev] [PATCH 2/9] nir: remove recursive inclusion in builtin_type_macros.h

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 1:31 PM, Emil Velikov wrote: > From: Emil Velikov > > The header is already included by glsl_types.{cpp,h}. > > Signed-off-by: Emil Velikov > --- > src/glsl/nir/builtin_type_macros.h | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/src/glsl/nir/builtin_type_macr

[Mesa-dev] [PATCH 6/9] nir: move glsl_types.{cpp,h} to compiler

2015-11-25 Thread Emil Velikov
From: Emil Velikov Allows us to remove the SCons workaround :-) Signed-off-by: Emil Velikov --- src/compiler/Makefile.sources | 2 ++ src/{glsl/nir => compiler}/glsl_types.cpp | 2 +- src/{glsl/nir => compiler}/glsl_types.h |

[Mesa-dev] [PATCH 0/9] Move nir/glsl to src/compiler

2015-11-25 Thread Emil Velikov
Hello all, Some of us have been thinking about moving nir out of glsl, and fleshing out some common helper (static library) that is use by both. So here it is - src/compiler. The modules (libcompiler, libnir and libglsl) are unfortunately not really independent. - libcompiler - compile time (

[Mesa-dev] [PATCH 8/9] nir: move to compiler

2015-11-25 Thread Emil Velikov
From: Emil Velikov Signed-off-by: Emil Velikov --- Android.mk | 1 + configure.ac | 1 + src/Makefile.am| 1 + src/{glsl => compiler}/nir/.gitignore | 0 src/co

[Mesa-dev] [PATCH 4/9] compiler: introduce a libcompiler static library

2015-11-25 Thread Emil Velikov
From: Emil Velikov Currently it's an empty library, although it'll be used to store common code between GLSL and NIR that is compiler specific (rather than generic as the one in src/util). XXX: strictly speaking we could add a python/mako parser to generate the relevant files instead including b

[Mesa-dev] [PATCH 2/9] nir: remove recursive inclusion in builtin_type_macros.h

2015-11-25 Thread Emil Velikov
From: Emil Velikov The header is already included by glsl_types.{cpp,h}. Signed-off-by: Emil Velikov --- src/glsl/nir/builtin_type_macros.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/glsl/nir/builtin_type_macros.h b/src/glsl/nir/builtin_type_macros.h index 8e16ae4..7bd2e4e 10064

[Mesa-dev] [PATCH 5/9] nir: move shader_enums.[ch] to compiler

2015-11-25 Thread Emil Velikov
From: Emil Velikov This way one can reuse it in glsl, nir or other compiler infrastructure without pulling nir as dependency. Signed-off-by: Emil Velikov --- Android.mk | 1 + src/SConscript | 1 + src/compiler/Android.mk

[Mesa-dev] [PATCH 1/9] nir: remove unneeded include

2015-11-25 Thread Emil Velikov
From: Emil Velikov Signed-off-by: Emil Velikov --- src/glsl/nir/nir_lower_samplers.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/glsl/nir/nir_lower_samplers.c b/src/glsl/nir/nir_lower_samplers.c index 5df79a6..2aab305 100644 --- a/src/glsl/nir/nir_lower_samplers.c +++ b/src/glsl/nir

[Mesa-dev] [PATCH 7/9] compiler: move the glsl_types C wrapper

2015-11-25 Thread Emil Velikov
From: Emil Velikov ... alongside its C++ brethren. On the flip side the files are called nir_types.{cpp,h} just because... At some point in the future we can fold the wrappers where they should be and rename things appropriately. Yet current direction is to try and split it out of nir. Signed-o

[Mesa-dev] [PATCH 3/9] drivers/x11: scons: partially revert b9b40ef9b76

2015-11-25 Thread Emil Velikov
From: Emil Velikov As glsl_types.{cpp,h} were moved out of the sconscript (commit b23a4859f4d "scons: Build nir/glsl_types.cpp once.") remove the dangling includes. Cc: Jose Fonseca Signed-off-by: Emil Velikov --- src/mesa/drivers/x11/SConscript | 2 -- 1 file changed, 2 deletions(-) diff -

Re: [Mesa-dev] [PATCH v2 5.5/42] i965: Add slice count to the brw_device_info structure.

2015-11-25 Thread Ben Widawsky
The most important feedback I have on the patch is that we continue to add stuff like this for compute when there is a libdrm interface which exposes all or most of it - and that interface should either be expanded or removed. FWIW, I wasn't a big fan of the interface when it was introduced, but it

[Mesa-dev] [PATCH v2 10/11] gallium: do not wrap header inclusion in

2015-11-25 Thread Emil Velikov
From: Emil Velikov Add one missing extern C guard within include/pipe/p_video_enums.h, and remove the wrapping throughout gallium. On Haiku one could even use the gallium debug_printf() although that's another topic. v2: Leave dbghelp.h as is (Jose) Cc: Jose Fonseca Cc: Brian Paul Cc: Alexan

Re: [Mesa-dev] [PATCH 07/11] i965: do not wrap header inclusion in extern "C"

2015-11-25 Thread Emil Velikov
On 24 November 2015 at 16:29, Emil Velikov wrote: > From: Emil Velikov > > Signed-off-by: Emil Velikov > --- > src/mesa/drivers/dri/i965/brw_vec4.h | 17 + > 1 file changed, 5 insertions(+), 12 deletions(-) > > diff --git a/src/mesa/drivers/dri/i965/brw_vec4.h > b/src/mesa/driv

Re: [Mesa-dev] [PATCH 3/3] i965/gen9+: Switch thread scratch space to non-coherent stateless access.

2015-11-25 Thread Kristian Høgsberg
On Wed, Nov 25, 2015 at 11:37 AM, Francisco Jerez wrote: > The thread scratch space is thread-local so using the full IA-coherent > stateless surface index (255 since Gen8) is unnecessary and > potentially expensive. On Gen8 and early steppings of Gen9 this is > not a functional change because th

Re: [Mesa-dev] [PATCH] mesa/program: remove empty function declaration

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 12:17 PM, Emil Velikov wrote: > From: Emil Velikov > > Unused since > > 5e9aa9926b9 (2011) - _mesa_ir_compile_shader > 69e07bdeb42 (2009) - _mesa_get_program_register I was confused because this second commit didn't have anything to do with _mesa_ir_compile_shader, and

[Mesa-dev] [PATCH] mesa/program: remove empty function declaration

2015-11-25 Thread Emil Velikov
From: Emil Velikov Unused since 5e9aa9926b9 (2011) - _mesa_ir_compile_shader 69e07bdeb42 (2009) - _mesa_get_program_register Cc: Kenneth Graunke Cc: Brian Paul Signed-off-by: Emil Velikov --- src/mesa/program/ir_to_mesa.h | 1 - src/mesa/program/prog_execute.h | 4 2 files changed,

Re: [Mesa-dev] [PATCH v2 21/42] glsl: Add default matrix ordering in lower_buffer_access

2015-11-25 Thread Jordan Justen
On 2015-11-25 01:32:37, Iago Toral wrote: > > On Tue, 2015-11-17 at 21:54 -0800, Jordan Justen wrote: > > For compute shader shared variable we will set a default of column > > major. > > > > Signed-off-by: Jordan Justen > > --- > > src/glsl/lower_buffer_access.cpp | 5 +++-- > > src/glsl/lowe

Re: [Mesa-dev] [PATCH] travis: Initial import of travis instructions.

2015-11-25 Thread Eric Anholt
Jose Fonseca writes: > On 24/11/15 21:38, Rob Clark wrote: >> On Tue, Nov 24, 2015 at 4:10 PM, Eric Anholt wrote: >>> Rob Clark writes: >>> On Tue, Nov 24, 2015 at 2:10 PM, Ilia Mirkin wrote: > On Tue, Nov 24, 2015 at 2:04 PM, Eric Anholt wrote: >> This just builds/installs our d

Re: [Mesa-dev] [PATCH v2 27/42] i965/fs: Handle nir shared variable load intrinsic

2015-11-25 Thread Francisco Jerez
Jordan Justen writes: > Signed-off-by: Jordan Justen > --- > src/mesa/drivers/dri/i965/brw_defines.h | 2 ++ > src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 33 > > 2 files changed, 35 insertions(+) > > diff --git a/src/mesa/drivers/dri/i965/brw_defines.h > b/s

[Mesa-dev] [PATCH 2/3] i965/fs: Don't use Gen7-style scratch block reads on Gen9+.

2015-11-25 Thread Francisco Jerez
Unfortunately Gen7 scratch block reads and writes seem to be hardwired to BTI 255 even on Gen9+ where that index causes the dataport to do an IA-coherent read or write. This change is required for the next patch to be correct, since otherwise we would be writing to the scratch space using non-cohe

[Mesa-dev] [PATCH 1/3] i965: Add symbolic defines for some magic dataport surface indices.

2015-11-25 Thread Francisco Jerez
--- src/mesa/drivers/dri/i965/brw_defines.h | 13 + 1 file changed, 13 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_defines.h b/src/mesa/drivers/dri/i965/brw_defines.h index ade3ede..a511d5c 100644 --- a/src/mesa/drivers/dri/i965/brw_defines.h +++ b/src/mesa/drivers/dri/i

[Mesa-dev] [PATCH 3/3] i965/gen9+: Switch thread scratch space to non-coherent stateless access.

2015-11-25 Thread Francisco Jerez
The thread scratch space is thread-local so using the full IA-coherent stateless surface index (255 since Gen8) is unnecessary and potentially expensive. On Gen8 and early steppings of Gen9 this is not a functional change because the kernel already sets bit 4 of HDC_CHICKEN0 which overrides all HD

Re: [Mesa-dev] [PATCH 1/1] i965: Do not overwrite optimizer dumps

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 11:05 AM, Jason Ekstrand wrote: > On Wed, Nov 25, 2015 at 10:52 AM, Matt Turner wrote: >> On Wed, Nov 25, 2015 at 10:46 AM, Jason Ekstrand >> wrote: >>> On Wed, Nov 25, 2015 at 10:45 AM, Matt Turner wrote: On Wed, Nov 25, 2015 at 10:37 AM, Jason Ekstrand wro

Re: [Mesa-dev] [PATCH 0/5] i965/gen9: Support fast clear on SRGB buffers

2015-11-25 Thread Ben Widawsky
On Wed, Nov 25, 2015 at 06:36:34PM +0100, Neil Roberts wrote: [snip] > > Sadly there is a second obstacle stopping window system buffers from > using fast clears which as that they are always x-tiled and supposedly > SKL doesn't support that. This is explicitly disabled in > intel_tiling_support

Re: [Mesa-dev] [PATCH v3 11/42] i965: Implement L3 state atom.

2015-11-25 Thread Matt Turner
On Wed, Nov 25, 2015 at 6:26 AM, Francisco Jerez wrote: > The L3 state atom calculates the target L3 partition weights when the > program bound to some shader stage is modified, and in case they are > far enough from the current partitioning it makes sure that the L3 > state is re-emitted. > > v3:

Re: [Mesa-dev] [PATCH 1/1] i965: Do not overwrite optimizer dumps

2015-11-25 Thread Jason Ekstrand
On Wed, Nov 25, 2015 at 10:52 AM, Matt Turner wrote: > On Wed, Nov 25, 2015 at 10:46 AM, Jason Ekstrand wrote: >> On Wed, Nov 25, 2015 at 10:45 AM, Matt Turner wrote: >>> On Wed, Nov 25, 2015 at 10:37 AM, Jason Ekstrand >>> wrote: On Wed, Nov 25, 2015 at 10:31 AM, Matt Turner wrote:

Re: [Mesa-dev] [PATCH v2] mesa: remove ARB_geometry_shader4

2015-11-25 Thread Kenneth Graunke
On Wednesday, November 25, 2015 12:16:02 PM Marta Lofstedt wrote: > From: Marta Lofstedt > > No drivers currently implement ARB_geometry_shader4, nor are there > any plans to implement it. We only support the version of geometry > shaders that was incorporated into OpenGL 3.2 / GLSL 1.50. > > S

Re: [Mesa-dev] [PATCH 1/2] i965: Fix fragment shader struct inputs.

2015-11-25 Thread Matt Turner
On Tue, Nov 24, 2015 at 10:35 PM, Kenneth Graunke wrote: > Apparently we have literally no support for FS varying struct inputs. > This is somewhat surprising, given that we've had tests for that very > feature that have been passing for a long time. > > Normally, varying packing splits up structu

Re: [Mesa-dev] [PATCH v2] mesa: remove ARB_geometry_shader4

2015-11-25 Thread Ilia Mirkin
At first I thought it was a mistake to remove things from enum_strings.cpp, but it looks like the ARB/EXT extensions actually had different enum values than core GL 3.2 for the same things. I've looked over all of this with some care and it looks right. Will need a bunch of changes to support OES_

Re: [Mesa-dev] [PATCH 2/2] i965: Fix scalar vertex shader struct outputs.

2015-11-25 Thread Jason Ekstrand
On Tue, Nov 24, 2015 at 10:35 PM, Kenneth Graunke wrote: > While we correctly set output[] for composite varyings, we set completely > bogus values for output_components[], making emit_urb_writes() output > zeros instead of the actual values. > > Unfortunately, our simple approach goes out the win

Re: [Mesa-dev] [PATCH 2/5] i965/gen8+: Don't upload the MCS buffer for single-sampled textures

2015-11-25 Thread Ben Widawsky
On Wed, Nov 25, 2015 at 06:36:36PM +0100, Neil Roberts wrote: > For single-sampled textures the MCS buffer is only used to implement > fast clears. However the surface always needs to be resolved before > being used as a texture anyway so the the MCS buffer doesn't actually > achieve anything. This

  1   2   3   >