Re: [Mesa-dev] [Nouveau] [RFC PATCH 5/8] nv50: prevent NULL pointer dereference with pipe_query functions

2015-06-22 Thread Michel Dänzer
On 23.06.2015 06:02, Samuel Pitoiset wrote: > > > On 06/22/2015 10:52 PM, Ilia Mirkin wrote: >> If query_create fails, why would any of these functions get called? > > Because the HUD doesn't check if query_create() fails and it calls other > pipe_query functions with NULL pointer instead of a v

Re: [Mesa-dev] [PATCH 03/14] mesa: Fix conditions to test signed, unsigned integer format

2015-06-22 Thread Iago Toral
On Mon, 2015-06-22 at 12:35 -0700, Anuj Phogat wrote: > On Sun, Jun 21, 2015 at 11:25 PM, Iago Toral wrote: > > On Fri, 2015-06-19 at 13:32 -0700, Anuj Phogat wrote: > >> On Thu, Jun 18, 2015 at 11:41 PM, Iago Toral wrote: > >> > On Thu, 2015-06-18 at 09:19 -0700, Anuj Phogat wrote: > >> >> On Th

Re: [Mesa-dev] [PATCH] glsl: binding point is a texture unit, which is a combined space

2015-06-22 Thread Timothy Arceri
This also probably explains why my max binding test for arrays of arrays was failing on the Nvidia blob. Guess I should have looked into that failure a little harder. On Tue, 2015-06-23 at 00:22 -0400, Ilia Mirkin wrote: > This fixes compilation failures in Dota 2 Reborn where a texture unit > bin

Re: [Mesa-dev] [PATCH v2 26/82] glsl: Don't do copy propagation on buffer variables

2015-06-22 Thread Iago Toral
On Mon, 2015-06-22 at 14:28 -0700, Jordan Justen wrote: > 24-26 once again makes me wonder if these optimization *can* be used > with SSBOs based on the same ext spec wording I referenced before: > > "The ability to write to buffer objects creates the potential for > multiple independent shader i

Re: [Mesa-dev] [PATCH] glsl: binding point is a texture unit, which is a combined space

2015-06-22 Thread Timothy Arceri
Looks good to me as well. Reviewed-by: Timothy Arceri Since you already looking around in there did you want to take a look at this patch: http://lists.freedesktop.org/archives/mesa-dev/2015-June/086925.html I submitted it earlier this month but no one seems to keen to review it. On Tue, 2015

[Mesa-dev] dlopen(libglapi) (Re: [PATCH 08/11] confiigure: drop unused variable GBM_BACKEND_DIRS)

2015-06-22 Thread Pekka Paalanen
On Sun, 21 Jun 2015 16:03:09 + Emil Velikov wrote: > On 19/06/15 22:00, Eric Anholt wrote: > > I find 9/10 weird -- if the DRI drivers need libglapi, why aren't they > > just linking libglapi? > > > Short version - currently they don't because of hysterical raisins, once > we move to shared

Re: [Mesa-dev] [PATCH] tgsi: handle indirect sampler arrays. (v2)

2015-06-22 Thread Dave Airlie
On 22 June 2015 at 21:20, Roland Scheidegger wrote: > Should there be some clamping somewhere to prevent crashes due to > out-of-bound unit index? The spec says its undefined, I'm never sure if that means explode in any way whatsoever. Dave. ___ mesa-d

Re: [Mesa-dev] [PATCH 3/4] i965/gen9: Don't use encrypted MOCS

2015-06-22 Thread Kenneth Graunke
On Monday, June 22, 2015 05:24:11 PM Ben Widawsky wrote: > On Thu, Jun 18, 2015 at 03:41:50PM -0700, Kenneth Graunke wrote: > > On Wednesday, June 17, 2015 03:50:13 PM Ben Widawsky wrote: > > > On gen9+ MOCS is an index into a table. It is 7 bits, and AFAICT, bit 0 > > > is for > > > doing encrypt

[Mesa-dev] [Bug 91044] piglit spec/egl_khr_create_context/valid debug flag gles* fail

2015-06-22 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=91044 --- Comment #3 from Boyan Ding --- Found the exact reason why EGL_BAD_MATCH instead of EGL_BAD_ATTRIBUTE is given for unknown flags in OpenGL ES context. src/mesa/drivers/dri/common/dri_util.c gives __DRI_CTX_ERROR_BAD_FLAG when hitting unknown f

[Mesa-dev] [PATCH] glsl: binding point is a texture unit, which is a combined space

2015-06-22 Thread Ilia Mirkin
This fixes compilation failures in Dota 2 Reborn where a texture unit binding point was used that was numerically higher than the max per stage. Signed-off-by: Ilia Mirkin Reviewed-by: Chris Forbes Tested-by: Nick Sarnie Cc: "10.5 10.6" --- src/glsl/ast_to_hir.cpp | 2 +- 1 file changed, 1 in

Re: [Mesa-dev] [PATCH 13/14] st/mesa: set default tessellation levels

2015-06-22 Thread Ilia Mirkin
This needs to be guarded on availability of tessellation. I'm guessing that something ends up setting st.dirty to ~0, and this gets called even when the driver doesn't support tess. Just hit this playing back a trace with llvmpipe but with the tess patches: #1 0x737dcf49 in update_tess (s

Re: [Mesa-dev] [PATCH 13/16] i965/vs: Pass the current set of clip planes through run() and run_vs()

2015-06-22 Thread Chris Forbes
Is fairly unpleasant that the clip plane plumbing needs to be so special in the visitors at all -- but breaking the context dependency is a win. - Chris On Tue, Jun 23, 2015 at 1:07 PM, Jason Ekstrand wrote: > Previously, these were pulled out of the GL context conditionally based on > whether w

