Re: [Mesa-dev] [PATCH 1/2] r600: fix viewport clipping magic.

2015-12-15 Thread Dave Airlie
> I have to NAK this series, but I was able to find something about the issue. > > If oViewport is used, VGT_REUSE_OFF must disable reuse. That's the correct > fix. > > If oViewport is constant, reuse can be enabled, but > VTE_VPORT_PROVOKE_DISABLE must be set. Okay I can confirm setting VGT_REUS

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

2015-12-15 Thread Juan A. Suarez Romero
On Thu, 2015-12-10 at 09:47 -0800, Matt Turner wrote: > Assuming that the cause is indeed non-orthogonal state changes, yes. > But I never saw an answer to that question. > > Reviewed-by: Matt Turner After rebasing and testing against master (11.1-branchpoint-653- g5c5ad4d) I can't reproduce th

[Mesa-dev] [PATCH 0/7] GL_ARB_shader_draw_parameters

2015-12-15 Thread Kristian Høgsberg Kristensen
Hi, Here's 7 patches to implement GL_ARB_shader_draw_parameters: https://www.opengl.org/registry/specs/ARB/shader_draw_parameters.txt and I have few new piglit tests for the extension as well. Kristian Kristian Høgsberg Kristensen (7): mesa/vbo: Add draw_id field to struct _mesa_prim mes

[Mesa-dev] [PATCH 1/7] mesa/vbo: Add draw_id field to struct _mesa_prim

2015-12-15 Thread Kristian Høgsberg Kristensen
The drivers will need this for passing in gl_DrawIDARB. For indirect multidraw calls, we get the prim array and prim[i].draw_id == i and is redundant. But for non-indirect calls, we get one primitive at a time and need the draw_id field. --- src/mesa/vbo/vbo.h| 1 + src/mesa/vbo/vbo_ex

[Mesa-dev] [PATCH 6/7] nir: Teach nir_opt_algebraic about adding and subtracting the same thing

2015-12-15 Thread Kristian Høgsberg Kristensen
This optimizes a + b - b to just a. Modest shader-db results (BDW): total instructions in shared programs: 7842452 -> 7841862 (-0.01%) instructions in affected programs: 61938 -> 61348 (-0.95%) total loops in shared programs:2131 -> 2131 (0.00%) helped:

[Mesa-dev] [PATCH 7/7] i965: Reduce vertex state reemission

2015-12-15 Thread Kristian Høgsberg Kristensen
We can inspect VS prog_data for iterations i > 0, and only flag BRW_NEW_VERTICES when one of our system values change. This change also flags BRW_NEW_VERTICES in one case we were missing before: if we're doing an indirect draw, prims[i].basevertex is always 0 and the real base vertex value is in t

[Mesa-dev] [PATCH 4/7] i965: Add support for gl_BaseVertexARB and gl_BaseInstanceARB

2015-12-15 Thread Kristian Høgsberg Kristensen
We already have gl_BaseVertexARB in the .x component of the SGVS vec4 and plug gl_BaseInstanceARB into the last free component (.y). --- src/mesa/drivers/dri/i965/brw_compiler.h | 2 ++ src/mesa/drivers/dri/i965/brw_context.h | 9 -- src/mesa/drivers/dri/i965/brw_draw.c

[Mesa-dev] [PATCH 3/7] i965: Assert that SYSTEM_VALUE_VERTEX_ID gets lowered

2015-12-15 Thread Kristian Høgsberg Kristensen
fs_visitor::emit_vs_system_value() looks like it's trying to handle SYSTEM_VALUE_VERTEX_ID, but we should never see that value in the backend. --- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp b/src/me

[Mesa-dev] [PATCH 2/7] mesa: Add core mesa support for GL_ARB_shader_draw_parameters

2015-12-15 Thread Kristian Høgsberg Kristensen
--- src/glsl/builtin_variables.cpp | 5 + src/glsl/glsl_parser_extras.cpp | 1 + src/glsl/glsl_parser_extras.h | 2 ++ src/glsl/nir/nir.c | 8 src/glsl/nir/nir_intrinsics.h | 2 ++ src/glsl/nir/shader_enums.h | 20

[Mesa-dev] [PATCH 5/7] i965: Add support for gl_DrawIDARB and enable extension

2015-12-15 Thread Kristian Høgsberg Kristensen
We have to break open a new vec4 for gl_DrawIDARB. We've used up all space in the vec4 we use for SGVS and gl_DrawIDARB has to come from its own separate vertex buffer anyway. This is because we point the vb for base vertex and base instance into the draw parameter BO for indirect draw calls, but

Re: [Mesa-dev] [PATCH 13/15] i965/fs: Add support for MOV_INDIRECT on pre-Broadwell hardware

2015-12-15 Thread Abdiel Janulgue
On 12/10/2015 06:23 AM, Jason Ekstrand wrote: > While we're at it, we also add support for the possibility that the > indirect is, in fact, a constant. This shouldn't happen in the common case > (if it does, that means NIR failed to constant-fold something), but it's > possible so we should hand

[Mesa-dev] [Bug 91724] GL/gl_mangle.h misses symbols from GLES/gl.h

2015-12-15 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=91724 --- Comment #4 from Frederic Devernay --- I updated the gist for the newest Mesa release: https://gist.github.com/devernay/71f3d7661d910e6494a9 Note that, despite what Emil said in http://lists.freedesktop.org/archives/mesa-dev/2014-December/072

Re: [Mesa-dev] [PATCH v2] mesa: fix interface matching done in validate_io

2015-12-15 Thread Timothy Arceri
On Tue, 2015-12-15 at 07:58 +0200, Tapani Pälli wrote: > On 12/15/2015 03:31 AM, Timothy Arceri wrote: > > On Mon, 2015-12-14 at 10:29 +0200, Tapani Pälli wrote: > > > Patch makes following changes for interface matching: > > > > > > - do not try to match builtin variables > > > - handle s

