Re: [Mesa-dev] [PATCH 18/18] i965: Convert WM_STATE to genxml on gen4-5.

2017-07-17 Thread Kenneth Graunke
On Friday, June 16, 2017 4:31:31 PM PDT Rafael Antognolli wrote: > The code doesn't get exactly a lot simpler but at least it is in a single > place, and we delete more than we add. > > Signed-off-by: Rafael Antognolli > --- > src/mesa/drivers/dri/i965/Makefile.sources| 1 - > src/mesa/dri

Re: [Mesa-dev] [PATCH] radv: Set the RADEON_SURF_OPTIMIZE_FOR_SPACE flag for images

2017-07-17 Thread Dave Airlie
On 17 July 2017 at 20:14, Alex Smith wrote: > This looks like a regression from df301237940 ("radv: use > ac_compute_surface"). Before that, the opt4Space addrlib flag was set > to true unless the image has FMASK (ac_compute_surface will similarly > only set that flag for images without FMASK). >

[Mesa-dev] [PATCH 2/2] i965/bufmgr: Skip wait ioctl when busy.

2017-07-17 Thread Kenneth Graunke
If the buffer is idle, we I915_GEM_WAIT will return immediately, so we may as well skip the ioctl altogether. We can't trust the "idle" flag for external buffers, but for most, it should be fine. --- src/mesa/drivers/dri/i965/brw_bufmgr.c | 4 1 file changed, 4 insertions(+) This patch shou

[Mesa-dev] [PATCH 1/2] i965/bufmgr: Explicitly wait instead of using I915_GEM_SET_DOMAIN.

2017-07-17 Thread Kenneth Graunke
With the advent of asynchronous maps, domain tracking doesn't make a whole lot of sense. Buffers can be in use on both the CPU and GPU at the same time. In order to avoid blocking, we stopped using set_domain for asynchronous mappings, which means that the kernel's tracking has lies. We can't pr

[Mesa-dev] [PATCH] [rfc] radv: start moving semaphore support out of libdrm

2017-07-17 Thread Dave Airlie
From: Dave Airlie This is a port of radv to the new lowlevel cs submission APIs for libdrm that I submitted earlier. This moves a lot of the current non-shared semaphore handling and chunk creation out of libdrm_amdgpu. It provides a much simpler implementation without all the list handling, I'm

Re: [Mesa-dev] [PATCH 10/20] nir: Add pass to scalarize read_invocation/read_first_invocation

2017-07-17 Thread Kenneth Graunke
On Monday, July 17, 2017 6:12:57 PM PDT Matt Turner wrote: > On Mon, Jul 17, 2017 at 5:10 PM, Kenneth Graunke > wrote: > > On Thursday, July 6, 2017 4:48:20 PM PDT Matt Turner wrote: > >> i965 will want these to be scalar operations. > >> --- > >> src/compiler/Makefile.sources

Re: [Mesa-dev] [PATCH] anv/image: Fix VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 5:18 PM, Chad Versace wrote: > On Tue 18 Jul 2017, Lionel Landwerlin wrote: > > Oh dear :/ > > > > Reviewed-by: Lionel Landwerlin > > > > On 17/07/17 23:32, Chad Versace wrote: > > > We incorrectly detected VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT. We > looked > > > for the b

Re: [Mesa-dev] [PATCH 20/20] nir: Narrow unnecessary 64-bit operations to 32-bits

2017-07-17 Thread Connor Abbott
On Thu, Jul 6, 2017 at 4:48 PM, Matt Turner wrote: > If we know the high bits are zero, we can just do a 32-bit comparison on > the low bytes instead. > --- > src/compiler/nir/nir_opt_algebraic.py | 14 +- > src/compiler/nir/nir_search_helpers.h | 48 > +++

Re: [Mesa-dev] [PATCH 16/20] nir: Reduce destination size of ballot intrinsic when possible

2017-07-17 Thread Connor Abbott
Aside from using nir_src_copy as mentioned by Ken, Reviewed-by: Connor Abbott On Mon, Jul 10, 2017 at 10:22 AM, Matt Turner wrote: > Some hardware, like i965, doesn't support group sizes greater than 32. > In that case, we can reduce the destination size of the ballot > intrinsic, which will si

Re: [Mesa-dev] [PATCH 20/20] nir: Narrow unnecessary 64-bit operations to 32-bits

2017-07-17 Thread Connor Abbott
On Thu, Jul 6, 2017 at 4:48 PM, Matt Turner wrote: > If we know the high bits are zero, we can just do a 32-bit comparison on > the low bytes instead. > --- > src/compiler/nir/nir_opt_algebraic.py | 14 +- > src/compiler/nir/nir_search_helpers.h | 48 > +++

[Mesa-dev] [PATCH 11/27] radeonsi: add basic memory object support v3

2017-07-17 Thread Andres Rodriguez
From: Dave Airlie v2: also consider gfx9 metadata v3: ref/unref memobj->buf Signed-off-by: Andres Rodriguez --- src/gallium/drivers/radeon/r600_pipe_common.h | 7 ++ src/gallium/drivers/radeon/r600_texture.c | 111 ++ 2 files changed, 118 insertions(+) diff --git

Re: [Mesa-dev] [PATCH 20/20] nir: Narrow unnecessary 64-bit operations to 32-bits

2017-07-17 Thread Matt Turner
On Mon, Jul 17, 2017 at 5:57 PM, Kenneth Graunke wrote: > On Thursday, July 6, 2017 4:48:30 PM PDT Matt Turner wrote: >> If we know the high bits are zero, we can just do a 32-bit comparison on >> the low bytes instead. >> --- >> src/compiler/nir/nir_opt_algebraic.py | 14 +- >> src/compi