Re: [Mesa-dev] [PATCH 14/16] i965/vec4: Turn some _mesa_problem calls into asserts

2015-06-22 Thread Ilia Mirkin
A very dangerous convention, IMO... it turns into infinite loops and other oddness in release builds. Should really just be done when it's really unreachable. (Perhaps that's the case here, dunno.) On Mon, Jun 22, 2015 at 11:21 PM, Chris Forbes wrote: > Recent convention has been to use unreachab

Re: [Mesa-dev] [PATCH 14/16] i965/vec4: Turn some _mesa_problem calls into asserts

2015-06-22 Thread Chris Forbes
Recent convention has been to use unreachable("str") rather than assert(!"str") On Tue, Jun 23, 2015 at 1:07 PM, Jason Ekstrand wrote: > --- > src/mesa/drivers/dri/i965/brw_vec4_vp.cpp | 9 +++-- > 1 file changed, 3 insertions(+), 6 deletions(-) > > diff --git a/src/mesa/drivers/dri/i965/brw

[Mesa-dev] [Bug 91044] piglit spec/egl_khr_create_context/valid debug flag gles* fail

2015-06-22 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=91044 --- Comment #2 from Boyan Ding --- (In reply to Emil Velikov from comment #1) > As Intel is a Khronos member, you should have access to the SVN repo/history > for the exact details. I'd assume that it would be the better option. Sorry if I cause

Re: [Mesa-dev] [PATCH 5/5] i965/gen9: Allocate YF/YS tiled buffer objects

2015-06-22 Thread Anuj Phogat
On Mon, Jun 22, 2015 at 5:13 PM, Ben Widawsky wrote: > On Wed, Jun 10, 2015 at 03:30:50PM -0700, Anuj Phogat wrote: >> In case of I915_TILING_{X,Y} we need to pass tiling format to libdrm >> using drm_intel_bo_alloc_tiled(). But, In case of YF/YS tiled buffers >> libdrm need not know about the til

[Mesa-dev] [PATCH 16/16] i965: Remove the brw_context from the visitors

2015-06-22 Thread Jason Ekstrand
As of this commit, nothing actually needs the brw_context. --- src/mesa/drivers/dri/i965/brw_cs.cpp| 6 -- src/mesa/drivers/dri/i965/brw_fs.cpp| 12 ++-- src/mesa/drivers/dri/i965/brw_fs.h | 2 +- src/mesa/drivers/dri/i965/brw_fs_reg_a

[Mesa-dev] [PATCH 12/16] i965/fs: Add a do_rep_send flag to run_fs

2015-06-22 Thread Jason Ekstrand
Previously, we were pulling it from brw->do_rep_send --- src/mesa/drivers/dri/i965/brw_fs.cpp | 9 + src/mesa/drivers/dri/i965/brw_fs.h | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp inde

[Mesa-dev] [PATCH 15/16] i965/vec4_vs: Add an explicit use_legacy_snorm_formula flag

2015-06-22 Thread Jason Ekstrand
This way we can stop doing is_gles3 checks inside of the compiler. --- src/mesa/drivers/dri/i965/brw_vec4.cpp| 4 +++- src/mesa/drivers/dri/i965/brw_vec4_vs_visitor.cpp | 9 + src/mesa/drivers/dri/i965/brw_vs.h| 5 - 3 files changed, 12 insertions(+), 6 dele

[Mesa-dev] [PATCH 03/16] i965: Plumb compiler debug logging through a function pointer in brw_compiler

2015-06-22 Thread Jason Ekstrand
v2 (Ken): Make shader_debug_log a printf-like function. v3 (Jason): Add a void * to pass the brw_context through --- src/mesa/drivers/dri/i965/brw_blorp_blit_eu.cpp | 3 ++- src/mesa/drivers/dri/i965/brw_cs.cpp | 3 ++- src/mesa/drivers/dri/i965/brw_fs.cpp | 3 ++- s

[Mesa-dev] [PATCH 08/16] i965/fs: Plumb compiler debug logging through brw_compiler

2015-06-22 Thread Jason Ekstrand
--- src/mesa/drivers/dri/i965/brw_fs.cpp | 13 + src/mesa/drivers/dri/i965/brw_shader.cpp | 26 ++ src/mesa/drivers/dri/i965/brw_shader.h | 1 + 3 files changed, 36 insertions(+), 4 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/me

[Mesa-dev] [PATCH 05/16] i965: Move INTEL_DEBUG variable parsing to screen creation time

2015-06-22 Thread Jason Ekstrand
--- src/mesa/drivers/dri/i965/brw_context.c | 10 +- src/mesa/drivers/dri/i965/intel_debug.c | 13 ++--- src/mesa/drivers/dri/i965/intel_debug.h | 4 ++-- src/mesa/drivers/dri/i965/intel_screen.c | 2 ++ 4 files changed, 15 insertions(+), 14 deletions(-) diff --git a/src/mesa

[Mesa-dev] [PATCH 06/16] i965/fs: Make no16 non-variadic

2015-06-22 Thread Jason Ekstrand
We never used the fact that it was variadic anyway. --- src/mesa/drivers/dri/i965/brw_fs.cpp | 14 -- src/mesa/drivers/dri/i965/brw_fs.h | 2 +- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.c

[Mesa-dev] [PATCH 11/16] i965: Pull calls to get_shader_time_index out of the visitor

