Re: [Mesa-dev] [PATCH v2 08/10] glsl: A shader cannot redefine or overload built-in functions in GLSL ES 3.00

2015-02-19 Thread Kenneth Graunke
On Thursday, February 19, 2015 09:55:35 AM Samuel Iglesias Gonsalvez wrote: Create a new search function to look for matching built-in functions by name and use it for built-in function redefinition or overload in GLSL ES 3.00. GLSL ES 3.0 spec, chapter 6.1 Function Definitions, page 71

Re: [Mesa-dev] [PATCH v2 08/10] glsl: A shader cannot redefine or overload built-in functions in GLSL ES 3.00

2015-02-19 Thread Samuel Iglesias Gonsálvez
On Thursday 19 February 2015 00:59:56 Kenneth Graunke wrote: On Thursday, February 19, 2015 09:55:35 AM Samuel Iglesias Gonsalvez wrote: Create a new search function to look for matching built-in functions by name and use it for built-in function redefinition or overload in GLSL ES 3.00.

[Mesa-dev] [PATCH v2 08/10] glsl: A shader cannot redefine or overload built-in functions in GLSL ES 3.00

2015-02-19 Thread Samuel Iglesias Gonsalvez
Create a new search function to look for matching built-in functions by name and use it for built-in function redefinition or overload in GLSL ES 3.00. GLSL ES 3.0 spec, chapter 6.1 Function Definitions, page 71 A shader cannot redefine or overload built-in functions. While in GLSL ES 1.0

Re: [Mesa-dev] [PATCH 2/2] st/mesa: add GSL_TYPE_DOUBLE, new ir_unop_* switch cases

2015-02-19 Thread Ilia Mirkin
On Thu, Feb 19, 2015 at 11:27 AM, Brian Paul bri...@vmware.com wrote: To silence compiler warnings about unhandled switch cases. --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 12 1 file changed, 12 insertions(+) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp

Re: [Mesa-dev] [PATCH 3/9] glsl: Create a _mesa_shader_stage_to_abbrev() function.

2015-02-19 Thread Ian Romanick
On 02/18/2015 09:00 PM, Kenneth Graunke wrote: This is similar to _mesa_shader_stage_to_string(), but returns VS instead of vertex. Signed-off-by: Kenneth Graunke kenn...@whitecape.org --- src/glsl/glsl_parser_extras.cpp | 17 + src/glsl/glsl_parser_extras.h | 3 +++ 2

[Mesa-dev] [PATCH] glsl: Use the without_array predicate