Re: [Mesa-dev] [PATCH 10/20] nir: Add pass to scalarize read_invocation/read_first_invocation

2017-07-17 Thread Matt Turner
On Mon, Jul 17, 2017 at 5:10 PM, Kenneth Graunke wrote: > On Thursday, July 6, 2017 4:48:20 PM PDT Matt Turner wrote: >> i965 will want these to be scalar operations. >> --- >> src/compiler/Makefile.sources | 1 + >> src/compiler/nir/nir.h | 2

Re: [Mesa-dev] [PATCH 06/20] i965/fs: Implement ARB_shader_group_vote operations

2017-07-17 Thread Matt Turner
On Mon, Jul 17, 2017 at 4:44 PM, Kenneth Graunke wrote: > On Thursday, July 6, 2017 4:48:16 PM PDT Matt Turner wrote: >> --- >> src/intel/compiler/brw_fs_nir.cpp | 36 >> 1 file changed, 36 insertions(+) >> >> diff --git a/src/intel/compiler/brw_fs_nir.cpp >>

Re: [Mesa-dev] [PATCH 20/20] nir: Narrow unnecessary 64-bit operations to 32-bits

2017-07-17 Thread Kenneth Graunke
On Thursday, July 6, 2017 4:48:30 PM PDT Matt Turner wrote: > If we know the high bits are zero, we can just do a 32-bit comparison on > the low bytes instead. > --- > src/compiler/nir/nir_opt_algebraic.py | 14 +- > src/compiler/nir/nir_search_helpers.h | 48 > +++

Re: [Mesa-dev] [PATCH 17/20] i965: Normalize types for FBL, FBH, etc

2017-07-17 Thread Kenneth Graunke
On Thursday, July 6, 2017 4:48:27 PM PDT Matt Turner wrote: > Allows the instructions to be compacted. The documentation claims that > some of these only accept UD types, even though the type doesn't change > the operation performed. Just normalize the types to ensure we get > instruction compactio

Re: [Mesa-dev] [PATCH 16/20] nir: Reduce destination size of ballot intrinsic when possible

2017-07-17 Thread Kenneth Graunke
On Monday, July 10, 2017 10:22:23 AM PDT Matt Turner wrote: > Some hardware, like i965, doesn't support group sizes greater than 32. > In that case, we can reduce the destination size of the ballot > intrinsic, which will simplify our code generation. > --- > v2: Just change the intrinsic size, and

Re: [Mesa-dev] [PATCH] mapi: add missing no_error tag to glBlitNamedFramebuffer()

2017-07-17 Thread Timothy Arceri
Reviewed-by: Timothy Arceri On 18/07/17 06:40, Samuel Pitoiset wrote: Fixes: 6fedb31785 ("mesa: add KHR_no_error support for glBlitNamedFramebuffer()") Signed-off-by: Samuel Pitoiset --- src/mapi/glapi/gen/ARB_direct_state_access.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) d

Re: [Mesa-dev] [PATCH 14/20] i965/fs: Implement ARB_shader_ballot operations

2017-07-17 Thread Kenneth Graunke
On Thursday, July 6, 2017 4:48:24 PM PDT Matt Turner wrote: > --- > src/intel/compiler/brw_fs_nir.cpp | 41 > +++ > src/intel/compiler/brw_nir.c | 1 + > 2 files changed, 42 insertions(+) > > diff --git a/src/intel/compiler/brw_fs_nir.cpp > b/src/intel/

Re: [Mesa-dev] [PATCH] anv/image: Fix VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT

2017-07-17 Thread Chad Versace
On Tue 18 Jul 2017, Lionel Landwerlin wrote: > Oh dear :/ > > Reviewed-by: Lionel Landwerlin > > On 17/07/17 23:32, Chad Versace wrote: > > We incorrectly detected VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT. We looked > > for the bit in VkImageCreateInfo::usage, but it's actually in > > VkImageCreateI

Re: [Mesa-dev] [PATCH 13/20] i965/fs: Do not move MOVs writing the flag outside of control flow

2017-07-17 Thread Kenneth Graunke
On Thursday, July 6, 2017 4:48:23 PM PDT Matt Turner wrote: > The implementation of ballotARB() will start by zeroing the flags > register. So, a doing something like > > if (gl_SubGroupInvocationARB % 2u == 0u) { > ... = ballotARB(true); > [...] > } e

Re: [Mesa-dev] [PATCH] anv/image: Fix VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT

2017-07-17 Thread Lionel Landwerlin
Oh dear :/ Reviewed-by: Lionel Landwerlin On 17/07/17 23:32, Chad Versace wrote: We incorrectly detected VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT. We looked for the bit in VkImageCreateInfo::usage, but it's actually in VkImageCreateInfo::flags. Found by assertion failures while enabling VK_ANDROI

Re: [Mesa-dev] [PATCH 10/20] nir: Add pass to scalarize read_invocation/read_first_invocation

2017-07-17 Thread Kenneth Graunke
On Thursday, July 6, 2017 4:48:20 PM PDT Matt Turner wrote: > i965 will want these to be scalar operations. > --- > src/compiler/Makefile.sources | 1 + > src/compiler/nir/nir.h | 2 +- > .../nir/nir_lower_read_invocation_to_scalar.c | 112

Re: [Mesa-dev] [PATCH 08/20] nir: Add intrinsics from ARB_shader_ballot

2017-07-17 Thread Kenneth Graunke
On Thursday, July 6, 2017 4:48:18 PM PDT Matt Turner wrote: > --- > src/compiler/glsl/glsl_to_nir.cpp | 45 > +++ > src/compiler/nir/nir_intrinsics.h | 13 +++ > 2 files changed, 58 insertions(+) > > diff --git a/src/compiler/glsl/glsl_to_nir.cpp > b/