2015-06-22 Thread Jason Ekstrand
--- src/mesa/drivers/dri/i965/brw_cs.cpp | 8 +++- src/mesa/drivers/dri/i965/brw_fs.cpp | 55 --- src/mesa/drivers/dri/i965/brw_fs.h| 7 ++- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 7 ++- src/mesa/drivers/dri/i965/brw_vec

[Mesa-dev] [PATCH 01/16] i965: Replace some instances of brw->gen with devinfo->gen

2015-06-22 Thread Jason Ekstrand
--- src/mesa/drivers/dri/i965/brw_fs.cpp | 4 ++-- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 8 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp index 5563c5a..ac65202 100644 --- a/src/

[Mesa-dev] [PATCH 13/16] i965/vs: Pass the current set of clip planes through run() and run_vs()

2015-06-22 Thread Jason Ekstrand
Previously, these were pulled out of the GL context conditionally based on whether we were running ff/ARB or a GLSL program. Now, we just pass them in so that the visitor doesn't have to grab them itself. --- src/mesa/drivers/dri/i965/brw_fs.cpp | 4 ++-- src/mesa/drivers/dri/i965/b

[Mesa-dev] [PATCH 10/16] i965: Use a single index per shader for shader_time.

2015-06-22 Thread Jason Ekstrand
Previously, each shader took 3 shader time indices which were potentially at arbirary points in the shader time buffer. Now, each shader gets a single index which refers to 3 consecutive locations in the buffer. This simplifies some of the logic at the cost of having a magic 3 a few places. ---

[Mesa-dev] [PATCH 14/16] i965/vec4: Turn some _mesa_problem calls into asserts

2015-06-22 Thread Jason Ekstrand
--- src/mesa/drivers/dri/i965/brw_vec4_vp.cpp | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_vec4_vp.cpp b/src/mesa/drivers/dri/i965/brw_vec4_vp.cpp index 92d1085..dcbd240 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_vp.cpp +++ b/src/

[Mesa-dev] [PATCH 09/16] i965: Add compiler options to brw_compiler

2015-06-22 Thread Jason Ekstrand
This creates the options at screen cration time and then we just copy them into the context at context creation time. We also move is_scalar to the brw_compiler structure. We also end up manually setting some values that the core would have set by default for us. Fortunately, there are only two

[Mesa-dev] [PATCH 07/16] i965/fs: Do the no16 perf logging directly in fs_visitor::no16()

2015-06-22 Thread Jason Ekstrand
While we're at it, we'll drop the note about 10-20% performance loss. --- src/mesa/drivers/dri/i965/brw_fs.cpp | 13 ++--- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp index a9d9f37..40e2c44 1006

[Mesa-dev] [PATCH 00/16] i965: Finish removing brw_context from the compiler

2015-06-22 Thread Jason Ekstrand
I started working on this project some time ago to remove brw_context from the backend compiler. I got a bunch of refactoring done but eventualy got stuck up on shader_time and some debug logging stuff. I've finally gotten around to finishing it and here it is. Jason Ekstrand (15): i965: Repla

[Mesa-dev] [PATCH 02/16] mesa: Add a va_args variant of _mesa_gl_debug().

2015-06-22 Thread Jason Ekstrand
From: Kenneth Graunke This will be useful for wrapper functions. Signed-off-by: Kenneth Graunke --- src/mesa/main/errors.c | 29 + src/mesa/main/errors.h | 9 + 2 files changed, 30 insertions(+), 8 deletions(-) diff --git a/src/mesa/main/errors.c b/src/mes

[Mesa-dev] [PATCH 04/16] i965: Remove the dependance on brw_context from the generators

2015-06-22 Thread Jason Ekstrand
--- src/mesa/drivers/dri/i965/brw_blorp_blit_eu.cpp | 2 +- src/mesa/drivers/dri/i965/brw_cs.cpp | 2 +- src/mesa/drivers/dri/i965/brw_fs.cpp | 2 +- src/mesa/drivers/dri/i965/brw_fs.h| 4 +++- src/mesa/drivers/dri/i965/brw_fs_generator.cpp| 5 +++--

Re: [Mesa-dev] [PATCH 4/5] i965/gen9: Add XY_FAST_COPY_BLT support to intelEmitCopyBlit()

2015-06-22 Thread Ben Widawsky
On Fri, Jun 19, 2015 at 02:41:50PM -0700, Anuj Phogat wrote: > On Wed, Jun 10, 2015 at 3:34 PM, Anuj Phogat wrote: > > This patch enables using XY_FAST_COPY_BLT only for Yf/Ys tiled buffers. > > It can be later turned on for other tiling patterns (X,Y) too. > > > > V3: Flush in between sequential

Re: [Mesa-dev] [PATCH 3/4] i965/gen9: Don't use encrypted MOCS

2015-06-22 Thread Ben Widawsky
On Thu, Jun 18, 2015 at 03:41:50PM -0700, Kenneth Graunke wrote: > On Wednesday, June 17, 2015 03:50:13 PM Ben Widawsky wrote: > > On gen9+ MOCS is an index into a table. It is 7 bits, and AFAICT, bit 0 is > > for > > doing encrypted reads. > > > > I don't recall how I decided to do this for BXT.

Re: [Mesa-dev] [PATCH 2/5] i965/gen9: Plugin the code for selecting YF/YS tiling on skl+

2015-06-22 Thread Anuj Phogat
On Mon, Jun 22, 2015 at 2:53 PM, Ben Widawsky wrote: > On Wed, Jun 10, 2015 at 03:30:47PM -0700, Anuj Phogat wrote: >> Buffers with Yf/Ys tiling end up using meta upload / download >> paths or the blitter for cases where they used tiled_memcpy paths >> in case of Y tiling. This has exposed some bu