Re: [Mesa-dev] [PATCH] clover: Fix build against LLVM 3.8 SVN >= r255078

2015-12-15 Thread Michel Dänzer
On 15.12.2015 09:17, Ilia Mirkin wrote: > On Wed, Dec 9, 2015 at 5:30 AM, Francisco Jerez wrote: >> Michel Dänzer writes: >> >>> From: Michel Dänzer >>> >>> Signed-off-by: Michel Dänzer >> >> Looks OK to me, >> Reviewed-by: Francisco Jerez >> >>> --- >>> src/gallium/state_trackers/clover/llvm

Re: [Mesa-dev] [PATCH 6/8] st/va: remove fence handling

2015-12-15 Thread Julien Isorce
Hi Christian, I tried your v2. I had to apply attached change on top of your patch. (the one in buffer.c to avoid crashing, the one postproc.c otherwise same behavior as the v1 of this patch). Note that I export the RGB-like surface (the one that vpp output), not the NV12 one that come from the d

Re: [Mesa-dev] [PATCH 6/8] st/va: remove fence handling

2015-12-15 Thread Julien Isorce
And the attachment :) On 15 December 2015 at 09:06, Julien Isorce wrote: > Hi Christian, > > I tried your v2. > > I had to apply attached change on top of your patch. (the one in buffer.c > to avoid crashing, the one postproc.c otherwise same behavior as the v1 of > this patch). Note that I expo

Re: [Mesa-dev] [PATCH 6/7] nir: Teach nir_opt_algebraic about adding and subtracting the same thing

2015-12-15 Thread Eduardo Lima Mitev
On 12/15/2015 09:28 AM, Kristian Høgsberg Kristensen wrote: > This optimizes a + b - b to just a. Modest shader-db results (BDW): > > total instructions in shared programs: 7842452 -> 7841862 (-0.01%) > instructions in affected programs: 61938 -> 61348 (-0.95%) > total loops in shared pr

Re: [Mesa-dev] [PATCH v2 2/3] nvc0: check return value of nvc0_program_validate()

2015-12-15 Thread Pierre Moreau
On 12:01 PM - Dec 14 2015, Ilia Mirkin wrote: > On Mon, Dec 14, 2015 at 11:59 AM, Pierre Moreau wrote: > > On 11:56 AM - Dec 14 2015, Ilia Mirkin wrote: > >> No, gp->code_size is set by the validation. You need to put that last. > > > > IIRC, you can't assume in which order the compiler will decid

Re: [Mesa-dev] [PATCH 6/8] st/va: remove fence handling

2015-12-15 Thread Christian König
Are you sure the flush after calling the compositor is really necessary? That clearly looks odd, but if it works I'm fine with keeping that for now. Regards, Christian. On 15.12.2015 10:06, Julien Isorce wrote: And the attachment :) On 15 December 2015 at 09:06, Julien Isorce

Re: [Mesa-dev] [Mesa-stable] [PATCH] clover: Fix build against LLVM 3.8 SVN >= r255078

2015-12-15 Thread Emil Velikov
On 15 December 2015 at 09:04, Michel Dänzer wrote: > On 15.12.2015 09:17, Ilia Mirkin wrote: >> On Wed, Dec 9, 2015 at 5:30 AM, Francisco Jerez >> wrote: >>> Michel Dänzer writes: >>> From: Michel Dänzer Signed-off-by: Michel Dänzer >>> >>> Looks OK to me, >>> Reviewed-by: Fran

[Mesa-dev] [PATCH] configura.ac: fix test for SSE4.1 assembler support

2015-12-15 Thread Oded Gabbay
This patch modifies the SSE4.1 test in configure.ac to use a global variable to initialize vector variables. In addition, we now return the value of the computation instead of 0. This is done so gcc 4.9 (and lower) won't optimize the SSE4.1 assembly instructions (when using -O1 and higher), becaus

Re: [Mesa-dev] [PATCH 2/8] st/va: cleanup filter color standard handling

2015-12-15 Thread Emil Velikov
On 11 December 2015 at 12:33, Christian König wrote: > From: Christian König > > Signed-off-by: Christian König > --- > src/gallium/state_trackers/va/surface.c | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git a/src/gallium/state_trackers/va/surface.c > b/src/galli

Re: [Mesa-dev] [PATCH 4/8] st/va: fix unused variable warning

2015-12-15 Thread Emil Velikov
On 11 December 2015 at 12:33, Christian König wrote: > From: Christian König > > Signed-off-by: Christian König > --- > src/gallium/state_trackers/va/picture.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/src/gallium/state_trackers/va/picture.c > b/src/gallium/state_trackers/va/pict

Re: [Mesa-dev] [PATCH 5/8] st/va: handle default post process regions

2015-12-15 Thread Emil Velikov
On 11 December 2015 at 12:33, Christian König wrote: > From: Christian König > > Avoid referencing NULL pointers. > Lacking any prior knowledge of the sequential patches, I'm afraid this commit message doesn't make any sense. How about "Will be used in the follow up patches" or anything alike ?

Re: [Mesa-dev] [PATCH 7/8] st/va: add NV12 -> NV12 post processing