Re: [Mesa-dev] [PATCH 09/20] nir: Add system values from ARB_shader_ballot

2017-07-17 Thread Kenneth Graunke
On Tuesday, July 11, 2017 6:02:30 PM PDT Matt Turner wrote: > On Mon, Jul 10, 2017 at 4:05 PM, Connor Abbott wrote: > > On Mon, Jul 10, 2017 at 3:50 PM, Matt Turner wrote: > >> On Mon, Jul 10, 2017 at 1:10 PM, Connor Abbott wrote: > >>> On Thu, Jul 6, 2017 at 4:48 PM, Matt Turner wrote: >

Re: [Mesa-dev] [PATCH 06/20] i965/fs: Implement ARB_shader_group_vote operations

2017-07-17 Thread Kenneth Graunke
On Thursday, July 6, 2017 4:48:16 PM PDT Matt Turner wrote: > --- > src/intel/compiler/brw_fs_nir.cpp | 36 > 1 file changed, 36 insertions(+) > > diff --git a/src/intel/compiler/brw_fs_nir.cpp > b/src/intel/compiler/brw_fs_nir.cpp > index a9dce42c38..264398f

Re: [Mesa-dev] [PATCH 01/20] nir: Add intrinsics from ARB_shader_group_vote

2017-07-17 Thread Kenneth Graunke
On Thursday, July 6, 2017 4:48:11 PM PDT Matt Turner wrote: > These are intrinsics rather than opcodes, because they operate across > channels. > --- > src/compiler/glsl/glsl_to_nir.cpp | 22 ++ > src/compiler/nir/nir_intrinsics.h | 5 + > 2 files changed, 27 insertions(+)

Re: [Mesa-dev] [PATCH] mesa: fix GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION_EXT query

2017-07-17 Thread Neha Bhende
Looks good. Reviewed-by: Neha Bhende Regards, Neha From: Brian Paul Sent: Monday, July 17, 2017 11:28:43 AM To: mesa-dev@lists.freedesktop.org Cc: Charmaine Lee; Neha Bhende Subject: [PATCH] mesa: fix GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION_EXT query This

[Mesa-dev] [PATCH] anv/image: Fix VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT

2017-07-17 Thread Chad Versace
We incorrectly detected VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT. We looked for the bit in VkImageCreateInfo::usage, but it's actually in VkImageCreateInfo::flags. Found by assertion failures while enabling VK_ANDROID_native_buffer. Cc: mesa-sta...@lists.freedesktop.org --- Can someone at Intel plea

[Mesa-dev] [PATCH] radeonsi: add back the USE_MININUM_PRIORITY flag to the low-prio compiler queue

2017-07-17 Thread Marek Olšák
From: Marek Olšák Accidentally removed in 9f320e0a387a1009c5218daf130b3b754a3c2800. --- src/gallium/drivers/radeonsi/si_pipe.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c index 4df60b6..0bc

Re: [Mesa-dev] [PATCH v3 08/16] anv: Transition more color buffer layouts

2017-07-17 Thread Jason Ekstrand
On Fri, Jul 14, 2017 at 2:42 AM, Nanley Chery wrote: > On Mon, Jul 10, 2017 at 10:14:21AM -0700, Jason Ekstrand wrote: > > On Wed, Jun 28, 2017 at 2:14 PM, Nanley Chery > wrote: > > > > > v2: Expound on comment for the pipe controls (Jason Ekstrand). > > > > > > Signed-off-by: Nanley Chery > >

Re: [Mesa-dev] [PATCH] ac/nir: rewrite shared variable handling (v2)

2017-07-17 Thread Connor Abbott
Pushed! On Thu, Jul 13, 2017 at 3:39 PM, Connor Abbott wrote: > From: Connor Abbott > > Translate the NIR variables directly to LLVM instead of lowering to a > TGSI-style giant array of vec4's and then back to a variable. This > should fix indirect dereferences, make shared variables more tightl

[Mesa-dev] [PATCH] mapi: add missing no_error tag to glBlitNamedFramebuffer()

2017-07-17 Thread Samuel Pitoiset
Fixes: 6fedb31785 ("mesa: add KHR_no_error support for glBlitNamedFramebuffer()") Signed-off-by: Samuel Pitoiset --- src/mapi/glapi/gen/ARB_direct_state_access.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mapi/glapi/gen/ARB_direct_state_access.xml b/src/mapi/glapi

Re: [Mesa-dev] [PATCH 5/6] radeonsi: use slot indexes for bindless handles

2017-07-17 Thread Nicolai Hähnle
Hi Samuel, On 07.07.2017 03:45, Samuel Pitoiset wrote: On 07/05/2017 01:42 PM, Nicolai Hähnle wrote: On 04.07.2017 15:05, Samuel Pitoiset wrote: Using VRAM address as bindless handles is not a good idea because we have to use LLVMIntToPTr and the LLVM CSE pass can't optimize because it has no

Re: [Mesa-dev] [PATCH 1.2/8 v2] spirv: Generate spirv_info.c

2017-07-17 Thread Jason Ekstrand
Reviewed-by: Jason Ekstrand On Mon, Jul 17, 2017 at 12:31 PM, Ian Romanick wrote: > From: Ian Romanick > > The old table based spirv_*_to_string functions would return NULL for > any values "inside" the table that didn't have entries. The tables also > needed to be updated by hand each time a

[Mesa-dev] [PATCH 1.2/8 v2] spirv: Generate spirv_info.c