Re: [Mesa-dev] [PATCH 5/5] i965/gen9: Allocate YF/YS tiled buffer objects

2015-06-22 Thread Ben Widawsky
On Wed, Jun 10, 2015 at 03:30:50PM -0700, Anuj Phogat wrote: > In case of I915_TILING_{X,Y} we need to pass tiling format to libdrm > using drm_intel_bo_alloc_tiled(). But, In case of YF/YS tiled buffers > libdrm need not know about the tiling format because these buffers > don't have hardware supp

Re: [Mesa-dev] [PATCH 28/46] glsl: don't lower variable indexing on non-patch tessellation inputs/outputs

2015-06-22 Thread Kenneth Graunke
On Wednesday, June 17, 2015 01:01:24 AM Marek Olšák wrote: > From: Marek Olšák > > There is no way to lower them, because the array sizes are unknown > at compile time. > > Based on a patch from: Fabian Bieler I'm a bit confused by the justification given for this patch. TCS/TES per-vertex in

Re: [Mesa-dev] [PATCH v3 11/18] mesa/macros: add power-of-two assertions for alignment macros

2015-06-22 Thread Brian Paul
On 06/22/2015 05:02 PM, Nanley Chery wrote: From: Nanley Chery ALIGN and ROUND_DOWN_TO both require that the alignment value passed into the macro be a power of two in the comments. Using software assertions verifies this to be the case. v2: use static inline functions instead of gcc-specific

[Mesa-dev] [PATCH v3 13/18] i965: use ALIGN_NPOT for setting ASTC mipmap layouts

2015-06-22 Thread Nanley Chery
From: Nanley Chery ALIGN is changed to ALIGN_NPOT because alignment values are sometimes not powers of two when working with ASTC. Signed-off-by: Nanley Chery --- src/mesa/drivers/dri/i965/brw_tex_layout.c| 12 ++-- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 4 ++-- 2 files c

[Mesa-dev] [PATCH v3 10/18] i965/surface_formats: add support for 2D ASTC surface formats

2015-06-22 Thread Nanley Chery
From: Nanley Chery Intel surface formats default to LDR unless there is hardware support for HDR and the texture is able to be processed in HDR mode. v2: remove extra newlines. v3: follow existing coding style in translate_tex_format(). Signed-off-by: Nanley Chery --- src/mesa/drivers/dri/i96

[Mesa-dev] [PATCH v3 12/18] mesa/macros: move ALIGN_NPOT to macros.h

2015-06-22 Thread Nanley Chery
From: Nanley Chery Aligning with a non-power-of-two number is a general task that can be used in various places. This commit is required for the next one. Signed-off-by: Nanley Chery --- src/mesa/drivers/dri/i965/intel_upload.c | 6 -- src/mesa/main/macros.h | 6 ++ 2

[Mesa-dev] [PATCH v3 08/18] mesa/teximage: return the base internal format of the ASTC formats

2015-06-22 Thread Nanley Chery
From: Nanley Chery This is necesary to initialize the gl_texture_image struct. From the KHR_texture_compression_astc_ldr spec: "Added to Section 3.8.6, Compressed Texture Images Add the tokens specified above to Table 3.16, Compressed Internal Formats. In all cases, the base internal fo

[Mesa-dev] [PATCH v3 16/18] i965: enable ASTC support for Skylake

2015-06-22 Thread Nanley Chery
From: Nanley Chery v2: remove OES ASTC extension reference. Signed-off-by: Nanley Chery --- src/mesa/drivers/dri/i965/intel_extensions.c | 5 + 1 file changed, 5 insertions(+) diff --git a/src/mesa/drivers/dri/i965/intel_extensions.c b/src/mesa/drivers/dri/i965/intel_extensions.c index 3

[Mesa-dev] [PATCH v3 18/18] swrast: add a new macro, FETCH_COMPRESSED

2015-06-22 Thread Nanley Chery
From: Nanley Chery This patch creates a new macro, FETCH_COMPRESSED - similar in nature to the other FETCH_* macros. This reduces repetition in the code that deals with compressed textures. Reviewed-by: Anuj Phogat Signed-off-by: Nanley Chery --- src/mesa/swrast/s_texfetch.c | 239 ---

[Mesa-dev] [PATCH v3 11/18] mesa/macros: add power-of-two assertions for alignment macros

2015-06-22 Thread Nanley Chery
From: Nanley Chery ALIGN and ROUND_DOWN_TO both require that the alignment value passed into the macro be a power of two in the comments. Using software assertions verifies this to be the case. v2: use static inline functions instead of gcc-specific statement expressions. Signed-off-by: Nanley

[Mesa-dev] [PATCH v3 15/18] i965: change the meaning of cpp for compressed textures

2015-06-22 Thread Nanley Chery
From: Nanley Chery An ASTC block takes up 16 bytes for all block width and height configurations. This size is not integrally divisible by all ASTC block widths. Therefore cpp is changed to mean bytes per block if the texture is compressed. Because the original definition was bytes per block div

[Mesa-dev] [PATCH v3 17/18] i965: refactor miptree alignment calculation code

2015-06-22 Thread Nanley Chery
From: Nanley Chery Remove redundant checks and comments by grouping our calculations for align_w and align_h wherever possible. v2: reintroduce brw. don't include functional changes. don't adjust function parameters or create a new function. Signed-off-by: Nanley Chery --- src/mesa/dr

[Mesa-dev] [PATCH v3 14/18] i965: correct mt->align_h for 2D textures on Skylake