2015-12-15 Thread Emil Velikov
On 11 December 2015 at 12:33, Christian König wrote: > +static void vlVaBoxAdjust(struct pipe_video_buffer *buf, unsigned idx, > + struct pipe_box *box) > +{ > + if (buf->interlaced) { > + box->y /= 2; > + box->height /= 2; > + } > + if (idx > buf->interla

Re: [Mesa-dev] [PATCH 2/8] st/va: cleanup filter color standard handling

2015-12-15 Thread Christian König
On 15.12.2015 11:06, Emil Velikov wrote: On 11 December 2015 at 12:33, Christian König wrote: From: Christian König Signed-off-by: Christian König --- src/gallium/state_trackers/va/surface.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gallium/state_trac

Re: [Mesa-dev] [PATCH 8/8] st/va: add BOB/WEAVE deinterlacing

2015-12-15 Thread Emil Velikov
On 11 December 2015 at 12:33, Christian König wrote: > From: Christian König > > Tested with MPV. > Since this patch does not add WEAVE support (since it's used by the state tracker by default) can we add a small note about it. Any shape or form will be great. > Signed-off-by: Christian König >

Re: [Mesa-dev] [PATCH 4/8] st/va: fix unused variable warning

2015-12-15 Thread Christian König
On 15.12.2015 11:08, Emil Velikov wrote: On 11 December 2015 at 12:33, Christian König wrote: From: Christian König Signed-off-by: Christian König --- src/gallium/state_trackers/va/picture.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/gallium/state_trackers/va/picture.c b/src/

Re: [Mesa-dev] [PATCH 5/8] st/va: handle default post process regions

2015-12-15 Thread Christian König
On 15.12.2015 11:11, Emil Velikov wrote: On 11 December 2015 at 12:33, Christian König wrote: From: Christian König Avoid referencing NULL pointers. Lacking any prior knowledge of the sequential patches, I'm afraid this commit message doesn't make any sense. How about "Will be used in the f

Re: [Mesa-dev] [PATCH v2] mesa: fix interface matching done in validate_io

2015-12-15 Thread Tapani Pälli
On 12/15/2015 10:56 AM, Timothy Arceri wrote: On Tue, 2015-12-15 at 07:58 +0200, Tapani Pälli wrote: On 12/15/2015 03:31 AM, Timothy Arceri wrote: On Mon, 2015-12-14 at 10:29 +0200, Tapani Pälli wrote: Patch makes following changes for interface matching: - do not try to match builtin va

Re: [Mesa-dev] [PATCH 5/8] st/va: handle default post process regions

2015-12-15 Thread Emil Velikov
On 15 December 2015 at 10:30, Christian König wrote: > On 15.12.2015 11:11, Emil Velikov wrote: >> >> On 11 December 2015 at 12:33, Christian König >> wrote: >>> >>> From: Christian König >>> >>> Avoid referencing NULL pointers. >>> >> Lacking any prior knowledge of the sequential patches, I'm a

Re: [Mesa-dev] [PATCH v2] mesa: fix interface matching done in validate_io

2015-12-15 Thread Timothy Arceri
On Tue, 2015-12-15 at 12:51 +0200, Tapani Pälli wrote: > On 12/15/2015 10:56 AM, Timothy Arceri wrote: > > On Tue, 2015-12-15 at 07:58 +0200, Tapani Pälli wrote: > > > On 12/15/2015 03:31 AM, Timothy Arceri wrote: > > > > On Mon, 2015-12-14 at 10:29 +0200, Tapani Pälli wrote: > > > > > Patch makes

[Mesa-dev] [PATCH 2/3] i965/fs: do not disable the FS unit in the presence of shader storage

2015-12-15 Thread Iago Toral Quiroga
We want to make sure that the driver does not disable the FS unit if the shader code only has SSBO writes (i.e. no color or depth output). We could go a step further and check if the shader storage is actually used for writing, but does not seem worth the trouble. Also, we do the same thing for at

[Mesa-dev] [PATCH 3/3] i965/wm: use proper API buffer size for the surfaces.

2015-12-15 Thread Iago Toral Quiroga
From: Samuel Iglesias Gonsálvez Commit 5bb5eeea fix a bug indicating that the surfaces should have the API buffer size. Hovewer it picked the wrong value. This patch adds a new variable, which takes into account glBindBufferRange() values. Fixes the following regressions: ES31-CTS.shader_storag

[Mesa-dev] [PATCH 1/3] mesa: Add helper to check if the active fragment shader has shader storage

2015-12-15 Thread Iago Toral Quiroga
Some drivers can disable the FS unit if there is nothing in the shader code that writes to an output (i.e. color, depth, etc). For drivers that check for these things, this helper function is useful to avoid that optimization in the case that the shader has shader storage space assigned (since it c

[Mesa-dev] [PATCH] i965/gen8/cs: fix constant push buffer

2015-12-15 Thread Iago Toral Quiroga
Page 502 of the Command Reference Broadwell PRM says that CURBE Total Data Length must be 64-bit aligned. Fixes the following CTS tests: ES31-CTS.shader_storage_buffer_object.basic-atomic-case1-cs ES31-CTS.shader_storage_buffer_object.basic-operations-case1-cs ES31-CTS.shader_storage_buffer_object

Re: [Mesa-dev] [PATCH 1/3] mesa: Add helper to check if the active fragment shader has shader storage

2015-12-15 Thread Tapani Pälli
Yep, I remember when and why this was done for atomic counters. Patches 1 and 2 are Reviewed-by: Tapani Pälli On 12/15/2015 01:51 PM, Iago Toral Quiroga wrote: Some drivers can disable the FS unit if there is nothing in the shader code that writes to an output (i.e. color, depth, etc). For dri

Re: [Mesa-dev] [PATCH] mesa: remove validation of shaders that should be done elsewhere

2015-12-15 Thread Tapani Pälli
On 12/15/2015 01:25 AM, Timothy Arceri wrote: On Wed, 2015-12-09 at 00:17 +1100, Timothy Arceri wrote: In core profile even if re-linking fails rendering shouldn't fail as the previous succesfully linked program will still be available. It also shouldn't be possible to have an unlinked program a

Re: [Mesa-dev] [PATCH] i965/gen8/cs: fix constant push buffer

2015-12-15 Thread Lofstedt, Marta
Thanks Iago! This patch does not only fix the ssbo test mentioned below, but a lot of other GLES 3.1 CTS tests. > -Original Message- > From: Iago Toral Quiroga [mailto:ito...@igalia.com] > Sent: Tuesday, December 15, 2015 12:55 PM > To: mesa-dev@lists.freedesktop.org > Cc: Lofstedt, Mart

[Mesa-dev] [OT] some contribution statistics

2015-12-15 Thread Giuseppe Bilotta
Hello all, when Steam first announced they'd give all present and future games free to all Mesa contributors with at least 25 commits[1], I was curious to see how many people would be affected by this choice, so I ran some statistics on the number of committers (and contributions by committer) on

[Mesa-dev] [PATCH v4 0/1] i965: add opportunistic behaviour to opt_vector_float()

2015-12-15 Thread Juan A. Suarez Romero
While working on related issue, found out that previous patch (and original version) were applying incorrectly opt_vector_float in some cases. Specifically, for this piece of code: cmp.nz.f0.0 null:F, vgrf6.xyzz:F, vgrf17.xyzz:F mov vgrf2.0.x:D, 0D (+f0.0.any4h) mov vgrf2.0.x:D, -1D mov vgrf2.0.y

[Mesa-dev] [PATCH v4 1/1] i965: add opportunistic behaviour to opt_vector_float()

2015-12-15 Thread Juan A. Suarez Romero
opt_vector_float() transforms several scalar MOV operations to a single vectorial MOV. This is done when those MOV covers all the components of the destination register. So something like: mov vgrf3.0.xy:D, 0D mov vgrf3.0.w:D, 1065353216D mov vgrf3.0.z:D, 0D is transformed in: mov vgrf3.0:F, [0

[Mesa-dev] Mesa 11.1.0

2015-12-15 Thread Emil Velikov
Hello all, Mesa 11.1.0 is now available. I would like to thank all the the developers, testers and everyone for helping shape this release. Here are some of the highlights: - New hardware enablement/support - a305, freedreno - stoney, radeonsi - New drivers - virgl gallium driver for the

Re: [Mesa-dev] [PATCH 2/3] i965/fs: do not disable the FS unit in the presence of shader storage

2015-12-15 Thread Jason Ekstrand
On Dec 15, 2015 3:52 AM, "Iago Toral Quiroga" wrote: > > We want to make sure that the driver does not disable the FS unit if > the shader code only has SSBO writes (i.e. no color or depth output). > > We could go a step further and check if the shader storage is actually > used for writing, but d

Re: [Mesa-dev] [PATCH] draw: handle edge flags in llvm path

2015-12-15 Thread Brian Paul
On 12/14/2015 08:38 PM, srol...@vmware.com wrote: From: Roland Scheidegger We just ignored them altogether. While this feature is rather old-fashioned supporting it is actually rather trivial. This fixes the associated piglit tests (2 gl-1.0-edgeflag, 2 gl-2.0-edgeflag and all (7) of point-vert

Re: [Mesa-dev] [PATCH] draw: handle edge flags in llvm path

2015-12-15 Thread Roland Scheidegger
Am 15.12.2015 um 17:25 schrieb Brian Paul: > On 12/14/2015 08:38 PM, srol...@vmware.com wrote: >> From: Roland Scheidegger >> >> We just ignored them altogether. While this feature is rather >> old-fashioned >> supporting it is actually rather trivial. >> This fixes the associated piglit tests (2

[Mesa-dev] [PATCH] draw: handle edge flags in llvm path

2015-12-15 Thread sroland
From: Roland Scheidegger We just ignored them altogether. While this feature is rather old-fashioned supporting it is actually rather trivial. This fixes the associated piglit tests (2 gl-1.0-edgeflag, 2 gl-2.0-edgeflag and all (7) of point-vertex-id). v2: comment fixes, and make the use of the

[Mesa-dev] [Bug 92570] 10 bit h264 OMX UVD decode outputs NV12

2015-12-15 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=92570 --- Comment #3 from Andy Furniss --- (In reply to Andy Furniss from comment #2) > If so why not output nv16 or something else 10 bit? lol at me re-reading this and remembering that nv16 is 8 bit 422. -- You are receiving this mail because: Yo

Re: [Mesa-dev] [PATCH 2/3] i965/fs: do not disable the FS unit in the presence of shader storage

2015-12-15 Thread Jason Ekstrand
On Tue, Dec 15, 2015 at 9:30 AM, Francisco Jerez wrote: > Jason Ekstrand writes: > >> On Dec 15, 2015 3:52 AM, "Iago Toral Quiroga" wrote: >>> >>> We want to make sure that the driver does not disable the FS unit if >>> the shader code only has SSBO writes (i.e. no color or depth output). >>> >>

Re: [Mesa-dev] [PATCH 1/8] nir: Silence missing field initializer warnings for nir_src

2015-12-15 Thread Ian Romanick
On 12/14/2015 07:36 PM, Jason Ekstrand wrote: > On Mon, Dec 14, 2015 at 5:12 PM, Ian Romanick wrote: >> On 12/14/2015 04:39 PM, Ilia Mirkin wrote: >>> On Mon, Dec 14, 2015 at 7:28 PM, Ian Romanick wrote: On 12/14/2015 03:38 PM, Ilia Mirkin wrote: > It's a pretty standard feature of compi

Re: [Mesa-dev] [PATCH] i965/gen8/cs: fix constant push buffer

2015-12-15 Thread Jordan Justen
Ah! I had just also discovered this issue yesterday in some related work but I didn't get the chance to try the CTS yet! :) For the subject I had: "Gen 8 requires 64 byte alignment for push constant data" On 2015-12-15 03:55:15, Iago Toral Quiroga wrote: > Page 502 of the Command Reference Broadw

Re: [Mesa-dev] [PATCH 2/3] i965/fs: do not disable the FS unit in the presence of shader storage

2015-12-15 Thread Francisco Jerez
Jason Ekstrand writes: > On Dec 15, 2015 3:52 AM, "Iago Toral Quiroga" wrote: >> >> We want to make sure that the driver does not disable the FS unit if >> the shader code only has SSBO writes (i.e. no color or depth output). >> >> We could go a step further and check if the shader storage is ac

Re: [Mesa-dev] [PATCH] draw: handle edge flags in llvm path

2015-12-15 Thread Brian Paul
Reviewed-by: Brian Paul On 12/15/2015 10:06 AM, srol...@vmware.com wrote: From: Roland Scheidegger We just ignored them altogether. While this feature is rather old-fashioned supporting it is actually rather trivial. This fixes the associated piglit tests (2 gl-1.0-edgeflag, 2 gl-2.0-edgefl

Re: [Mesa-dev] [Libva] [PATCH] st/va: retrieve size from the temporary img variable

2015-12-15 Thread Julien Isorce
+ mesa-dev of course :) Thx Sean On 15 December 2015 at 17:46, Sean V Kelley wrote: > > > On Dec 15, 2015, at 1:01 AM, Julien Isorce > wrote: > > > > "image" is not ready yet since it will be set at > > the end of the function by: *image = *img; > > > > Signed-off-by: Julien Isorce > > --- >

Re: [Mesa-dev] [PATCH 3/7] i965: Assert that SYSTEM_VALUE_VERTEX_ID gets lowered

2015-12-15 Thread Anuj Phogat
On Tue, Dec 15, 2015 at 12:28 AM, Kristian Høgsberg Kristensen wrote: > fs_visitor::emit_vs_system_value() looks like it's trying to handle > SYSTEM_VALUE_VERTEX_ID, but we should never see that value in the > backend. > --- > src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 1 + > 1 file changed,

Re: [Mesa-dev] [PATCH 2/7] mesa: Add core mesa support for GL_ARB_shader_draw_parameters

2015-12-15 Thread Anuj Phogat
On Tue, Dec 15, 2015 at 12:28 AM, Kristian Høgsberg Kristensen wrote: > --- > src/glsl/builtin_variables.cpp | 5 + > src/glsl/glsl_parser_extras.cpp | 1 + > src/glsl/glsl_parser_extras.h | 2 ++ > src/glsl/nir/nir.c | 8 > src/glsl/nir/nir_intrin

Re: [Mesa-dev] [PATCH 1/7] mesa/vbo: Add draw_id field to struct _mesa_prim

2015-12-15 Thread Anuj Phogat
On Tue, Dec 15, 2015 at 12:28 AM, Kristian Høgsberg Kristensen wrote: > The drivers will need this for passing in gl_DrawIDARB. For indirect > multidraw calls, we get the prim array and prim[i].draw_id == i and is > redundant. But for non-indirect calls, we get one primitive at a time > and need t

Re: [Mesa-dev] [PATCH 4/7] i965: Add support for gl_BaseVertexARB and gl_BaseInstanceARB

2015-12-15 Thread Anuj Phogat
On Tue, Dec 15, 2015 at 12:28 AM, Kristian Høgsberg Kristensen wrote: > We already have gl_BaseVertexARB in the .x component of the SGVS vec4 > and plug gl_BaseInstanceARB into the last free component (.y). > --- > src/mesa/drivers/dri/i965/brw_compiler.h | 2 ++ > src/mesa/drivers/dri/

Re: [Mesa-dev] [PATCH 1/3] nir/lower_system_values: Stop supporting non-SSA

2015-12-15 Thread Eric Anholt
Jason Ekstrand writes: > The one user of this (i965) only ever calls it while in SSA form. This series is: Reviewed-by: Eric Anholt signature.asc Description: PGP signature ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freed

Re: [Mesa-dev] [PATCH 1/3] nir/lower_system_values: Stop supporting non-SSA

2015-12-15 Thread Jason Ekstrand
On Tue, Dec 15, 2015 at 12:26 PM, Eric Anholt wrote: > Jason Ekstrand writes: > >> The one user of this (i965) only ever calls it while in SSA form. > > This series is: > > Reviewed-by: Eric Anholt Thanks! Did you happen to run it on something that actually uses clip plane lowering? I'd like

Re: [Mesa-dev] [PATCH] mesa: remove validation of shaders that should be done elsewhere

2015-12-15 Thread Timothy Arceri
On Tue, 2015-12-15 at 14:32 +0200, Tapani Pälli wrote: > On 12/15/2015 01:25 AM, Timothy Arceri wrote: > > On Wed, 2015-12-09 at 00:17 +1100, Timothy Arceri wrote: > > > In core profile even if re-linking fails rendering shouldn't fail > > > as > > > the > > > previous succesfully linked program wi

Re: [Mesa-dev] [OT] some contribution statistics

2015-12-15 Thread Kenneth Graunke
On Tuesday, December 15, 2015 02:23:07 PM Giuseppe Bilotta wrote: > The only problem with these numbers is actually the lack of a .mailmap > to normalize contributor name/emails, which obviously skews the > results a little bit towards the lower end. I don't suppose someone > has a .mailmap for Mes

Re: [Mesa-dev] [OT] some contribution statistics

2015-12-15 Thread Nicolai Hähnle
On 15.12.2015 16:22, Kenneth Graunke wrote: On Tuesday, December 15, 2015 02:23:07 PM Giuseppe Bilotta wrote: The only problem with these numbers is actually the lack of a .mailmap to normalize contributor name/emails, which obviously skews the results a little bit towards the lower end. I don't

Re: [Mesa-dev] [OT] some contribution statistics

2015-12-15 Thread Giuseppe Bilotta
On Tue, Dec 15, 2015 at 10:22 PM, Kenneth Graunke wrote: > On Tuesday, December 15, 2015 02:23:07 PM Giuseppe Bilotta wrote: >> The only problem with these numbers is actually the lack of a .mailmap >> to normalize contributor name/emails, which obviously skews the >> results a little bit towards

[Mesa-dev] [PATCH] Add .mailmap

2015-12-15 Thread Giuseppe Bilotta
This adds a first tentative .mailmap file, to canonicize contributor name/emails in shortlogs and other statistical endeavours. There's a couple of root and richard entries which I don't know who they belong to, and hopefully not too many overeager merges. Signed-off-by: Giuseppe Bilotta --- .m

Re: [Mesa-dev] [PATCH 1/3] nir/lower_system_values: Stop supporting non-SSA

2015-12-15 Thread Eric Anholt
Jason Ekstrand writes: > On Tue, Dec 15, 2015 at 12:26 PM, Eric Anholt wrote: >> Jason Ekstrand writes: >> >>> The one user of this (i965) only ever calls it while in SSA form. >> >> This series is: >> >> Reviewed-by: Eric Anholt > > Thanks! > > Did you happen to run it on something that actua

Re: [Mesa-dev] [PATCH 2/7] mesa: Add core mesa support for GL_ARB_shader_draw_parameters

2015-12-15 Thread Ian Romanick
On 12/15/2015 12:28 AM, Kristian Høgsberg Kristensen wrote: > --- > src/glsl/builtin_variables.cpp | 5 + > src/glsl/glsl_parser_extras.cpp | 1 + > src/glsl/glsl_parser_extras.h | 2 ++ > src/glsl/nir/nir.c | 8 > src/glsl/nir/nir_intrinsics.h

Re: [Mesa-dev] [PATCH 3/7] i965: Assert that SYSTEM_VALUE_VERTEX_ID gets lowered

2015-12-15 Thread Ian Romanick
On 12/15/2015 12:28 AM, Kristian Høgsberg Kristensen wrote: > fs_visitor::emit_vs_system_value() looks like it's trying to handle > SYSTEM_VALUE_VERTEX_ID, but we should never see that value in the > backend. > --- > src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 1 + > 1 file changed, 1 insertion

[Mesa-dev] [PATCH] ttn: Use the new nir_load_system_value helper

2015-12-15 Thread Jason Ekstrand
Only compile-tested. Cc: Eric Anholt --- src/gallium/auxiliary/nir/tgsi_to_nir.c | 10 +- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/gallium/auxiliary/nir/tgsi_to_nir.c b/src/gallium/auxiliary/nir/tgsi_to_nir.c index 5def6d3..122e87b 100644 --- a/src/gallium/auxili

Re: [Mesa-dev] [PATCH 4/7] i965: Add support for gl_BaseVertexARB and gl_BaseInstanceARB

2015-12-15 Thread Ian Romanick
On 12/15/2015 11:48 AM, Anuj Phogat wrote: > On Tue, Dec 15, 2015 at 12:28 AM, Kristian Høgsberg Kristensen > wrote: >> We already have gl_BaseVertexARB in the .x component of the SGVS vec4 >> and plug gl_BaseInstanceARB into the last free component (.y). >> --- >> src/mesa/drivers/dri/i965/brw_c

Re: [Mesa-dev] [PATCH 4/7] i965: Add support for gl_BaseVertexARB and gl_BaseInstanceARB

2015-12-15 Thread Ian Romanick
This patch is really doing two different things. It changes the existing SYSTEM_VALUE_BASE_VERTEX to be independent from SYSTEM_VALUE_VERTEX_ID_ZERO. It also adds SYSTEM_VALUE_BASE_INSTANCE support. I was going to let that go, but because the two things happened in one patch, I overlooked the ex

Re: [Mesa-dev] [PATCH 5/7] i965: Add support for gl_DrawIDARB and enable extension

2015-12-15 Thread Ian Romanick
On 12/15/2015 12:28 AM, Kristian Høgsberg Kristensen wrote: > We have to break open a new vec4 for gl_DrawIDARB. We've used up all > space in the vec4 we use for SGVS and gl_DrawIDARB has to come from its > own separate vertex buffer anyway. This is because we point the vb for > base vertex and ba

Re: [Mesa-dev] [PATCH 6/7] nir: Teach nir_opt_algebraic about adding and subtracting the same thing

2015-12-15 Thread Ian Romanick
On 12/15/2015 12:28 AM, Kristian Høgsberg Kristensen wrote: > This optimizes a + b - b to just a. Modest shader-db results (BDW): > > total instructions in shared programs: 7842452 -> 7841862 (-0.01%) > instructions in affected programs: 61938 -> 61348 (-0.95%) > total loops in shared pr

Re: [Mesa-dev] [PATCH 7/7] i965: Reduce vertex state reemission

2015-12-15 Thread Ian Romanick
On 12/15/2015 12:28 AM, Kristian Høgsberg Kristensen wrote: > We can inspect VS prog_data for iterations i > 0, and only flag > BRW_NEW_VERTICES when one of our system values change. > > This change also flags BRW_NEW_VERTICES in one case we were missing > before: if we're doing an indirect draw,

[Mesa-dev] [PATCH 10/11] [RFC] mesa: optimize out the realloc from glCopyTexImagexD()

2015-12-15 Thread Miklós Máté
Apitrace showed this call to be 5ms (9 times per frame), but in reality it's about 500us. This shortcut makes it 20us. --- src/mesa/main/teximage.c | 29 + 1 file changed, 29 insertions(+) diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index ab60a2f..

[Mesa-dev] [PATCH 09/11] swrast: move two global defines to the only place where they are used

2015-12-15 Thread Miklós Máté
--- src/mesa/main/mtypes.h| 2 -- src/mesa/swrast/s_atifragshader.c | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index 5c71ac4..99e7912 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -2278,8

[Mesa-dev] [PATCH 00/11] GL_ATI_fragment_shader support for Gallium

2015-12-15 Thread Miklós Máté
Hi, This series aims to improve the looks of Star Wars: Knights of the Old Republic (via Wine), but features some additional cleanup as well. The main component of the series is the implementation of GL_ATI_fragment_shader for all Gallium drivers (though I could only test it with radeonsi, llvm

[Mesa-dev] [PATCH 11/11] program: Remove extra reference_program()

2015-12-15 Thread Miklós Máté
It was already done in get_mesa_program() --- src/mesa/program/ir_to_mesa.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/mesa/program/ir_to_mesa.cpp b/src/mesa/program/ir_to_mesa.cpp index 8f58f3e..a28cf97 100644 --- a/src/mesa/program/ir_to_mesa.cpp +++ b/src/mesa/program/ir_to_mesa

[Mesa-dev] [PATCH 02/11] mesa: optionally associate a gl_program to ati_fragment_shader

2015-12-15 Thread Miklós Máté
the state tracker will use it --- src/mesa/drivers/common/driverfuncs.c | 3 +++ src/mesa/main/atifragshader.c | 13 - src/mesa/main/dd.h| 6 +- src/mesa/main/mtypes.h| 1 + src/mesa/main/state.c | 14 +- 5

[Mesa-dev] [PATCH 01/11] mesa: Don't leak ATIfs instructions in DeleteFragmentShader

2015-12-15 Thread Miklós Máté
--- src/mesa/main/atifragshader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/main/atifragshader.c b/src/mesa/main/atifragshader.c index 935ba05..3ddc51d 100644 --- a/src/mesa/main/atifragshader.c +++ b/src/mesa/main/atifragshader.c @@ -293,7 +293,7 @@ _mesa_Delete

[Mesa-dev] [PATCH 08/11] mesa: improve debug log in atifragshader

2015-12-15 Thread Miklós Máté
--- src/mesa/main/atifragshader.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/mesa/main/atifragshader.c b/src/mesa/main/atifragshader.c index d1c07c5..8b19a35 100644 --- a/src/mesa/main/atifragshader.c +++ b/src/mesa/main/atifragshader.c @@ -349,6 +349,9 @@ _mesa_BeginFragmentShader

[Mesa-dev] [PATCH 04/11] st/mesa: enable GL_ATI_fragment_shader

2015-12-15 Thread Miklós Máté
--- src/mesa/state_tracker/st_extensions.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c index d97dfde..45ceae1 100644 --- a/src/mesa/state_tracker/st_extensions.c +++ b/src/mesa/state_tracker/st_extensions.c @@

[Mesa-dev] [PATCH 06/11] st/mesa: fix handling the fallback texture

2015-12-15 Thread Miklós Máté
--- src/mesa/state_tracker/st_atom_sampler.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mesa/state_tracker/st_atom_sampler.c b/src/mesa/state_tracker/st_atom_sampler.c index 4252c27..7d3d8e7 100644 --- a/src/mesa/state_tracker/st_atom_sampler.c +++ b/src/mesa/sta

mesa-dev@lists.freedesktop.org

2015-12-15 Thread Miklós Máté
this works with radeonsi, but crashes with llvmpipe --- src/mesa/main/context.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c index 888c461..dcaf524 100644 --- a/src/mesa/main/context.c +++ b/src/mesa/main/context.c

[Mesa-dev] [PATCH 03/11] st/mesa: implement GL_ATI_fragment_shader

2015-12-15 Thread Miklós Máté
--- src/mesa/Makefile.sources | 1 + src/mesa/state_tracker/st_atifs_to_tgsi.c | 798 ++ src/mesa/state_tracker/st_atifs_to_tgsi.h | 49 ++ src/mesa/state_tracker/st_atom_constbuf.c | 14 + src/mesa/state_tracker/st_cb_drawpixels.c | 1 + src/mesa/

[Mesa-dev] [PATCH 07/11] program: fix comment about the fog formula

2015-12-15 Thread Miklós Máté
--- src/mesa/program/prog_statevars.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/program/prog_statevars.c b/src/mesa/program/prog_statevars.c index bdb335e..12490d0 100644 --- a/src/mesa/program/prog_statevars.c +++ b/src/mesa/program/prog_statevars.c @@ -474,7 +

[Mesa-dev] [PATCH 3/5] main/version: Don't require ARB_compute_shader for OpenGLES 3.1

2015-12-15 Thread Jordan Justen
The OpenGL ARB_compute_shader extension specfication requires at least 1024 for GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS, whereas OpenGLES 3.1 only required 128. Signed-off-by: Jordan Justen Cc: Ian Romanick Cc: Marta Lofstedt --- src/mesa/main/version.c | 9 ++--- 1 file changed, 6 insertion

[Mesa-dev] [PATCH 0/5] i965: Non-overridden OpenGLES 3.1 context on Gen8+

2015-12-15 Thread Jordan Justen
git://people.freedesktop.org/~jljusten/mesa es31-gen8-v1 With this series, gen8+ should be able to create an OpenGLES 3.1 context without any environment variable overrides. Jordan Justen (5): main: Add MESA_VERBOSE=api for LinkProgram & UseProgram main: Allow compute shaders to be compiled w

[Mesa-dev] [PATCH 5/5] i965/screen: Allow OpenGLES 3.1 for gen8+

2015-12-15 Thread Jordan Justen
OpenGLES 3.1 cannot be enabled for gen 7 (Ivy Bridge, Haswell) since they are still missing ARB_stencil_texturing. Signed-off-by: Jordan Justen Cc: Ian Romanick Cc: Marta Lofstedt --- src/mesa/drivers/dri/i965/intel_screen.c | 5 + 1 file changed, 5 insertions(+) diff --git a/src/mesa/dri

[Mesa-dev] [PATCH 2/5] main: Allow compute shaders to be compiled with OpenGLES 3.1

2015-12-15 Thread Jordan Justen
Previous OpenGLES 3.1 testing had been done when ARB_compute_shader was overridden to enabled. Signed-off-by: Jordan Justen Cc: Marta Lofstedt --- src/mesa/main/shaderapi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c

[Mesa-dev] [PATCH 4/5] i965: Enable compute shaders in more cases for OpenGLES 3.1

2015-12-15 Thread Jordan Justen
Previously we were checking the desktop OpenGL ARB_compute_shader requirements, but for OpenGLES 3.1, the requirements are lower. Signed-off-by: Jordan Justen Cc: Marta Lofstedt --- src/mesa/drivers/dri/i965/brw_context.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/s

[Mesa-dev] [PATCH 1/5] main: Add MESA_VERBOSE=api for LinkProgram & UseProgram

2015-12-15 Thread Jordan Justen
Signed-off-by: Jordan Justen --- src/mesa/main/shaderapi.c | 5 + 1 file changed, 5 insertions(+) diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c index ac40891..a732d83 100644 --- a/src/mesa/main/shaderapi.c +++ b/src/mesa/main/shaderapi.c @@ -1514,6 +1514,8 @@ void GLAPIE

Re: [Mesa-dev] [PATCH 03/11] st/mesa: implement GL_ATI_fragment_shader

2015-12-15 Thread Ilia Mirkin
Hardly a complete review, but a handful of comments: On Tue, Dec 15, 2015 at 6:05 PM, Miklós Máté wrote: > --- > src/mesa/Makefile.sources | 1 + > src/mesa/state_tracker/st_atifs_to_tgsi.c | 798 > ++ > src/mesa/state_tracker/st_atifs_to_tgsi.h |

Re: [Mesa-dev] [PATCH 3/5] main/version: Don't require ARB_compute_shader for OpenGLES 3.1

2015-12-15 Thread Ian Romanick
On 12/15/2015 04:08 PM, Jordan Justen wrote: > The OpenGL ARB_compute_shader extension specfication requires at least > 1024 for GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS, whereas OpenGLES 3.1 > only required 128. Does this mean that extensions->ARB_compute_shader is not set? I'm a little bit nervous

[Mesa-dev] [PATCH] svga: don't use debug code in update_state() in release builds

2015-12-15 Thread Brian Paul
--- src/gallium/drivers/svga/svga_state.c | 4 1 file changed, 4 insertions(+) diff --git a/src/gallium/drivers/svga/svga_state.c b/src/gallium/drivers/svga/svga_state.c index 722b369..4479a27 100644 --- a/src/gallium/drivers/svga/svga_state.c +++ b/src/gallium/drivers/svga/svga_state.c @@

[Mesa-dev] [PATCH 2/2] st/osmesa: add OSMesaCreateContextAttribs() function

2015-12-15 Thread Brian Paul
As with the previous commit, except for gallium. --- src/gallium/state_trackers/osmesa/osmesa.c | 96 +- 1 file changed, 93 insertions(+), 3 deletions(-) diff --git a/src/gallium/state_trackers/osmesa/osmesa.c b/src/gallium/state_trackers/osmesa/osmesa.c index 0f27ba8

[Mesa-dev] [PATCH 1/2] osmesa: add new OSMesaCreateContextAttribs function

2015-12-15 Thread Brian Paul
This allows specifying a GL profile and version so one can get a core- profile context. --- docs/relnotes/11.2.0.html| 2 + include/GL/osmesa.h | 45 - src/mesa/drivers/osmesa/osmesa.c | 104 ++- 3 files changed, 148 inser

Re: [Mesa-dev] [PATCH 03/11] st/mesa: implement GL_ATI_fragment_shader

2015-12-15 Thread Ian Romanick
On 12/15/2015 04:40 PM, Ilia Mirkin wrote: > Hardly a complete review, but a handful of comments: > > On Tue, Dec 15, 2015 at 6:05 PM, Miklós Máté wrote: >> --- >> src/mesa/Makefile.sources | 1 + >> src/mesa/state_tracker/st_atifs_to_tgsi.c | 798 >> ++

Re: [Mesa-dev] [PATCH 4/5] i965: Enable compute shaders in more cases for OpenGLES 3.1

2015-12-15 Thread Ian Romanick
Doesn't this make patch 3 irrelevant? FWIW, I like this better. On 12/15/2015 04:08 PM, Jordan Justen wrote: > Previously we were checking the desktop OpenGL ARB_compute_shader > requirements, but for OpenGLES 3.1, the requirements are lower. > > Signed-off-by: Jordan Justen > Cc: Marta Lofsted

Re: [Mesa-dev] [PATCH 3/5] main/version: Don't require ARB_compute_shader for OpenGLES 3.1

2015-12-15 Thread Jordan Justen
On 2015-12-15 16:50:39, Ian Romanick wrote: > On 12/15/2015 04:08 PM, Jordan Justen wrote: > > The OpenGL ARB_compute_shader extension specfication requires at least > > 1024 for GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS, whereas OpenGLES 3.1 > > only required 128. > > Does this mean that extensions->

  1   2   >