2017-07-17 Thread Ian Romanick
From: Ian Romanick The old table based spirv_*_to_string functions would return NULL for any values "inside" the table that didn't have entries. The tables also needed to be updated by hand each time a new spirv.h was imported. Generate the file instead. v2: Make this script work more like src/

Re: [Mesa-dev] [PATCH v2] etnaviv: Add support for ETC2 texture compression

2017-07-17 Thread Christian Gmeiner
2017-07-17 18:56 GMT+02:00 Wladimir J. van der Laan : > Add support for ETC2 compressed textures in the etnaviv driver. > > One step closer towards GL ES 3 support. > > For now, treat SRGB and RGB formats the same. It looks like these are > distinguished using a different bit in sampler state, and

Re: [Mesa-dev] [PATCH] st/mesa: init winsys buffers list only if context creation succeeds

2017-07-17 Thread Brian Paul
On 07/11/2017 11:42 PM, Charmaine Lee wrote: Fixes piglit test crash when context creation fails. v2: As suggested by Brian, move the init to st_create_context_priv() --- src/mesa/state_tracker/st_context.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mesa/sta

Re: [Mesa-dev] [PATCH 08/16] i965/wm: Use isl for determining vertical slice pitch

2017-07-17 Thread Jason Ekstrand
On July 17, 2017 11:17:43 AM "Pohjolainen, Topi" wrote: On Mon, Jul 17, 2017 at 09:11:53AM -0700, Jason Ekstrand wrote: On Mon, Jul 17, 2017 at 6:34 AM, Topi Pohjolainen < topi.pohjolai...@gmail.com> wrote: > This helps to drop dependency to miptree::total_height which is > used in brw_miptr

[Mesa-dev] [PATCH] st/mesa: init winsys buffers list only if context creation succeeds

2017-07-17 Thread Charmaine Lee
Fixes piglit test crash when context creation fails. v2: As suggested by Brian, move the init to st_create_context_priv() --- src/mesa/state_tracker/st_context.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker

[Mesa-dev] [PATCH] mesa: fix GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION_EXT query

2017-07-17 Thread Brian Paul
This query is not allowed in GL core profile 3.3 and later (since GL_QUADS and GL_QUAD_STRIP are disallowed). The query was (mistakenly) supported in GL 3.2. This fixes the glGet error test accordingly. --- src/mesa/main/get.c | 12 src/mesa/main/get_hash_params.py | 2

Re: [Mesa-dev] [PATCH] st/mesa: init winsys buffers list only if context creation succeeds

2017-07-17 Thread Brian Paul
On 07/11/2017 11:14 PM, Charmaine Lee wrote: Fixes piglit test crash when context creation fails. --- src/mesa/state_tracker/st_context.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c index 5

Re: [Mesa-dev] [PATCH v3 02/14] i965/miptree: Allocate HiZ up-front

2017-07-17 Thread Jason Ekstrand
Topi, Ping? I'd like to land as much of the prep-work as possible. On Mon, Jul 17, 2017 at 10:33 AM, Pohjolainen, Topi < topi.pohjolai...@gmail.com> wrote: > On Mon, Jul 17, 2017 at 08:10:01AM -0700, Jason Ekstrand wrote: > > On Mon, Jul 17, 2017 at 5:50 AM, Pohjolainen, Topi < > > topi.pohjolai

Re: [Mesa-dev] [PATCH 08/16] i965/wm: Use isl for determining vertical slice pitch

2017-07-17 Thread Pohjolainen, Topi
On Mon, Jul 17, 2017 at 09:11:53AM -0700, Jason Ekstrand wrote: > On Mon, Jul 17, 2017 at 6:34 AM, Topi Pohjolainen < > topi.pohjolai...@gmail.com> wrote: > > > This helps to drop dependency to miptree::total_height which is > > used in brw_miptree_get_vertical_slice_pitch(). > > > > This is also

Re: [Mesa-dev] [PATCH 1.2/8] spirv: Generate spirv_info.c

2017-07-17 Thread Ian Romanick
On 07/17/2017 10:54 AM, Emil Velikov wrote: > On 15 July 2017 at 02:39, Ian Romanick wrote: >> From: Ian Romanick >> >> The old table based spirv_*_to_string functions would return NULL for >> any values "inside" the table that didn't have entries. The tables also >> needed to be updated by hand

[Mesa-dev] [PATCH 1/2] egl/drm: Fix misused x and y offsets on swrast_put_image2()

2017-07-17 Thread Gwan-gyeong Mun
It fixes misused x and y offsets on the calculation of the memory copy regions. And it adds limits of the height and the width on the copy region. Signed-off-by: Mun Gwan-gyeong --- src/egl/drivers/dri2/platform_drm.c | 17 +++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff

[Mesa-dev] [PATCH 2/2] egl/drm: Fix misused x and y offsets on swrast_get_image()

2017-07-17 Thread Gwan-gyeong Mun
It fixes misused x and y offsets on the calculation of the memory copy regions. And it adds limits of the height and the width on the copy region. Signed-off-by: Mun Gwan-gyeong --- src/egl/drivers/dri2/platform_drm.c | 19 --- 1 file changed, 16 insertions(+), 3 deletions(-) di

Re: [Mesa-dev] [PATCH 01/20] nir: Add intrinsics from ARB_shader_group_vote

2017-07-17 Thread Matt Turner
I've force pushed this series with all suggested changes to the ballot branch of my tree git://people.freedesktop.org/~mattst88/mesa ballot The only two reviews I have so far are my own, after changing the authorship on two patches to Curro. With the branchpoint coming up this week, I'd really

[Mesa-dev] [PATCH] st/mesa: init winsys buffers list only if context creation succeeds