2015-06-22 Thread Nanley Chery
From: Nanley Chery In agreement with commit 4ab8d59a23, vertical alignment values are equal to four times the block height on Gen9+. v2: add newlines to separate declarations, statments, and comments. Reviewed-by: Anuj Phogat Reviewed-by: Neil Roberts Signed-off-by: Nanley Chery --- src/mes

[Mesa-dev] [PATCH v3 00/18] Enable support for 2D ASTC (LDR and HDR modes) in SKL

2015-06-22 Thread Nanley Chery
From: Nanley Chery This patch series enables support for the KHR_texture_compression_astc_{ldr,hdr} extensions on Skylake machines. This revision includes developer suggestions and fixes rendering issues on previously untested systems. The sRGB issues were fixed and determined to be unrelated to

[Mesa-dev] [PATCH v3 01/18] mesa/formats: define the 2D ASTC formats

2015-06-22 Thread Nanley Chery
From: Nanley Chery Includes definition of the formats, updates to functions likely to be used, as well as changes necessary for compilation. Reviewed-by: Anuj Phogat Signed-off-by: Nanley Chery --- src/mesa/main/format_info.py | 3 + src/mesa/main/formats.c | 130 ++

[Mesa-dev] [PATCH v3 09/18] mesa/formats: store whether or not a format is sRGB in gl_format_info

2015-06-22 Thread Nanley Chery
From: Nanley Chery v2: remove extra newline. v3: use bool instead of GLboolean. Reviewed-by: Anuj Phogat Signed-off-by: Nanley Chery --- src/mesa/main/format_info.py | 2 ++ src/mesa/main/formats.c | 28 2 files changed, 6 insertions(+), 24 deletions(-) dif

[Mesa-dev] [PATCH v3 02/18] glapi: add support for KHR_texture_compression_astc_ldr

2015-06-22 Thread Nanley Chery
From: Nanley Chery v2: correct the spelling of the sRGB variants. remove spaces around "=" when setting the enum value. Reviewed-by: Anuj Phogat Signed-off-by: Nanley Chery --- .../glapi/gen/KHR_texture_compression_astc.xml | 40 ++ src/mapi/glapi/gen/Makefile.am

[Mesa-dev] [PATCH v3 04/18] mesa: return bool instead of GLboolean in compressedteximage_only_format()

2015-06-22 Thread Nanley Chery
From: Nanley Chery In agreement with the coding style, functions that aren't directly visible to the GL API should prefer the use of bool over GLboolean. Suggested-by: Ian Romanick Signed-off-by: Nanley Chery --- src/mesa/main/teximage.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletion

[Mesa-dev] [PATCH v3 07/18] mesa/texcompress: enable translation between MESA and GL ASTC formats

2015-06-22 Thread Nanley Chery
From: Nanley Chery Reviewed-by: Anuj Phogat Signed-off-by: Nanley Chery --- src/mesa/main/texcompress.c | 114 1 file changed, 114 insertions(+) diff --git a/src/mesa/main/texcompress.c b/src/mesa/main/texcompress.c index 1654fc6..203a065 100644 --

[Mesa-dev] [PATCH v3 06/18] mesa/glformats: recognize ASTC formats as compressed

2015-06-22 Thread Nanley Chery
From: Nanley Chery Reviewed-by: Anuj Phogat Signed-off-by: Nanley Chery --- src/mesa/main/glformats.c | 29 + 1 file changed, 29 insertions(+) diff --git a/src/mesa/main/glformats.c b/src/mesa/main/glformats.c index ac69fab..e7363b5 100644 --- a/src/mesa/main/glfor

[Mesa-dev] [PATCH v3 03/18] mesa: disable online compression for ASTC formats

2015-06-22 Thread Nanley Chery
From: Nanley Chery Reviewed-by: Anuj Phogat Signed-off-by: Nanley Chery --- src/mesa/main/texcompress.c | 22 ++ src/mesa/main/teximage.c| 28 2 files changed, 50 insertions(+) diff --git a/src/mesa/main/texcompress.c b/src/mesa/main/texcom

[Mesa-dev] [PATCH v3 05/18] mesa: add ASTC extensions to the extensions table

2015-06-22 Thread Nanley Chery
From: Nanley Chery v2: alphabetize the extensions. remove OES ASTC extension. Reviewed-by: Anuj Phogat Signed-off-by: Nanley Chery --- src/mesa/main/extensions.c | 2 ++ src/mesa/main/mtypes.h | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/mesa/main/extensions.c b/src/mesa

Re: [Mesa-dev] [PATCH 1/3] i965/cfg: Assert that cur_do/while/if pointers are non-NULL.

2015-06-22 Thread Jordan Justen
Series Reviewed-by: Jordan Justen On 2015-06-22 14:56:06, Matt Turner wrote: > Coverity sees that the functions immediately below the new assertions > dereference these pointers, but is unaware that an ENDIF always follows > an IF, etc. > --- > src/mesa/drivers/dri/i965/brw_cfg.cpp | 2 ++ > 1 f

Re: [Mesa-dev] [PATCH] i965/fs: Don't mess up stride for uniform integer multiplication.

2015-06-22 Thread Kenneth Graunke
On Monday, June 22, 2015 02:58:36 PM Matt Turner wrote: > If the stride is 0, the source is a uniform and we should not modify the > stride. > > Cc: "10.6" > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91047 > --- > src/mesa/drivers/dri/i965/brw_fs.cpp | 20 > 1 f

Re: [Mesa-dev] [RFC] Compatibility between old dri modules and new loaders, and vice verse