2015-02-19 Thread Timothy Arceri
--- src/glsl/ir.h | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/glsl/ir.h b/src/glsl/ir.h index a0f48b2..9c60b07 100644 --- a/src/glsl/ir.h +++ b/src/glsl/ir.h @@ -450,11 +450,8 @@ public: */ inline bool is_interface_instance() const { - const

Re: [Mesa-dev] [PATCH] glsl: don't allow invariant qualifiers for interface blocks

2015-02-19 Thread Ian Romanick
On 12/09/2014 02:52 AM, Eduardo Lima Mitev wrote: From: Samuel Iglesias Gonsalvez sigles...@igalia.com GLSL 1.50 and GLSL 4.40 specs, they both say the same in Interface Blocks section: If no optional qualifier is used in a member-declaration, the qualification of the member includes

Re: [Mesa-dev] [PATCH 10/32] i965/fs: Remove logic to keep track of MRF metadata in lower_load_payload().

2015-02-19 Thread Jason Ekstrand
On Fri, Feb 6, 2015 at 4:01 PM, Francisco Jerez curroje...@riseup.net wrote: Hey Matt, Matt Turner matts...@gmail.com writes: On Fri, Feb 6, 2015 at 6:42 AM, Francisco Jerez curroje...@riseup.net wrote: MRFs cannot be read from anyway so they cannot possibly be a valid source of

Re: [Mesa-dev] [PATCH 3/9] glsl: Create a _mesa_shader_stage_to_abbrev() function.

2015-02-19 Thread Ian Romanick
On 02/19/2015 11:43 AM, Ian Romanick wrote: On 02/18/2015 09:00 PM, Kenneth Graunke wrote: This is similar to _mesa_shader_stage_to_string(), but returns VS instead of vertex. Signed-off-by: Kenneth Graunke kenn...@whitecape.org --- src/glsl/glsl_parser_extras.cpp | 17 +

Re: [Mesa-dev] [PATCH 10/32] i965/fs: Remove logic to keep track of MRF metadata in lower_load_payload().

2015-02-19 Thread Francisco Jerez
Jason Ekstrand ja...@jlekstrand.net writes: On Fri, Feb 6, 2015 at 4:01 PM, Francisco Jerez curroje...@riseup.net wrote: Hey Matt, Matt Turner matts...@gmail.com writes: On Fri, Feb 6, 2015 at 6:42 AM, Francisco Jerez curroje...@riseup.net wrote: MRFs cannot be read from anyway so

[Mesa-dev] [PATCH 2/2] st/mesa: add GSL_TYPE_DOUBLE, new ir_unop_* switch cases

2015-02-19 Thread Brian Paul
To silence compiler warnings about unhandled switch cases. v2: move GSL_TYPE_DOUBLE case to the Invalid type in type_size section, per Ilia. --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 12 1 file changed, 12 insertions(+) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp

[Mesa-dev] [PATCH 1/2] nir: add missing GLSL_TYPE_DOUBLE case in type_size()

2015-02-19 Thread Brian Paul
To silence compiler warning about unhandled switch case. v2: move GLSL_TYPE_DOUBLE to the not reached section, per Ilia. --- src/glsl/nir/nir_lower_io.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/glsl/nir/nir_lower_io.c b/src/glsl/nir/nir_lower_io.c index ddbc249..207f8da 100644 ---

Re: [Mesa-dev] [PATCH 1/2] nir: add missing GLSL_TYPE_DOUBLE case in type_size()

2015-02-19 Thread Ilia Mirkin
Series is Reviewed-by: Ilia Mirkin imir...@alum.mit.edu On Thu, Feb 19, 2015 at 3:51 PM, Brian Paul bri...@vmware.com wrote: To silence compiler warning about unhandled switch case. v2: move GLSL_TYPE_DOUBLE to the not reached section, per Ilia. --- src/glsl/nir/nir_lower_io.c | 1 + 1 file

Re: [Mesa-dev] [PATCH 10/32] i965/fs: Remove logic to keep track of MRF metadata in lower_load_payload().

2015-02-19 Thread Jason Ekstrand
On Thu, Feb 19, 2015 at 12:13 PM, Francisco Jerez curroje...@riseup.net wrote: Jason Ekstrand ja...@jlekstrand.net writes: On Fri, Feb 6, 2015 at 4:01 PM, Francisco Jerez curroje...@riseup.net wrote: Hey Matt, Matt Turner matts...@gmail.com writes: On Fri, Feb 6, 2015 at 6:42

[Mesa-dev] [PATCH] radeonsi: don't use SQC_CACHES to flush ICACHE and KCACHE on SI

2015-02-19 Thread Marek Olšák
From: Marek Olšák marek.ol...@amd.com This reverts 73c2b0d18c51459697d8ec194ecfc4438c98c139. It doesn't seem to be reliable. It's probably missing a wait packet or something, because it's just a register write and doesn't wait for anything. SURFACE_SYNC at least seems to wait until the flush is

Re: [Mesa-dev] [PATCH 2/2] i965/skl: Layout a 1D miptree horizontally

2015-02-19 Thread Neil Roberts
Ian Romanick i...@freedesktop.org writes: There aren't any compressed formats that support 1D textures, so I don't think this can occur. Does the bspec say anything about compressed 1D textures? Ah yes, you're right. I just copied it from brw_miptree_layout_2d without really thinking it

Re: [Mesa-dev] [Mesa-announce] Mesa 10.3 release candidate 1

2015-02-19 Thread Lucas Stach
Am Freitag, den 07.11.2014, 01:19 -0800 schrieb Matt Turner: On Fri, Nov 7, 2014 at 1:07 AM, Thierry Vignaud thierry.vign...@gmail.com wrote: On 5 November 2014 04:44, Matt Turner matts...@gmail.com wrote: I tried to reproduce this today and couldn't. (...) Thanks. Maybe you could

[Mesa-dev] [PATCH] install-lib-links: don't depend on .libs directory

2015-02-19 Thread Lucas Stach
This snippet can be included in Makefiles that may, depending on the project configuration, not actually build any installable libraries. In that case we don't have anything to depend on and this part of the makefile may be executed before the .libs directory is created, so do not depend on it

Re: [Mesa-dev] [PATCH v4] Fixing an x86 FPU bug.

2015-02-19 Thread Brian Paul
Looks better, just a bunch of nit-picks... First, I think the summary/subject line can be improved. How about mesa: use fi_type in vertex attribute code On 02/18/2015 10:00 AM, marius.pre...@intel.com wrote: From: Marius Predut marius.pre...@intel.com On 32-bit, for floating point

Re: [Mesa-dev] [PATCH 2/2] st/mesa: add GSL_TYPE_DOUBLE, new ir_unop_* switch cases

2015-02-19 Thread Anuj Phogat
On Thu, Feb 19, 2015 at 8:27 AM, Brian Paul bri...@vmware.com wrote: To silence compiler warnings about unhandled switch cases. --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 12 1 file changed, 12 insertions(+) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp

Re: [Mesa-dev] [PATCH 9/9] i965/vec4: Print VS or GS when compiles fail, not vec4.

2015-02-19 Thread Kristian Høgsberg
On Wed, Feb 18, 2015 at 9:37 PM, Jason Ekstrand ja...@jlekstrand.net wrote: Series is Reviewed-by: Jason Ekstrand jason.ekstr...@intel.com Me too: Reviewed-by: Kristian Høgsberg k...@bitplanet.net On Feb 18, 2015 9:00 PM, Kenneth Graunke kenn...@whitecape.org wrote: This is now trivial to

Re: [Mesa-dev] [PATCH] glsl: Use the without_array predicate

2015-02-19 Thread Matt Turner
On Thu, Feb 19, 2015 at 11:57 AM, Timothy Arceri t_arc...@yahoo.com.au wrote: --- src/glsl/ir.h | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/glsl/ir.h b/src/glsl/ir.h index a0f48b2..9c60b07 100644 --- a/src/glsl/ir.h +++ b/src/glsl/ir.h @@ -450,11 +450,8

Re: [Mesa-dev] [PATCH 10/32] i965/fs: Remove logic to keep track of MRF metadata in lower_load_payload().

2015-02-19 Thread Francisco Jerez
Jason Ekstrand ja...@jlekstrand.net writes: On Thu, Feb 19, 2015 at 12:13 PM, Francisco Jerez curroje...@riseup.net wrote: Jason Ekstrand ja...@jlekstrand.net writes: On Fri, Feb 6, 2015 at 4:01 PM, Francisco Jerez curroje...@riseup.net wrote: Hey Matt, Matt Turner

Re: [Mesa-dev] [PATCH 1/2] nir: add missing GLSL_TYPE_DOUBLE case in type_size()

2015-02-19 Thread Jason Ekstrand
Reviewed-by: Jason Ekstrand jason.ekstr...@intel.com On Thu, Feb 19, 2015 at 12:51 PM, Brian Paul bri...@vmware.com wrote: To silence compiler warning about unhandled switch case. v2: move GLSL_TYPE_DOUBLE to the not reached section, per Ilia. --- src/glsl/nir/nir_lower_io.c | 1 + 1 file

Re: [Mesa-dev] [PATCH] st/mesa: fix sampler view reference counting bug in glDraw/CopyPixels

2015-02-19 Thread Ilia Mirkin
On Wed, Feb 18, 2015 at 1:20 PM, Brian Paul bri...@vmware.com wrote: Use pipe_sampler_view_reference() instead of ordinary assignment. Also add a new sanity check assertion. Fixes piglit gl-1.0-drawpixels-color-index test crash. But note that the test still fails. Fails on nvc0 as well, for

Re: [Mesa-dev] [PATCH] st/mesa: fix sampler view reference counting bug in glDraw/CopyPixels

2015-02-19 Thread Brian Paul
Ping. On 02/18/2015 11:20 AM, Brian Paul wrote: Use pipe_sampler_view_reference() instead of ordinary assignment. Also add a new sanity check assertion. Fixes piglit gl-1.0-drawpixels-color-index test crash. But note that the test still fails. Cc: 10.4, 10.5 mesa-sta...@lists.freedesktop.org

[Mesa-dev] [PATCH] gallium: add double opcodes and TGSI execution (v4.1)

2015-02-19 Thread Dave Airlie
This patch adds support for a set of double opcodes to TGSI. It is an update of work done originally by Michal Krol on the gallium-double-opcodes branch. The opcodes have a hint where they came from in the header file. v2: add unsigned/int - double v2.1: update docs. v3: add DRSQ (Glenn), fix

Re: [Mesa-dev] [PATCH 10/32] i965/fs: Remove logic to keep track of MRF metadata in lower_load_payload().

2015-02-19 Thread Jason Ekstrand
On Thu, Feb 19, 2015 at 1:25 PM, Francisco Jerez curroje...@riseup.net wrote: Jason Ekstrand ja...@jlekstrand.net writes: On Thu, Feb 19, 2015 at 12:13 PM, Francisco Jerez curroje...@riseup.net wrote: Jason Ekstrand ja...@jlekstrand.net writes: On Fri, Feb 6, 2015 at 4:01 PM,

Re: [Mesa-dev] [PATCH 1/3] gallium: add double opcodes and TGSI execution (v3.1)

2015-02-19 Thread Dave Airlie
I've addressed most of these, + /* double modifiers handled by caller */ + if (dtype) + return; Should the below code just get moved to fetch_source? Or does it rely on local args which makes that a pain? If it's not too hard, I think it'd be a lot cleaner / clearer than an extra

Re: [Mesa-dev] [PATCH 1/9] i965/fs: Remove type parameter from emit_vs_system_value().

2015-02-19 Thread Anuj Phogat
On Wed, Feb 18, 2015 at 9:00 PM, Kenneth Graunke kenn...@whitecape.org wrote: Every VS system value has type D. We can always add this back if that changes, but for now, it's extra typing. Signed-off-by: Kenneth Graunke kenn...@whitecape.org --- src/mesa/drivers/dri/i965/brw_fs.h

Re: [Mesa-dev] [PATCH] gallium: add double opcodes and TGSI execution (v4.1)

2015-02-19 Thread Ilia Mirkin
On Thu, Feb 19, 2015 at 4:53 PM, Dave Airlie airl...@gmail.com wrote: This patch adds support for a set of double opcodes to TGSI. It is an update of work done originally by Michal Krol on the gallium-double-opcodes branch. The opcodes have a hint where they came from in the header file.

Re: [Mesa-dev] [PATCH] st/mesa: fix sampler view reference counting bug in glDraw/CopyPixels

2015-02-19 Thread Brian Paul
On 02/19/2015 02:55 PM, Ilia Mirkin wrote: On Wed, Feb 18, 2015 at 1:20 PM, Brian Paul bri...@vmware.com wrote: Use pipe_sampler_view_reference() instead of ordinary assignment. Also add a new sanity check assertion. Fixes piglit gl-1.0-drawpixels-color-index test crash. But note that the

[Mesa-dev] [PATCH] glsl: add lowering for double divide to rcp/mul

2015-02-19 Thread Dave Airlie
From: Dave Airlie airl...@redhat.com It looks like no hw does div anyways, so we should just lower at the GLSL level. Signed-off-by: Dave Airlie airl...@redhat.com --- src/glsl/lower_instructions.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

Re: [Mesa-dev] [PATCH] fp64: disable varying packing for doubles.

2015-02-19 Thread Dave Airlie
On 20 February 2015 at 12:49, Ilia Mirkin imir...@alum.mit.edu wrote: On Thu, Feb 19, 2015 at 9:43 PM, Dave Airlie airl...@gmail.com wrote: From: Dave Airlie airl...@redhat.com I'm not sure we really care about this, but we need to write better support if we do. For now just disable it.

Re: [Mesa-dev] [PATCH] gallium: add new double-related shader caps to all the getters

2015-02-19 Thread Dave Airlie
On 20 February 2015 at 14:46, Ilia Mirkin imir...@alum.mit.edu wrote: Missed a few drivers in the earlier changes, this should fix up all the ones that print unknown caps or don't have a default statement. +++ b/src/gallium/drivers/vc4/vc4_screen.c @@ -318,6 +318,10 @@

Re: [Mesa-dev] [PATCH] glsl: don't allow invariant qualifiers for interface blocks

2015-02-19 Thread Samuel Iglesias Gonsálvez
On Wednesday 18 February 2015 11:51:45 Matt Turner wrote: On Tue, Dec 9, 2014 at 2:52 AM, Eduardo Lima Mitev el...@igalia.com wrote: From: Samuel Iglesias Gonsalvez sigles...@igalia.com GLSL 1.50 and GLSL 4.40 specs, they both say the same in Interface Blocks section: If no optional

Re: [Mesa-dev] [PATCH] i965/fs: Set pixel/sample mask for compute shaders atomic ops

2015-02-19 Thread Ben Widawsky
On Thu, Feb 19, 2015 at 11:25:56PM -0800, Jordan Justen wrote: On 2015-02-19 21:40:37, Ben Widawsky wrote: On Thu, Feb 19, 2015 at 03:42:05PM -0800, Jordan Justen wrote: For fragment programs, we pull this mask from the payload header. The same mask doesn't exist for compute shaders, so

Re: [Mesa-dev] [PATCH] i965/gen6: Fix GL_GEOMETRY_SHADER_PRIMITIVES_EMITTED_ARB

2015-02-19 Thread Ben Widawsky
On Fri, Feb 20, 2015 at 08:21:25AM +0100, Iago Toral Quiroga wrote: In gen6 we need to compute the primitive count in the generated GS program. The current implementation only counts full primitives, that is, if the output primitive type is a triangle strip, it won't count individual triangles

Re: [Mesa-dev] [PATCH 06/23] main: Add entry point for NamedBufferStorage.

2015-02-19 Thread Martin Peres
On 20/02/2015 02:15, Laura Ekstrand wrote: This is NamedBufferStorage, not NamedBufferData. The storage function uses a bitfield instead of an enum. Oops, sorry. I was trying to match these patches with their relative piglit tests and as the order is not always the same, I must have got

Re: [Mesa-dev] [PATCH 2/3] i965/fs/nir: Optimize (gl_FrontFacing ? x : y) where x and y are ±1.0.

2015-02-19 Thread Matt Turner
On Tue, Feb 17, 2015 at 11:46 AM, Matt Turner matts...@gmail.com wrote: total instructions in shared programs: 8013221 - 8010869 (-0.03%) instructions in affected programs: 475925 - 473573 (-0.49%) helped:2350 --- Patches 1 and 3 have been reviewed, but I'm

[Mesa-dev] [PATCH] glsl/fp64: disable varying packing for doubles. (v2)

2015-02-19 Thread Dave Airlie
From: Dave Airlie airl...@redhat.com I'm not sure we really care about this, but we need to write better support if we do. For now just disable it. piglit test: tests/spec/arb_gpu_shader_fp64/execution/vs-out-fs-in-double-2.shader_test v2: move code down below to avoid getting array type.

[Mesa-dev] [PATCH] gallium: add new double-related shader caps to all the getters

2015-02-19 Thread Ilia Mirkin
Missed a few drivers in the earlier changes, this should fix up all the ones that print unknown caps or don't have a default statement. Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- src/gallium/drivers/freedreno/freedreno_screen.c | 2 ++ src/gallium/drivers/i915/i915_screen.c |

Re: [Mesa-dev] [PATCH] i965/fs: Set pixel/sample mask for compute shaders atomic ops

2015-02-19 Thread Ben Widawsky
On Thu, Feb 19, 2015 at 03:42:05PM -0800, Jordan Justen wrote: For fragment programs, we pull this mask from the payload header. The same mask doesn't exist for compute shaders, so we set all bits to enabled. Note: this mask is ANDed with the execution mask, so some channels may not end up

[Mesa-dev] [PATCH] nir: Copy-propagate vecN operations that are actually moves

2015-02-19 Thread Jason Ekstrand
We were already do this for ALU operations but we haven't for non-ALU operations. This changes that. total NIR instructions in shared programs: 2039883 - 2022338 (-0.86%) NIR instructions in affected programs: 1768850 - 1751305 (-0.99%) helped:14244 HURT:

Re: [Mesa-dev] [PATCH] glsl: don't allow invariant qualifiers for interface blocks

2015-02-19 Thread Samuel Iglesias Gonsálvez
On Thursday 19 February 2015 11:39:13 Ian Romanick wrote: On 12/09/2014 02:52 AM, Eduardo Lima Mitev wrote: From: Samuel Iglesias Gonsalvez sigles...@igalia.com GLSL 1.50 and GLSL 4.40 specs, they both say the same in Interface Blocks section: If no optional qualifier is used in a

Re: [Mesa-dev] [PATCH] i965/fs: Set pixel/sample mask for compute shaders atomic ops

2015-02-19 Thread Jordan Justen
On 2015-02-19 21:40:37, Ben Widawsky wrote: On Thu, Feb 19, 2015 at 03:42:05PM -0800, Jordan Justen wrote: For fragment programs, we pull this mask from the payload header. The same mask doesn't exist for compute shaders, so we set all bits to enabled. Note: this mask is ANDed with the

Re: [Mesa-dev] [PATCH 02/23] main: Add entry point for TextureBufferRange.

2015-02-19 Thread Martin Peres
On 18/02/2015 20:10, Ian Romanick wrote: On 02/17/2015 07:59 AM, Martin Peres wrote: Hey Laura, Thanks for this code. I'll be sending reviews throughout the week :) On 12/02/15 04:05, Laura Ekstrand wrote: diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index

Re: [Mesa-dev] [PATCH] gallium: add new double-related shader caps to all the getters

2015-02-19 Thread Ilia Mirkin
On Thu, Feb 19, 2015 at 11:54 PM, Dave Airlie airl...@gmail.com wrote: On 20 February 2015 at 14:46, Ilia Mirkin imir...@alum.mit.edu wrote: Missed a few drivers in the earlier changes, this should fix up all the ones that print unknown caps or don't have a default statement. +++

[Mesa-dev] [PATCH] i965/skl: Use 1 register for uniform pull constant payload

2015-02-19 Thread Ben Widawsky
When under dispatch_width=16 the previous code would allocate 2 registers for the payload when only one is needed. This manifested itself through bugs on SKL which needs to mess with this instruction. Ken though this might impact shader-db, but apparently it doesn't Cc: Kenneth Graunke

Re: [Mesa-dev] [PATCH] nir: Copy-propagate vecN operations that are actually moves

2015-02-19 Thread Connor Abbott
I agree with Ken that the regressions are small enough, and it seems they're mostly stuff we can prevent by being smarter when doing the sel peephole, so it seems like the cleanup that will probably help other passes is worth it. Reviewed-by: Connor Abbott cwabbo...@gmail.com On Fri, Feb 20,

Re: [Mesa-dev] [PATCH 07/23] main: Add entry point for NamedBufferData.

2015-02-19 Thread Martin Peres
On 20/02/2015 02:12, Laura Ekstrand wrote: On Wed, Feb 18, 2015 at 7:40 AM, Martin Peres martin.pe...@linux.intel.com mailto:martin.pe...@linux.intel.com wrote: On 12/02/15 04:05, Laura Ekstrand wrote: v2: review from Ian Romanick - Fix space in

Re: [Mesa-dev] [PATCH] i965/fs: Set pixel/sample mask for compute shaders atomic ops

2015-02-19 Thread Matt Turner
On Thu, Feb 19, 2015 at 3:42 PM, Jordan Justen jordan.l.jus...@intel.com wrote: For fragment programs, we pull this mask from the payload header. The same mask doesn't exist for compute shaders, so we set all bits to enabled. Note: this mask is ANDed with the execution mask, so some channels

[Mesa-dev] [PATCH] i965/gen6: Fix GL_GEOMETRY_SHADER_PRIMITIVES_EMITTED_ARB

2015-02-19 Thread Iago Toral Quiroga
In gen6 we need to compute the primitive count in the generated GS program. The current implementation only counts full primitives, that is, if the output primitive type is a triangle strip, it won't count individual triangles in the strip, only complete strips. If we want to count basic

[Mesa-dev] [PATCH] st/glsl_to_tgsi: fix ir_assignment hack doing bad things for doubles

2015-02-19 Thread Dave Airlie
From: Dave Airlie airl...@redhat.com This hack for fixing gl_FragDepth apparantly caused a GLSL shader outputting a single double to try and output a dvec4, but we hadn't assigned outputs for the secondary bit. This avoids going into the hack code for scalar doubles. Signed-off-by: Dave Airlie

Re: [Mesa-dev] [PATCH] nir: Copy-propagate vecN operations that are actually moves

2015-02-19 Thread Kenneth Graunke
On Thursday, February 19, 2015 10:03:15 PM Jason Ekstrand wrote: We were already do this for ALU operations but we haven't for non-ALU operations. This changes that. total NIR instructions in shared programs: 2039883 - 2022338 (-0.86%) NIR instructions in affected programs: 1768850 -

Re: [Mesa-dev] [PATCH] nir: Copy-propagate vecN operations that are actually moves

2015-02-19 Thread Matt Turner
On Thu, Feb 19, 2015 at 11:01 PM, Connor Abbott cwabbo...@gmail.com wrote: I agree with Ken that the regressions are small enough, and it seems they're mostly stuff we can prevent by being smarter when doing the sel peephole, so it seems like the cleanup that will probably help other passes is

Re: [Mesa-dev] [PATCH] glsl: add lowering for double divide to rcp/mul

2015-02-19 Thread Ilia Mirkin
On Thu, Feb 19, 2015 at 5:47 PM, Dave Airlie airl...@gmail.com wrote: From: Dave Airlie airl...@redhat.com It looks like no hw does div anyways, so we should just lower at the GLSL level. Sounds like radeonsi has helpers for DDIV, but they can work this out when they add support in mesa. Like

Re: [Mesa-dev] [PATCH 3/3] i965/fs: Consider MOV.SAT to interfere if it has a source modifier.

2015-02-19 Thread Ian Romanick
This patch is Reviewed-by: Ian Romanick ian.d.roman...@intel.com On 02/11/2015 02:54 PM, Matt Turner wrote: The saturate propagation pass recognizes that the second instruction below does not interfere with an attempt to propagate the saturate modifier from instruction 3 to 1. 1: add(8)

[Mesa-dev] [PATCH] i965: just avoid warnings with fp64

2015-02-19 Thread Dave Airlie
This just fills in some blanks to avoid warnings in the i965 driver. Signed-off-by: Dave Airlie airl...@redhat.com --- src/mesa/drivers/dri/i965/brw_fs.cpp | 1 + src/mesa/drivers/dri/i965/brw_fs_channel_expressions.cpp | 13 +

Re: [Mesa-dev] [PATCH 1/4] i965: Don't emit saturates for instructions without destinations.

2015-02-19 Thread Matt Turner
On Thu, Feb 19, 2015 at 3:31 PM, Ian Romanick i...@freedesktop.org wrote: On 02/10/2015 11:09 AM, Matt Turner wrote: We were special casing OPCODE_END but no other instructions that have no destination, like OPCODE_KIL, leading us to emitting MOVs with null destinations. Should we (or do we

[Mesa-dev] [PATCH 4/6] st/mesa: add support for new double opcodes

2015-02-19 Thread Ilia Mirkin
Not having SQRT is assumed to tacitly mean that RSQ is available. Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp

[Mesa-dev] [PATCH 3/6] gallium: add shader cap for dldexp/dfracexp support

2015-02-19 Thread Ilia Mirkin
Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- src/gallium/auxiliary/gallivm/lp_bld_limits.h | 1 + src/gallium/auxiliary/tgsi/tgsi_exec.h | 1 + src/gallium/docs/source/screen.rst | 2 ++ src/gallium/drivers/nouveau/nvc0/nvc0_screen.c | 2 ++

[Mesa-dev] [PATCH 6/6] st/mesa: lower DFRACEXP/DLDEXP when they are not supported

2015-02-19 Thread Ilia Mirkin
Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp index e170217..4d91ca6 100644 ---

[Mesa-dev] [PATCH 5/6] st/mesa: disable lowering of dops to dfrac when dround is available

2015-02-19 Thread Ilia Mirkin
Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp index 63b779d..e170217 100644

[Mesa-dev] [PATCH 2/6] gallium: add a cap to enable double rounding opcodes

2015-02-19 Thread Ilia Mirkin
Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- src/gallium/auxiliary/gallivm/lp_bld_limits.h | 1 + src/gallium/auxiliary/tgsi/tgsi_exec.h | 2 ++ src/gallium/docs/source/screen.rst | 2 ++ src/gallium/drivers/nouveau/nvc0/nvc0_screen.c | 4

[Mesa-dev] [PATCH 1/6] gallium: add some more double opcodes to avoid unnecessary lowering

2015-02-19 Thread Ilia Mirkin
Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- src/gallium/auxiliary/tgsi/tgsi_info.c | 5 src/gallium/docs/source/tgsi.rst | 39 ++ src/gallium/include/pipe/p_shader_tokens.h | 7 +- 3 files changed, 50 insertions(+), 1 deletion(-) diff

[Mesa-dev] [PATCH 1/2] tgsi/scan: add uses_doubles to tgsi scanner

2015-02-19 Thread Dave Airlie
From: Dave Airlie airl...@redhat.com This allows drivers to work out if a shader contains any double opcodes easily. Signed-off-by: Dave Airlie airl...@redhat.com --- src/gallium/auxiliary/tgsi/tgsi_scan.c | 4 src/gallium/auxiliary/tgsi/tgsi_scan.h | 2 +- 2 files changed, 5

Re: [Mesa-dev] [PATCH] fp64: disable varying packing for doubles.

2015-02-19 Thread Ilia Mirkin
On Thu, Feb 19, 2015 at 9:43 PM, Dave Airlie airl...@gmail.com wrote: From: Dave Airlie airl...@redhat.com I'm not sure we really care about this, but we need to write better support if we do. For now just disable it. piglit test:

[Mesa-dev] [PATCH 1/2] nir: add missing GLSL_TYPE_DOUBLE case in type_size()

2015-02-19 Thread Brian Paul
To silence compiler warning about unhandled switch case. --- src/glsl/nir/nir_lower_io.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/glsl/nir/nir_lower_io.c b/src/glsl/nir/nir_lower_io.c index ddbc249..23499e5 100644 --- a/src/glsl/nir/nir_lower_io.c +++ b/src/glsl/nir/nir_lower_io.c

[Mesa-dev] [PATCH 2/2] st/mesa: add GSL_TYPE_DOUBLE, new ir_unop_* switch cases

2015-02-19 Thread Brian Paul
To silence compiler warnings about unhandled switch cases. --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 12 1 file changed, 12 insertions(+) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp index 3dac004..9969fac 100644 ---

[Mesa-dev] [Bug 89199] u_math.h:591:4: error: implicit declaration of function 'ffsll'

2015-02-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=89199 --- Comment #2 from Brian Paul bri...@vmware.com --- Hi Vinson, Is that with gcc? Which compiler version? I'll attach a patch proposal for you to try... -- You are receiving this mail because: You are the QA Contact for the bug. You are the

[Mesa-dev] [Bug 89199] u_math.h:591:4: error: implicit declaration of function 'ffsll'

2015-02-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=89199 --- Comment #3 from Brian Paul bri...@vmware.com --- Created attachment 113670 -- https://bugs.freedesktop.org/attachment.cgi?id=113670action=edit proposed patch If you're using gcc, maybe a gcc version check would be better. This patch also

[Mesa-dev] [PATCH] mesa: Check that draw buffers are valid for glDrawBuffers on GLES3

2015-02-19 Thread Eduardo Lima Mitev
Section 4.2 (Whole Framebuffer Operations) of the OpenGL 3.0 specification says: Each buffer listed in bufs must be BACK, NONE, or one of the values from table 4.3 (NONE, COLOR_ATTACHMENTi). Fixes 1 dEQP test: * dEQP-GLES3.functional.negative_api.buffer.draw_buffers ---

Re: [Mesa-dev] [PATCH v2] mesa: Check first that draw buffers are valid for glDrawBuffers on GLES3

2015-02-19 Thread Eduardo Lima Mitev
On 02/18/2015 09:09 PM, Matt Turner wrote: On Tue, Jan 13, 2015 at 3:29 AM, Eduardo Lima Mitev el...@igalia.com wrote: This patch was updated and is pending review. I think we're waiting on a new version with Tapani's comment addressed. The patch looks right, FWIW. Hi Matt, I

Re: [Mesa-dev] [PATCH] mesa: Check that draw buffers are valid for glDrawBuffers on GLES3

2015-02-19 Thread Matt Turner
Reviewed-by: Matt Turner matts...@gmail.com ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [Mesa-announce] Mesa 10.3 release candidate 1

2015-02-19 Thread Matt Turner
On Thu, Feb 19, 2015 at 5:53 AM, Lucas Stach l.st...@pengutronix.de wrote: Am Freitag, den 07.11.2014, 01:19 -0800 schrieb Matt Turner: On Fri, Nov 7, 2014 at 1:07 AM, Thierry Vignaud thierry.vign...@gmail.com wrote: On 5 November 2014 04:44, Matt Turner matts...@gmail.com wrote: I tried to

Re: [Mesa-dev] [PATCH] radeonsi: don't use SQC_CACHES to flush ICACHE and KCACHE on SI

2015-02-19 Thread Alex Deucher
On Thu, Feb 19, 2015 at 7:10 AM, Marek Olšák mar...@gmail.com wrote: From: Marek Olšák marek.ol...@amd.com This reverts 73c2b0d18c51459697d8ec194ecfc4438c98c139. It doesn't seem to be reliable. It's probably missing a wait packet or something, because it's just a register write and doesn't

Re: [Mesa-dev] [PATCH] install-lib-links: don't depend on .libs directory

2015-02-19 Thread Matt Turner
On Thu, Feb 19, 2015 at 5:52 AM, Lucas Stach l.st...@pengutronix.de wrote: This snippet can be included in Makefiles that may, depending on the project configuration, not actually build any installable libraries. In that case we don't have anything to depend on and this part of the makefile

Re: [Mesa-dev] [PATCH 1/4] i965: Don't emit saturates for instructions without destinations.

2015-02-19 Thread Ian Romanick
On 02/10/2015 11:09 AM, Matt Turner wrote: We were special casing OPCODE_END but no other instructions that have no destination, like OPCODE_KIL, leading us to emitting MOVs with null destinations. Should we (or do we somehow already) handle instructions with null destinations? So...

[Mesa-dev] [PATCH] fp64: disable varying packing for doubles.

2015-02-19 Thread Dave Airlie
From: Dave Airlie airl...@redhat.com I'm not sure we really care about this, but we need to write better support if we do. For now just disable it. piglit test: tests/spec/arb_gpu_shader_fp64/execution/vs-out-fs-in-double-2.shader_test Signed-off-by: Dave Airlie airl...@redhat.com ---

Re: [Mesa-dev] [PATCH 2/4] i965: Use greater-equal cmod to implement maximum.

2015-02-19 Thread Ian Romanick
This patch is Reviewed-by: Ian Romanick ian.d.roman...@intel.com On 02/10/2015 11:09 AM, Matt Turner wrote: The docs specifically call out SEL with .l and .ge as the implementations of MIN and MAX respectively. Among other things, SEL with these conditional mods are commutative. ---

Re: [Mesa-dev] [PATCH 1/4] i965: Don't emit saturates for instructions without destinations.

2015-02-19 Thread Ian Romanick
On 02/19/2015 03:38 PM, Matt Turner wrote: On Thu, Feb 19, 2015 at 3:31 PM, Ian Romanick i...@freedesktop.org wrote: On 02/10/2015 11:09 AM, Matt Turner wrote: We were special casing OPCODE_END but no other instructions that have no destination, like OPCODE_KIL, leading us to emitting MOVs

Re: [Mesa-dev] [PATCH] i965: just avoid warnings with fp64

2015-02-19 Thread Chris Forbes
Looks reasonable, if it's going to be a while before an i965 backend is ready.. Reviewed-by: Chris Forbes chr...@ijw.co.nz On Fri, Feb 20, 2015 at 12:38 PM, Dave Airlie airl...@gmail.com wrote: This just fills in some blanks to avoid warnings in the i965 driver. Signed-off-by: Dave Airlie

Re: [Mesa-dev] [PATCH 10/32] i965/fs: Remove logic to keep track of MRF metadata in lower_load_payload().

2015-02-19 Thread Jason Ekstrand
I'm still a little pensive. But Reviewed-by: Jason Ekstrand jason.ekstr...@intel.com Now for a little aside. I have come to the conclusion that I made a grave mistake when I did the LOAD_PAYLOAD stuff. In retrospect, I should have just subclassed fs_inst for load_payload. The problem is that

Re: [Mesa-dev] [PATCH] glapi: Do not use backtrace on FreeBSD.

2015-02-19 Thread Vinson Lee
On Thu, Feb 5, 2015 at 4:02 AM, Ian Romanick i...@freedesktop.org wrote: On 01/24/2015 05:46 AM, Vinson Lee wrote: Fix build error. CCLD libGL.la libglapi.a(glapi_libglapi_la-glapi_gentable.o): In function `__glapi_gentable_NoOp': glapi_gentable.c:76: undefined reference to

[Mesa-dev] [PATCH 2/2] r600g: add doubles support for CAYMAN

2015-02-19 Thread Dave Airlie
From: Dave Airlie airl...@redhat.com Only a subset of AMD GPUs supported by r600g support doubles, CAYMAN and CYPRESS are probably all we'll try and support, however I don't have a CYPRESS so ignore that for now. This disables SB support for doubles, as we think we need to make the scheduler

[Mesa-dev] [RFC] cayman fp64 support

2015-02-19 Thread Dave Airlie
This just implements FP64 on cayman but disables the sb compiler for now. Dave. ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH 1/2] tgsi/scan: add uses_doubles to tgsi scanner

2015-02-19 Thread Ilia Mirkin
On Thu, Feb 19, 2015 at 7:54 PM, Dave Airlie airl...@gmail.com wrote: From: Dave Airlie airl...@redhat.com This allows drivers to work out if a shader contains any double opcodes easily. Signed-off-by: Dave Airlie airl...@redhat.com --- src/gallium/auxiliary/tgsi/tgsi_scan.c | 4

[Mesa-dev] [PATCH v5] mesa: use fi_type in vertex attribute code

2015-02-19 Thread marius . predut
From: Marius Predut marius.pre...@intel.com For 32-bit builds, floating point operations use x86 FPU registers, not SSE registers. If we're actually storing an integer in a float variable, the value might get modified when written to memory. This patch changes the VBO code to use the fi_type

Re: [Mesa-dev] [PATCH 2/3] i965/fs: Use fs_inst::overwrites_reg() in saturate propagation.

2015-02-19 Thread Matt Turner
On Thu, Feb 19, 2015 at 3:25 PM, Ian Romanick i...@freedesktop.org wrote: On 02/11/2015 02:54 PM, Matt Turner wrote: This is safer and matches the conditional_mod propagation pass. Cc: mesa-sta...@lists.freedesktop.org --- .../dri/i965/brw_fs_saturate_propagation.cpp | 8 ++---

Re: [Mesa-dev] [PATCH] st/mesa: add st fp64 support (v7)

2015-02-19 Thread Ilia Mirkin
On Thu, Feb 19, 2015 at 6:09 PM, Dave Airlie airl...@gmail.com wrote: From: Dave Airlie airl...@redhat.com v2 : add double to int/unsigned conversion v3: handle fp64 consts better v4: use DRSQ v4.1: add d2b v4.2: drop DDIV v5: split out some prep patches. v5.1: add some comments. v5.2:

[Mesa-dev] [PATCH] i965/fs: Set pixel/sample mask for compute shaders atomic ops

2015-02-19 Thread Jordan Justen
For fragment programs, we pull this mask from the payload header. The same mask doesn't exist for compute shaders, so we set all bits to enabled. Note: this mask is ANDed with the execution mask, so some channels may not end up issuing the atomic operation. Signed-off-by: Jordan Justen

[Mesa-dev] [Bug 89199] u_math.h:591:4: error: implicit declaration of function 'ffsll'

2015-02-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=89199 --- Comment #4 from Vinson Lee v...@freedesktop.org --- $ gcc --version gcc (NetBSD nb2 20110806) 4.5.3 Copyright (C) 2010 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not

Re: [Mesa-dev] [PATCH 06/23] main: Add entry point for NamedBufferStorage.

2015-02-19 Thread Laura Ekstrand
This is NamedBufferStorage, not NamedBufferData. The storage function uses a bitfield instead of an enum. On Wed, Feb 18, 2015 at 7:04 AM, Martin Peres martin.pe...@linux.intel.com wrote: On 12/02/15 04:05, Laura Ekstrand wrote: --- src/mapi/glapi/gen/ARB_direct_state_access.xml | 7 +++

[Mesa-dev] [Bug 89238] nir/nir.h, line 643: Error: In this declaration src is of an incomplete type nir_alu_src[].

2015-02-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=89238 Bug ID: 89238 Summary: nir/nir.h, line 643: Error: In this declaration src is of an incomplete type nir_alu_src[]. Product: Mesa Version: git Hardware: x86-64 (AMD64)

[Mesa-dev] [PATCH 01/11] nvc0/ir: add emission of dadd/dmul/dmad opcodes, fix minmax

2015-02-19 Thread Ilia Mirkin
Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- .../drivers/nouveau/codegen/nv50_ir_emit_nvc0.cpp | 66 +- 1 file changed, 63 insertions(+), 3 deletions(-) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_nvc0.cpp

[Mesa-dev] [PATCH] intel: fix EGLImage renderbuffer _BaseFormat

2015-02-19 Thread Frank Henigman
Correctly set _BaseFormat field when creating a gl_renderbuffer with EGLImage storage. Signed-off-by: Frank Henigman fjhenig...@google.com Reviewed-by: Stéphane Marchesin marc...@chromium.org --- src/mesa/drivers/dri/i915/intel_fbo.c | 3 +-- src/mesa/drivers/dri/i965/intel_fbo.c | 2 +- 2 files

Re: [Mesa-dev] [PATCH 2/3] i965/fs: Use fs_inst::overwrites_reg() in saturate propagation.

2015-02-19 Thread Ian Romanick
On 02/11/2015 02:54 PM, Matt Turner wrote: This is safer and matches the conditional_mod propagation pass. Cc: mesa-sta...@lists.freedesktop.org --- .../dri/i965/brw_fs_saturate_propagation.cpp | 8 ++--- .../dri/i965/test_fs_saturate_propagation.cpp | 40

Re: [Mesa-dev] [PATCH 4/4] i965/blorp: Emit MADs.

2015-02-19 Thread Ian Romanick
Assuming that my assumption / recollection that blorp is only for GEN6+, this patch is Reviewed-by: Ian Romanick ian.d.roman...@intel.com On 02/10/2015 11:10 AM, Matt Turner wrote: Low hanging fruit: cuts a couple of instructions. --- src/mesa/drivers/dri/i965/brw_blorp_blit.cpp | 6 ++

Re: [Mesa-dev] [PATCH] i965: just avoid warnings with fp64

2015-02-19 Thread Ian Romanick
Yes, please. Reviewed-by: Ian Romanick ian.d.roman...@intel.com On 02/19/2015 03:38 PM, Dave Airlie wrote: This just fills in some blanks to avoid warnings in the i965 driver. Signed-off-by: Dave Airlie airl...@redhat.com --- src/mesa/drivers/dri/i965/brw_fs.cpp | 1 +

  1   2   >