2017-07-17 Thread Charmaine Lee
Fixes piglit test crash when context creation fails. --- src/mesa/state_tracker/st_context.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c index 560d94e..8eccad6 100644 --- a/src/mesa/state_track

Re: [Mesa-dev] [PATCH] gles: Restore some lost typedefs

2017-07-17 Thread Scott D Phillips
Eric Engestrom writes: > On Friday, 2017-06-30 15:06:36 -0700, Ian Romanick wrote: >> Has this been reported to upstream (i.e., Khronos)? I don't mind fixing >> these in our tree, but they really should get fixed at the source too. > > I can't see any mention of this on neither the old Bugzilla

Re: [Mesa-dev] [PATCH 05/20] i965/fs: Handle explicit flag destinations in flags_written()

2017-07-17 Thread Matt Turner
On Fri, Jul 14, 2017 at 3:23 PM, Francisco Jerez wrote: > Matt Turner writes: > >> The implementations of the ARB_shader_group_vote intrinsics will >> explicitly write the flag as the destination register. >> --- >> src/intel/compiler/brw_fs.cpp | 12 ++-- >> 1 file changed, 10 insertion

Re: [Mesa-dev] [PATCH 1.2/8] spirv: Generate spirv_info.c

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 18:54, Emil Velikov wrote: > I think you missed "git add spirvjson" Nope, it's there as PATCH 1.1/8. Pardon for the noise. -Emil ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listi

Re: [Mesa-dev] [PATCH 12/20] i965/fs: Handle explicit flag sources in flags_read()

2017-07-17 Thread Matt Turner
On Fri, Jul 14, 2017 at 5:52 PM, Francisco Jerez wrote: > Matt Turner writes: > >> The implementations of the ARB_shader_ballot intrinsics will explicitly >> read the flag as a source register. >> --- >> src/intel/compiler/brw_fs.cpp | 18 ++ >> 1 file changed, 14 insertions(+),

Re: [Mesa-dev] [PATCH 1.2/8] spirv: Generate spirv_info.c

2017-07-17 Thread Emil Velikov
On 15 July 2017 at 02:39, Ian Romanick wrote: > From: Ian Romanick > > The old table based spirv_*_to_string functions would return NULL for > any values "inside" the table that didn't have entries. The tables also > needed to be updated by hand each time a new spirv.h was imported. > Generate t

Re: [Mesa-dev] [PATCH 1.5/14] i965/miptree: Add an intel_tiling_supports_hiz helper

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 10:42 AM, Pohjolainen, Topi < topi.pohjolai...@gmail.com> wrote: > On Mon, Jul 17, 2017 at 08:04:40AM -0700, Jason Ekstrand wrote: > > We need this split for the same reason that we need the split for CCS: > > intel_miptree_supports_hiz is called *before* we choose the actu

Re: [Mesa-dev] [PATCH 11/20] i965/fs: Allow emit_uniformize() to broadcast a specific channel

2017-07-17 Thread Matt Turner
On Fri, Jul 14, 2017 at 5:48 PM, Francisco Jerez wrote: > I don't like re-using emit_uniformize() (which is supposed to give you > the value of a channel of the input it can prove live as the doxygen > comment explains), as a "fetch me the i-th channel of the source" > helper. I think what you wa

Re: [Mesa-dev] [PATCH 1.5/14] i965/miptree: Add an intel_tiling_supports_hiz helper

2017-07-17 Thread Pohjolainen, Topi
On Mon, Jul 17, 2017 at 08:04:40AM -0700, Jason Ekstrand wrote: > We need this split for the same reason that we need the split for CCS: > intel_miptree_supports_hiz is called *before* we choose the actual > tiling. Adding a tiling_supports_hiz helper lets choose_aux_usage > more accurately decide

Re: [Mesa-dev] [PATCH 1.2/8] spirv: Generate spirv_info.c