2015-06-22 Thread Dave Airlie
On 23 June 2015 at 08:16, Ian Romanick wrote: > On 06/22/2015 11:54 AM, Dave Airlie wrote: >>> >>> As kindly hinted by Marek, currently we do have a wide selection of >>> supported dri <> loader combinations. >>> >>> Although we like to think that things never break, we have to admit >>> that not

Re: [Mesa-dev] [RFC] Compatibility between old dri modules and new loaders, and vice verse

2015-06-22 Thread Ian Romanick
On 06/22/2015 11:54 AM, Dave Airlie wrote: >> >> As kindly hinted by Marek, currently we do have a wide selection of >> supported dri <> loader combinations. >> >> Although we like to think that things never break, we have to admit >> that not many of us test every possible combinations of dri modu

Re: [Mesa-dev] [PATCH] mesa: Delete unused ICEIL().

2015-06-22 Thread Jordan Justen
Reviewed-by: Jordan Justen On 2015-06-22 14:58:27, Matt Turner wrote: > Can't find any uses of it in git history. > --- > Strangely, when it was moved to its current location in commit 27558a1, > it was moved from mmath.h... which seems to have been lost from git's > history. Searching further gi

[Mesa-dev] [PATCH] mesa: Delete unused ICEIL().

2015-06-22 Thread Matt Turner
Can't find any uses of it in git history. --- Strangely, when it was moved to its current location in commit 27558a1, it was moved from mmath.h... which seems to have been lost from git's history. Searching further git log --grep mmath.h shows that various commit messages mention modifying mmath.h

[Mesa-dev] [PATCH] i965/fs: Don't mess up stride for uniform integer multiplication.

2015-06-22 Thread Matt Turner
If the stride is 0, the source is a uniform and we should not modify the stride. Cc: "10.6" Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91047 --- src/mesa/drivers/dri/i965/brw_fs.cpp | 20 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/src/mesa/dri

Re: [Mesa-dev] [PATCH 4/5] i965: Make a helper function intel_miptree_can_use_tr_mode()

2015-06-22 Thread Ben Widawsky
1-4 (with/without changes) are: Reviewed-by: Ben Widawsky On Wed, Jun 10, 2015 at 03:30:49PM -0700, Anuj Phogat wrote: > Signed-off-by: Anuj Phogat > Cc: Ben Widawsky > --- > src/mesa/drivers/dri/i965/brw_tex_layout.c | 30 > +++--- > 1 file changed, 19 insertions(+),

Re: [Mesa-dev] [PATCH 3/5] i965: Make a helper function intel_miptree_release_levels()

2015-06-22 Thread Ben Widawsky
I am shocked this is the only place we do this... On Wed, Jun 10, 2015 at 03:30:48PM -0700, Anuj Phogat wrote: > Signed-off-by: Anuj Phogat > Cc: Ben Widawsky > --- > src/mesa/drivers/dri/i965/brw_tex_layout.c | 17 - > 1 file changed, 12 insertions(+), 5 deletions(-) > > diff

[Mesa-dev] [PATCH 2/3] i965: Assert that the GL primitive isn't out of range.

2015-06-22 Thread Matt Turner
Coverity sees the if (mode >= BRW_PRIM_OFFSET (128)) test and assumes that the else-branch might execute for mode to up 127, which out be out of bounds. --- src/mesa/drivers/dri/i965/brw_draw.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/brw_dra

[Mesa-dev] [PATCH 3/3] i965: Initialize backend_shader::mem_ctx in its constructor.

2015-06-22 Thread Matt Turner
We were initializing it in each subclasses' constructors for some reason. --- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 4 +--- src/mesa/drivers/dri/i965/brw_shader.cpp | 2 ++ src/mesa/drivers/dri/i965/brw_shader.h | 1 + src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp | 3 +--

[Mesa-dev] [PATCH 1/3] i965/cfg: Assert that cur_do/while/if pointers are non-NULL.

2015-06-22 Thread Matt Turner
Coverity sees that the functions immediately below the new assertions dereference these pointers, but is unaware that an ENDIF always follows an IF, etc. --- src/mesa/drivers/dri/i965/brw_cfg.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_cfg.cpp b/src/mes

Re: [Mesa-dev] [PATCH 2/5] i965/gen9: Plugin the code for selecting YF/YS tiling on skl+

2015-06-22 Thread Ben Widawsky
On Wed, Jun 10, 2015 at 03:30:47PM -0700, Anuj Phogat wrote: > Buffers with Yf/Ys tiling end up using meta upload / download > paths or the blitter for cases where they used tiled_memcpy paths > in case of Y tiling. This has exposed some bugs in meta path. To > avoid any piglit regressions on SKL t

Re: [Mesa-dev] [PATCH v2 27/82] mesa: Add new IR node ir_ssbo_store

2015-06-22 Thread Jordan Justen
Reviewed-by: Jordan Justen On 2015-06-03 00:01:17, Iago Toral Quiroga wrote: > Shader storage buffer objects (SSBO) require special handling: when we > detect writes to any channel of a shader buffer variable we need to > emit the corresponding write to memory. We will later add a lowering pass >

Re: [Mesa-dev] [PATCH 2/2] draw/gallivm: add invocation ID support for llvmpipe.

2015-06-22 Thread Roland Scheidegger
For the series: Reviewed-by: Roland Scheidegger Am 22.06.2015 um 06:01 schrieb Dave Airlie: > From: Dave Airlie > > This extends the draw code to add support for invocations. > > Signed-off-by: Dave Airlie > --- > src/gallium/auxiliary/draw/draw_gs.c| 3 ++- > src/gallium/auxili

Re: [Mesa-dev] [PATCH v2 26/82] glsl: Don't do copy propagation on buffer variables

2015-06-22 Thread Jordan Justen
24-26 once again makes me wonder if these optimization *can* be used with SSBOs based on the same ext spec wording I referenced before: "The ability to write to buffer objects creates the potential for multiple independent shader invocations to read and write the same underlying memory. The same

Re: [Mesa-dev] [PATCH] i965: Don't count NIR instructions for shader-db.

2015-06-22 Thread Matt Turner
Reviewed-by: Matt Turner ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

[Mesa-dev] [PATCH] i965: Don't count NIR instructions for shader-db.

2015-06-22 Thread Kenneth Graunke
Matt, Jason, and I haven't found this useful in a long time. Signed-off-by: Kenneth Graunke --- src/mesa/drivers/dri/i965/brw_nir.c | 31 --- 1 file changed, 31 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_nir.c b/src/mesa/drivers/dri/i965/brw_nir.c ind

Re: [Mesa-dev] [Nouveau] [RFC PATCH 5/8] nv50: prevent NULL pointer dereference with pipe_query functions

2015-06-22 Thread Samuel Pitoiset
On 06/22/2015 10:52 PM, Ilia Mirkin wrote: If query_create fails, why would any of these functions get called? Because the HUD doesn't check if query_create() fails and it calls other pipe_query functions with NULL pointer instead of a valid query object. On Mon, Jun 22, 2015 at 4:53 PM,

Re: [Mesa-dev] [Nouveau] [RFC PATCH 5/8] nv50: prevent NULL pointer dereference with pipe_query functions

2015-06-22 Thread Ilia Mirkin
If query_create fails, why would any of these functions get called? On Mon, Jun 22, 2015 at 4:53 PM, Samuel Pitoiset wrote: > This may happen when nv50_query_create() fails to create a new query. > > Signed-off-by: Samuel Pitoiset > --- > src/gallium/drivers/nouveau/nv50/nv50_query.c | 15 +

[Mesa-dev] [RFC PATCH 4/8] nv50: configure the ring buffer for reading back PM counters

2015-06-22 Thread Samuel Pitoiset
To write data at the right offset, the kernel has to know some parameters of this ring buffer, like the number of domains and the maximum number of queries. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nv50/nv50_screen.c | 7 +++ 1 file changed, 7 insertions(+) diff --git

[Mesa-dev] [RFC PATCH 1/8] nouveau: implement the nvif hardware performance counters interface

2015-06-22 Thread Samuel Pitoiset
This commit implements the base interface for hardware performance counters that will be shared between nv50 and nvc0 drivers. TODO: Bump libdrm version of mesa when nvif will be merged. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/Makefile.sources | 2 + src/gallium/driver

[Mesa-dev] [RFC PATCH 0/8] nv50: expose global performance counters

2015-06-22 Thread Samuel Pitoiset
Hello there, This series exposes NVIDIA's global performance counters for Tesla through the Gallium's HUD and the GL_AMD_performance_monitor extension. This adds support for 24 hardware events which have been reverse engineered with PerfKit (Windows) and CUPTI (Linux). These hardware events will

[Mesa-dev] [RFC PATCH 7/8] nv50: expose global performance counters to the HUD

2015-06-22 Thread Samuel Pitoiset
Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nv50/nv50_query.c | 41 ++ src/gallium/drivers/nouveau/nv50/nv50_screen.c | 1 + src/gallium/drivers/nouveau/nv50/nv50_screen.h | 3 ++ 3 files changed, 45 insertions(+) diff --git a/src/gallium/drivers/nou

[Mesa-dev] [RFC PATCH 6/8] nv50: add support for compute/graphics global performance counters

2015-06-22 Thread Samuel Pitoiset
This commit adds support for both compute and graphics global performance counters which have been reverse engineered with CUPTI (Linux) and PerfKit (Windows). Currently, only one query type can be monitored at the same time because the Gallium's HUD doesn't fit pretty well. This will be improved

[Mesa-dev] [RFC PATCH 3/8] nv50: allocate and map a notifier buffer object for PM

2015-06-22 Thread Samuel Pitoiset
This notifier buffer object will be used to read back global performance counters results written by the kernel. For each domain, we will store the handle of the perfdom object, an array of 4 counters and the number of cycles. Like the Gallium's HUD, we keep a list of busy queries in a ring in ord

[Mesa-dev] [RFC PATCH 2/8] nv50: allocate a software object class

2015-06-22 Thread Samuel Pitoiset
This will allow to monitor global performance counters through the command stream of the GPU instead of using ioctls. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nv50/nv50_screen.c | 11 +++ src/gallium/drivers/nouveau/nv50/nv50_screen.h | 1 + src/gallium/drivers/nou

[Mesa-dev] [RFC PATCH 5/8] nv50: prevent NULL pointer dereference with pipe_query functions

2015-06-22 Thread Samuel Pitoiset
This may happen when nv50_query_create() fails to create a new query. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nv50/nv50_query.c | 15 ++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/nv50/nv50_query.c b/src/gallium/

[Mesa-dev] [RFC PATCH 8/8] nv50: enable GL_AMD_performance_monitor

2015-06-22 Thread Samuel Pitoiset
This exposes a group of global performance counters that enables GL_AMD_performance_monitor. All piglit tests are okay. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nv50/nv50_query.c | 35 ++ src/gallium/drivers/nouveau/nv50/nv50_screen.c | 1 + src/ga

Re: [Mesa-dev] [Mesa-stable] [PATCH] egl/x11: Remove duplicate call to dri2_x11_add_configs_for_visuals