2017-07-17 Thread Ian Romanick
On 07/17/2017 10:09 AM, Ian Romanick wrote: > On 07/14/2017 09:22 PM, Jason Ekstrand wrote: >> What you have is fine here but I've been really liking the style that's >> used in mesa/main/format_fallbacks.py and the anv_extensions.py that I >> sent out which does >> >> COPYRIGHT=""" >> \* The usual

Re: [Mesa-dev] [PATCH 1.2/8] spirv: Generate spirv_info.c

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 10:09 AM, Ian Romanick wrote: > On 07/14/2017 09:22 PM, Jason Ekstrand wrote: > > On Fri, Jul 14, 2017 at 6:39 PM, Ian Romanick > > wrote: > > > > From: Ian Romanick > > > > > > The old table based

Re: [Mesa-dev] [PATCH 15/16] i965: Refactor check for separate stencil

2017-07-17 Thread Pohjolainen, Topi
On Mon, Jul 17, 2017 at 09:19:01AM -0700, Jason Ekstrand wrote: > On Mon, Jul 17, 2017 at 6:35 AM, Topi Pohjolainen < > topi.pohjolai...@gmail.com> wrote: > > > Signed-off-by: Topi Pohjolainen > > --- > > src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 24 > > > > 1 file

Re: [Mesa-dev] [PATCH v3 02/14] i965/miptree: Allocate HiZ up-front

2017-07-17 Thread Pohjolainen, Topi
On Mon, Jul 17, 2017 at 08:10:01AM -0700, Jason Ekstrand wrote: > On Mon, Jul 17, 2017 at 5:50 AM, Pohjolainen, Topi < > topi.pohjolai...@gmail.com> wrote: > > > On Mon, Jul 17, 2017 at 03:29:32PM +0300, Pohjolainen, Topi wrote: > > > On Fri, Jul 14, 2017 at 03:22:51PM -0700, Chad Versace wrote: >

Re: [Mesa-dev] [PATCH 4/4] dri: Add KHR_no_error toggle to driconf

2017-07-17 Thread Emil Velikov
On 13 July 2017 at 12:09, Grigori Goronzy wrote: > On 2017-07-12 15:15, Emil Velikov wrote: >> >> As mentioned in earlier commit no_error should be device agnostic. >> Hence removing the st/dri bits and adding a DRI_CONF_MESA_NO_ERROR() >> line next to DRI_CONF_VBLANK_MODE seems like the better so

Re: [Mesa-dev] [PATCH v2] etnaviv: Add support for ETC2 texture compression

2017-07-17 Thread Ilia Mirkin
;On Mon, Jul 17, 2017 at 12:56 PM, Wladimir J. van der Laan wrote: > Add support for ETC2 compressed textures in the etnaviv driver. > > One step closer towards GL ES 3 support. > > For now, treat SRGB and RGB formats the same. It looks like these are > distinguished using a different bit in sampl

Re: [Mesa-dev] [PATCH 1.2/8] spirv: Generate spirv_info.c

2017-07-17 Thread Ian Romanick
On 07/14/2017 09:22 PM, Jason Ekstrand wrote: > On Fri, Jul 14, 2017 at 6:39 PM, Ian Romanick > wrote: > > From: Ian Romanick > > > The old table based spirv_*_to_string functions would return NULL for > any values "i

Re: [Mesa-dev] [PATCH 5/6] radeonsi: use slot indexes for bindless handles

2017-07-17 Thread Marek Olšák
On Mon, Jul 17, 2017 at 4:35 AM, Samuel Pitoiset wrote: > > > On 07/15/2017 02:54 AM, Marek Olšák wrote: >> >> On Wed, Jul 5, 2017 at 1:42 PM, Nicolai Hähnle wrote: >>> >>> On 04.07.2017 15:05, Samuel Pitoiset wrote: Using VRAM address as bindless handles is not a good idea because

[Mesa-dev] [PATCH v2] etnaviv: Add support for ETC2 texture compression

2017-07-17 Thread Wladimir J. van der Laan
Add support for ETC2 compressed textures in the etnaviv driver. One step closer towards GL ES 3 support. For now, treat SRGB and RGB formats the same. It looks like these are distinguished using a different bit in sampler state, and not part of the format, but I have not yet been able to confirm

Re: [Mesa-dev] [PATCH 2/2] configure/swr: add KNL and SKX architecture targets

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 15:08, Tim Rowley wrote: > Not built by default. > --- > configure.ac | 16 ++ > src/gallium/drivers/swr/Makefile.am| 38 > ++ > src/gallium/drivers/swr/swr_loader.cpp | 20 +- > 3 files

Re: [Mesa-dev] [PATCH 1/2] configure/swr: configurable swr architectures

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 15:08, Tim Rowley wrote: > Allow configuration of the SWR architecture depend libraries > we build for with --with-swr-archs. Maintains current behavior > by defaulting to avx,avx2. > > Scons changes made to make it still build and work, but > without the changes for configurin

Re: [Mesa-dev] [PATCH 1/2] i965: Rework the modifier info map

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 8:24 AM, Daniel Stone wrote: > Hi, > > On 17 July 2017 at 15:39, Jason Ekstrand wrote: > > On Mon, Jul 17, 2017 at 2:24 AM, Daniel Stone > wrote: > >> On 17 July 2017 at 01:48, Jason Ekstrand wrote: > >> > This commit splits the mapping in half. The modifier_infos tabl

Re: [Mesa-dev] [PATCH 06/16] i965/miptree: Do not rely on msaa type to decide if aux is needed

2017-07-17 Thread Jason Ekstrand
Oops, forgot to add: Reviewed-by: Jason Ekstrand On Mon, Jul 17, 2017 at 9:27 AM, Jason Ekstrand wrote: > On Mon, Jul 17, 2017 at 6:34 AM, Topi Pohjolainen < > topi.pohjolai...@gmail.com> wrote: > >> Once the driver moves to ISL both compressed and uncompressed have >> the same type. One needs

Re: [Mesa-dev] [PATCH 06/16] i965/miptree: Do not rely on msaa type to decide if aux is needed

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 6:34 AM, Topi Pohjolainen < topi.pohjolai...@gmail.com> wrote: > Once the driver moves to ISL both compressed and uncompressed have > the same type. One needs to tell them apart by other means. This > can be done by checking the existence of mcs_buf. > > There is a short pe

Re: [Mesa-dev] [PATCH 16/16] i965/gen4: Set tile offsets to zero after depth rebase

2017-07-17 Thread Jason Ekstrand
9-16 are Reviewed-by: Jason Ekstrand On Mon, Jul 17, 2017 at 6:35 AM, Topi Pohjolainen < topi.pohjolai...@gmail.com> wrote: > Current logic calls intel_renderbuffer_set_draw_offset() which in > turn tries to calculate x and y offset against layer/level settings > that are against the original m

Re: [Mesa-dev] [PATCH 15/16] i965: Refactor check for separate stencil

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 6:35 AM, Topi Pohjolainen < topi.pohjolai...@gmail.com> wrote: > Signed-off-by: Topi Pohjolainen > --- > src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 24 > > 1 file changed, 20 insertions(+), 4 deletions(-) > > diff --git a/src/mesa/drivers/dri

Re: [Mesa-dev] [PATCH 08/16] i965/wm: Use isl for determining vertical slice pitch

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 6:34 AM, Topi Pohjolainen < topi.pohjolai...@gmail.com> wrote: > This helps to drop dependency to miptree::total_height which is > used in brw_miptree_get_vertical_slice_pitch(). > > This is also readily compatible once miptree itself is isl > based. > > Signed-off-by: Topi

Re: [Mesa-dev] [PATCH 07/16] i965/miptree: Check for miptree_create() failures

2017-07-17 Thread Jason Ekstrand
Reviewed-by: Jason Ekstrand On Mon, Jul 17, 2017 at 6:34 AM, Topi Pohjolainen < topi.pohjolai...@gmail.com> wrote: > Rest of the function assumes it always succeeds. > > Signed-off-by: Topi Pohjolainen > --- > src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 2 ++ > 1 file changed, 2 insertions

Re: [Mesa-dev] [PATCH 04/16] i965/tex: Use offset helper instead of accessing table directly

2017-07-17 Thread Jason Ekstrand
1-4 are Reviewed-by: Jason Ekstrand On Mon, Jul 17, 2017 at 6:34 AM, Topi Pohjolainen < topi.pohjolai...@gmail.com> wrote: > Signed-off-by: Topi Pohjolainen > --- > src/mesa/drivers/dri/i965/intel_tex_image.c| 6 -- > src/mesa/drivers/dri/i965/intel_tex_subimage.c | 6 -- > 2 file

Re: [Mesa-dev] [PATCH 05/16] i965: Make irb::mt_layer logical instead of physical

2017-07-17 Thread Jason Ekstrand
Thank you, thank you, thank you! This has been annoying me for a long time. Good to see it get sorted. I did a quick grep through the tree and it looks like you got them all. Reviewed-by: Jason Ekstrand On Mon, Jul 17, 2017 at 6:34 AM, Topi Pohjolainen < topi.pohjolai...@gmail.com> wrote: >

Re: [Mesa-dev] [PATCH] egl/drm: fix assert checking of dri2_surf->buffer_count

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 16:47, Gwan-gyeong Mun wrote: > This adds an increment of buffer_count and changes a border value with > ARRAY_SIZE() macro. > > Signed-off-by: Mun Gwan-gyeong > --- > src/egl/drivers/dri2/platform_drm.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git

[Mesa-dev] [PATCH v7 3/6] mesa/st: glsl_to_tgsi: add tests for the new temporary lifetime tracker

2017-07-17 Thread Gert Wollny
This patch adds a set of unit tests for the new lifetime tracker. --- configure.ac |1 + src/mesa/Makefile.am |2 +- src/mesa/state_tracker/tests/Makefile.am | 36 + .../tests/test_glsl_to_tgsi_lifetime.cpp

[Mesa-dev] [PATCH v7 1/6] mesa/st: glsl_to_tgsi move some helper classes to extra files

2017-07-17 Thread Gert Wollny
To prepare the implementation of a temp register lifetime tracker some of the classes are moved into seperate header/implementation files to make them accessible from other files. Specifically these are: class st_src_reg; class st_dst_reg; class glsl_to_tgsi_instruction; struct re

[Mesa-dev] [PATCH v7 4/6] mesa/st: glsl_to_tgsi: add register rename mapping evaluator

2017-07-17 Thread Gert Wollny
The remapping evaluator first sorts the temporary registers ascending based on their first life time instruction, and then uses a binary search to find merge canidates. For the initial sorting it uses std::sort because qsort is quite slow in comparison. By removing the define USE_STL_SORT in src/

[Mesa-dev] [PATCH v7 5/6] mesa/st: glsl_to_tgsi: Add test set for evaluation of rename mapping

2017-07-17 Thread Gert Wollny
The patch adds tests for the register rename mapping evaluation and combined life time estimation and renaming. --- .../tests/test_glsl_to_tgsi_lifetime.cpp | 192 + 1 file changed, 192 insertions(+) diff --git a/src/mesa/state_tracker/tests/test_glsl_to_tgsi_lifetim

[Mesa-dev] [PATCH v7 6/6] mesa/st: glsl_to_tgsi: tie in new temporary register merge approach

2017-07-17 Thread Gert Wollny
This patch replaces the old register lifetime estiamtion and rename mapping evaluation with the new one. Performance to compare between the current and the new implementation were measured by running the shader-db in one thread. ---

[Mesa-dev] [PATCH v7 2/6] mesa/st: glsl_to_tgsi: implement new temporary register lifetime tracker

2017-07-17 Thread Gert Wollny
This patch adds a class for tracking the life times of temporary registers in the glsl to tgsi translation. The algorithm runs in three steps: First, in order to minimize the number of needed memory allocations the program is scanned to evaluate the number of scopes. Then, the program is scanned s

[Mesa-dev] [PATCH v7 0/6] mesa/st: glsl_to_tgsi: improved temp-reg lifetime estimation

2017-07-17 Thread Gert Wollny
Hello Nicolai, many thanks for the review. With this new patch set I've implemented most of your suggestions, patch 1 and 6 are only rebased though. The patches are also available via https://github.com/gerddie/mesa/tree/regrename-v7 The one thing I did not do (or better said, I reverted it)

[Mesa-dev] [PATCH] egl/drm: fix assert checking of dri2_surf->buffer_count

2017-07-17 Thread Gwan-gyeong Mun
This adds an increment of buffer_count and changes a border value with ARRAY_SIZE() macro. Signed-off-by: Mun Gwan-gyeong --- src/egl/drivers/dri2/platform_drm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/egl/drivers/dri2/platform_drm.c b/src/egl/drivers/dri2/plat

Re: [Mesa-dev] [PATCH] egl/drm: Format code in platform_drm.c according to style guide.

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 16:21, Gwan-gyeong Mun wrote: > This is a tiny housekeeping patch which does the following: > * Limit lines to 78 or fewer characters. > According to the mesa coding style guidelines. > The odd line which goes over the guideline (note it's not a requirement), doesn't hurt. But

Re: [Mesa-dev] [PATCH] egl/drm: add going out of the loop when the designated buffer is found

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 16:03, Gwan-gyeong Mun wrote: > Because the color_buffers have a each unique bo, if the designated buffer is > found, release_buffer() can go out the loop which seaches the buffer. > Indeed. Currently we waste a couple of CPU cycles to check the remaining color buffers when we d

Re: [Mesa-dev] [PATCH] gbm: fix typo in doxygen comment

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 15:01, Gwan-gyeong Mun wrote: > This fixes the misspelling of gbm_bo_import api param. > Fixes: 44f066b9ffb ("gbm: Add new gbm_bo_import entry point") Reviewed-by: Emil Velikov I'll push this later on today, barring any objections. Thanks Emil

Re: [Mesa-dev] [PATCH 1/2] i965: Rework the modifier info map

2017-07-17 Thread Daniel Stone
Hi, On 17 July 2017 at 15:39, Jason Ekstrand wrote: > On Mon, Jul 17, 2017 at 2:24 AM, Daniel Stone wrote: >> On 17 July 2017 at 01:48, Jason Ekstrand wrote: >> > This commit splits the mapping in half. The modifier_infos table now >> > only contains the modifier and the since_gen field. The

[Mesa-dev] [PATCH] egl/drm: Format code in platform_drm.c according to style guide.

2017-07-17 Thread Gwan-gyeong Mun
This is a tiny housekeeping patch which does the following: * Limit lines to 78 or fewer characters. According to the mesa coding style guidelines. Signed-off-by: Mun Gwan-gyeong --- src/egl/drivers/dri2/platform_drm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/e

Re: [Mesa-dev] [PATCH 03/11] anv/cmd_buffer: Properly handle render passes with 0 attachments

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 4:18 AM, James Legg wrote: > On Tue, 2017-07-11 at 17:04 -0700, Jason Ekstrand wrote: > > We were early returning and never created the NULL surface state. > > > > Cc: mesa-sta...@lists.freedesktop.org > > This patch fixes a bug that affected me. > > Tested-by: James Legg

Re: [Mesa-dev] [PATCH 03/16] i965: Mark read-only args as const in intel_miptree_supports_hiz()

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 14:34, Topi Pohjolainen wrote: > Signed-off-by: Topi Pohjolainen > --- > src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c > b/src/mesa/drivers/dri/i965/inte

Re: [Mesa-dev] [PATCH 02/16] i965/miptree: Use > 1 instead of > 0 to check for multisampling

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 14:34, Topi Pohjolainen wrote: > Checking against zero currently works as single sampling is > represented with zero. Once one moves to isl single sampling > really has sample number of one. > > This keeps later patches simpler. > After ISL lands we can cleanup some of the remai

Re: [Mesa-dev] [PATCH v3 02/14] i965/miptree: Allocate HiZ up-front

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 5:50 AM, Pohjolainen, Topi < topi.pohjolai...@gmail.com> wrote: > On Mon, Jul 17, 2017 at 03:29:32PM +0300, Pohjolainen, Topi wrote: > > On Fri, Jul 14, 2017 at 03:22:51PM -0700, Chad Versace wrote: > > > On Wed 12 Jul 2017, Jason Ekstrand wrote: > > > > HiZ, like MCS and C

[Mesa-dev] [PATCH 1.5/14] i965/miptree: Add an intel_tiling_supports_hiz helper

2017-07-17 Thread Jason Ekstrand
We need this split for the same reason that we need the split for CCS: intel_miptree_supports_hiz is called *before* we choose the actual tiling. Adding a tiling_supports_hiz helper lets choose_aux_usage more accurately decide whether or not to enable hiz. In particular, this prevents us from ena

[Mesa-dev] [PATCH] egl/drm: add going out of the loop when the designated buffer is found

2017-07-17 Thread Gwan-gyeong Mun
Because the color_buffers have a each unique bo, if the designated buffer is found, release_buffer() can go out the loop which seaches the buffer. Signed-off-by: Mun Gwan-gyeong --- src/egl/drivers/dri2/platform_drm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/egl/drivers/dri2/platf

Re: [Mesa-dev] [PATCH] swr: remove unneeded fallback strcasecmp define

2017-07-17 Thread Rowley, Timothy O
Reviewed-by: Tim Rowley > On Jul 17, 2017, at 9:34 AM, Emil Velikov wrote: > > From: Emil Velikov > > The last user of the function was removed with earlier commit. > > Fixes: 50842e8a931 ("swr: replace gallium->swr format enum conversion") > Cc: Tim Rowley > Signed-off-by: Emil Velikov >

Re: [Mesa-dev] [PATCH 01/16] i965/miptree: Set refcount before failing via _release()

2017-07-17 Thread Emil Velikov
On 17 July 2017 at 14:34, Topi Pohjolainen wrote: > Otherwise one wraps uint to UINT_MAX via -1. > > Signed-off-by: Topi Pohjolainen > --- > src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/src/mesa/drivers/dri/i965/intel_mi

Re: [Mesa-dev] [PATCH v3 10/14] i965/miptree: Allocate mcs_buf for an image's CCS

2017-07-17 Thread Jason Ekstrand
On Mon, Jul 17, 2017 at 2:47 AM, Pohjolainen, Topi < topi.pohjolai...@gmail.com> wrote: > On Wed, Jul 12, 2017 at 09:23:21PM -0700, Jason Ekstrand wrote: > > From: Ben Widawsky > > > > This code will disable actually creating these buffers for the scanout, > > but it puts the allocation in place.

  1   2   >