2015-06-22 Thread Chad Versace
On Thu 18 Jun 2015, Emil Velikov wrote: > Hi Boyan, > > On 13 June 2015 at 08:33, Boyan Ding wrote: > > The call to dri2_x11_add_configs_for_visuals (previously > > dri2_add_configs_for_visuals) was moved downwards in commit f8c5b8a1, > > but appeared again in its original position after its rena

Re: [Mesa-dev] [PATCH] radeon: Advertise correct GL_SAMPLES_PASSED value.

2015-06-22 Thread Marek Olšák
Reviewed-by: Marek Olšák For Gallium, a new PIPE_CAP or new get_xxx_param function will be needed. Marek On Mon, Jun 22, 2015 at 8:41 PM, Ian Romanick wrote: > From: Ian Romanick > > Commit b765119c changed the default value of all the counter bits to > 64. However, older hardware only has

Re: [Mesa-dev] [PATCH 03/14] mesa: Fix conditions to test signed, unsigned integer format

2015-06-22 Thread Anuj Phogat
On Sun, Jun 21, 2015 at 11:25 PM, Iago Toral wrote: > On Fri, 2015-06-19 at 13:32 -0700, Anuj Phogat wrote: >> On Thu, Jun 18, 2015 at 11:41 PM, Iago Toral wrote: >> > On Thu, 2015-06-18 at 09:19 -0700, Anuj Phogat wrote: >> >> On Thu, Jun 18, 2015 at 7:09 AM, Iago Toral wrote: >> >> > On Tue, 2

Re: [Mesa-dev] Building Mesa/LLVMpipe on Windows

2015-06-22 Thread Jose Fonseca
On 22/06/15 19:40, Florian Link wrote: Hi everyone, I spent some time building Mesa/llvmpipe on Windows and created a Python script that implements all the required steps (downloading/extracting all prerequisites and sources, configuring and building LLVM and Mesa). The script is available at:

Re: [Mesa-dev] [RFC] Compatibility between old dri modules and new loaders, and vice verse

2015-06-22 Thread Dave Airlie
> > As kindly hinted by Marek, currently we do have a wide selection of > supported dri <> loader combinations. > > Although we like to think that things never break, we have to admit > that not many of us test every possible combinations of dri modules > and loaders. With the chances getting small

Re: [Mesa-dev] [PATCH 00/11] glapi fixes - build whole of mesa with

2015-06-22 Thread Emil Velikov
On 22 June 2015 at 15:01, Jose Fonseca wrote: > On 19/06/15 23:09, Emil Velikov wrote: >> >> On 19 June 2015 at 21:26, Jose Fonseca wrote: >>> >>> On 19/06/15 20:56, Emil Velikov wrote: Hi all, A lovely series inspired (more like 'was awaken to send these out') by Pa

Re: [Mesa-dev] [PATCH 11/11] android: egl: do not link against libglapi

2015-06-22 Thread Marek Olšák
Yes, I think we need to support every loader/driver combination, but I'm not sure. Ian, please how much do we care about compatibility between loaders (libGL, libEGL) and DRI drivers? Thanks, Marek On Mon, Jun 22, 2015 at 8:04 PM, Emil Velikov wrote: > Niiice, thank you. For most drivers - gal

[Mesa-dev] [PATCH] radeon: Advertise correct GL_SAMPLES_PASSED value.

2015-06-22 Thread Ian Romanick
From: Ian Romanick Commit b765119c changed the default value of all the counter bits to 64. However, older hardware only has 32 counter bits. This has only been build-tested. We don't have any tests that verify the advertised value against implementation behavior, so I don't know what addition

[Mesa-dev] Building Mesa/LLVMpipe on Windows

2015-06-22 Thread Florian Link
Hi everyone, I spent some time building Mesa/llvmpipe on Windows and created a Python script that implements all the required steps (downloading/extracting all prerequisites and sources, configuring and building LLVM and Mesa). The script is available at: https://github.com/florianlink/MesaOnWin

[Mesa-dev] [RFC] Compatibility between old dri modules and new loaders, and vice verse

2015-06-22 Thread Emil Velikov
Hi all, As kindly hinted by Marek, currently we do have a wide selection of supported dri <> loader combinations. Although we like to think that things never break, we have to admit that not many of us test every possible combinations of dri modules and loaders. With the chances getting smaller a

Re: [Mesa-dev] [PATCH 00/11] glapi fixes - build whole of mesa with

2015-06-22 Thread Ian Romanick
On 06/22/2015 07:01 AM, Jose Fonseca wrote: > On 19/06/15 23:09, Emil Velikov wrote: >> On 19 June 2015 at 21:26, Jose Fonseca wrote: >>> On 19/06/15 20:56, Emil Velikov wrote: Hi all, A lovely series inspired (more like 'was awaken to send these out') by Pal Rohár, who wa

Re: [Mesa-dev] abundance of branches in mesa.git

2015-06-22 Thread Marek Olšák
It's not so important now that the amdgpu driver is about to be merged. Speaking of other branches, I think removing the old feature branches is a good idea. Marek On Mon, Jun 22, 2015 at 8:02 PM, Ian Romanick wrote: > On 06/22/2015 10:40 AM, Marek Olšák wrote: >> I will happily remove the bran

[Mesa-dev] [PATCH] i965/fs: Fix ir_txs in emit_texture_gen4_simd16().

2015-06-22 Thread Kenneth Graunke
We were not emitting the LOD, which led to message lengths of 1 instead of 3. Setting has_lod makes us emit the LOD, but I had to make changes to avoid emitting the non-existent coordinate as well. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91022 Cc: mesa-sta...@lists.freedesktop.org

  1   2   >