[Mesa-dev] [PATCH 5/9] radeonsi: move passmgr into si_compiler

2018-04-16 Thread Marek Olšák
From: Marek Olšák --- src/gallium/drivers/radeonsi/si_pipe.c| 30 src/gallium/drivers/radeonsi/si_pipe.h| 7 src/gallium/drivers/radeonsi/si_shader.h | 1 + .../drivers/radeonsi/si_shader_tgsi_setup.c | 34 +-- 4 files changed, 32 in

[Mesa-dev] [PATCH 6/9] radeonsi: move data_layout into si_compiler

2018-04-16 Thread Marek Olšák
From: Marek Olšák --- src/gallium/drivers/radeonsi/si_pipe.c | 9 + src/gallium/drivers/radeonsi/si_shader.h| 1 + src/gallium/drivers/radeonsi/si_shader_tgsi_setup.c | 7 +-- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/src/gallium/drivers

[Mesa-dev] [PATCH 9/9] radeonsi: increase the number of compiler threads depending on the CPU

2018-04-16 Thread Marek Olšák
From: Marek Olšák The compiler queue was limited to 3 threads, so shader-db running on a 16-thread CPU would have a bottleneck on the 3-thread queue. --- src/gallium/drivers/radeonsi/si_pipe.c | 39 +- src/gallium/drivers/radeonsi/si_pipe.h | 6 ++-- 2 files changed, 29

[Mesa-dev] [PATCH 8/9] Revert "radeonsi: fix potential use-after-free of debug callbacks"

2018-04-16 Thread Marek Olšák
From: Marek Olšák This reverts commit b650fc09c3a35ca624aad5fe4b5c34867708f116. There is a 100%-reproducible deadlock if I increase the number of compiler queues. Also: Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105379 Cc: 18.0 --- src/gallium/drivers/radeonsi/si_pipe.c | 4

[Mesa-dev] [PATCH 2/9] radeonsi: add triple into si_compiler

2018-04-16 Thread Marek Olšák
From: Marek Olšák --- src/amd/common/ac_llvm_util.c | 6 +- src/amd/common/ac_llvm_util.h | 4 +++- src/amd/vulkan/radv_shader.c| 2 +- src/gallium/drivers/radeonsi/si_pipe.c | 3 ++- src/gallium/drivers/radeons

[Mesa-dev] [PATCH 7/9] radeonsi: avoid a crash in gallivm_dispose_target_library_info

2018-04-16 Thread Marek Olšák
From: Marek Olšák --- src/gallium/drivers/radeonsi/si_pipe.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c index 09b9f588a6f..490a090da87 100644 --- a/src/gallium/drivers/radeonsi/si_pipe.c +++ b/src/galliu

Re: [Mesa-dev] [PATCH 1/9] radeonsi: add struct si_compiler containing LLVMTargetMachineRef

2018-04-16 Thread Timothy Arceri
Series: Reviewed-by: Timothy Arceri ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Re: [Mesa-dev] [PATCH] fix gcc 8 parenthesis warning

2018-04-16 Thread Timothy Arceri
Pushed. Thanks! On 23/03/18 21:01, Marc Dietrich wrote: fixes warnings like this: [184/1137] Compiling C++ object 'src/compiler/glsl/glsl@sta/lower_jumps.cpp.o'. In file included from ../src/mesa/main/mtypes.h:48, from ../src/compiler/glsl_types.h:149, from ..

Re: [Mesa-dev] [PATCH 07/10] nir: return early when lowering a return at the end of a function

2018-04-16 Thread Jason Ekstrand
Reviewed-by: Jason Ekstrand On Mon, Apr 9, 2018 at 9:34 PM, Timothy Arceri wrote: > Otherwise we create unused conditional return flags and things > get unnecessarily ugly fast when lowering nested functions. > --- > src/compiler/nir/nir_lower_returns.c | 8 > 1 file changed, 8 insert

Re: [Mesa-dev] [PATCH 07/10] nir: return early when lowering a return at the end of a function

2018-04-16 Thread Jason Ekstrand
On Mon, Apr 9, 2018 at 9:34 PM, Timothy Arceri wrote: > Otherwise we create unused conditional return flags and things > get unnecessarily ugly fast when lowering nested functions. > --- > src/compiler/nir/nir_lower_returns.c | 8 > 1 file changed, 8 insertions(+) > > diff --git a/src/c

Re: [Mesa-dev] [PATCH 1/2] mesa: GL_EXT_texture_norm16 extension plumbing

2018-04-16 Thread Tapani Pälli
On 17.04.2018 02:42, Ilia Mirkin wrote: On Mon, Apr 16, 2018 at 7:36 PM, Tapani Pälli wrote: Hi; On 16.04.2018 18:19, Ilia Mirkin wrote: You never check EXT_texture_norm16 anywhere... is that right? Should probably respect that in the _mesa_is_es3_* helpers. Also what about Oops that is

Re: [Mesa-dev] [Mesa-stable] [PATCH] ac/nir: Make the GFX9 buffer size fix apply to image loads/atomics too.

2018-04-16 Thread Bas Nieuwenhuizen
On Mon, Apr 16, 2018 at 1:17 PM, Juan A. Suarez Romero wrote: > On Mon, 2018-04-16 at 00:09 +0200, Bas Nieuwenhuizen wrote: >> No clue how I missed those ... >> >> Fixes: 4503ff760c "ac/nir: Add workaround for GFX9 buffer views." >> CC: >> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=10

Re: [Mesa-dev] [PATCH] mesa/math: Allocate memory for GLmatrix elements and its inverse contiguously

2018-04-16 Thread Thomas Helland
Hi, and thanks for the patch =) Have you done any performance testing on this to verify it gives us a speedup of any kind? I'm asking because it seems like this might be something that a decent compiler should be able to do. Performance related patches, at least in core mesa, usually have some jus

Re: [Mesa-dev] [PATCH v2 2/5] i965: perf: snapshot RPSTAT register

2018-04-16 Thread Kenneth Graunke
On Tuesday, April 3, 2018 7:48:10 AM PDT Lionel Landwerlin wrote: > This register contains the current/previous frequency of the GT, it's > one of the value GPA would like to have as part of their queries. > > v2: Don't use this register on baytrail/cherryview (Ken) > Use GET_FIELD() macro (Ke

Re: [Mesa-dev] [PATCH v2 3/5] i965: perf: read slice/unslice frequencies from OA reports

2018-04-16 Thread Kenneth Graunke
On Tuesday, April 3, 2018 7:48:11 AM PDT Lionel Landwerlin wrote: > Signed-off-by: Lionel Landwerlin > --- > src/mesa/drivers/dri/i965/brw_performance_query.c | 37 > +++ > src/mesa/drivers/dri/i965/brw_performance_query.h | 12 > 2 files changed, 49 insertions(+) >

[Mesa-dev] [Bug 106058] Fix version requirements for GL_ARB_gpu_shader5

2018-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=106058 Timothy Arceri changed: What|Removed |Added Status|NEW |RESOLVED Resolution|---

[Mesa-dev] [PATCH 2/3] meson: Add library versions to swr drivers

2018-04-16 Thread Jan Alexander Steffens (heftig)
This is for parity with autotools. Signed-off-by: Jan Alexander Steffens (heftig) --- src/gallium/drivers/swr/meson.build | 4 1 file changed, 4 insertions(+) diff --git a/src/gallium/drivers/swr/meson.build b/src/gallium/drivers/swr/meson.build index 4bcd4f4e38..e722602403 100644 --- a/s

[Mesa-dev] [PATCH 3/3] meson: Version libMesaOpenCL like autotools does

2018-04-16 Thread Jan Alexander Steffens (heftig)
This is for parity with autotools. It names the library libMesaOpenCL.so.1.0.0 and points mesa.icd to the .1 symlink. opencl_version now matches configure.ac's OPENCL_VERSION. Signed-off-by: Jan Alexander Steffens (heftig) --- src/gallium/targets/opencl/meson.build | 4 ++-- 1 file changed, 2 i

[Mesa-dev] [PATCH 0/3] meson: Patches for autotools parity

2018-04-16 Thread Jan Alexander Steffens (heftig)
Hi, these patches were added to mesa 18.0.0 by Arch Linux in order to make the meson build product more like the autotools one. They are in addition to two patches already in master: - 6ac87c17 (meson: fix megadriver symlinking) - 19dbed64 (meson: Set .so version for xa like autotools does)

[Mesa-dev] [PATCH 1/3] meson: Define NDEBUG for non-debug-builds

2018-04-16 Thread Jan Alexander Steffens (heftig)
This is for parity with autotools. We were suddenly getting assertion failures after switching to meson, see [1]. [1]: https://bugs.archlinux.org/task/58218 Signed-off-by: Jan Alexander Steffens (heftig) --- meson.build | 2 ++ 1 file changed, 2 insertions(+) diff --git a/meson.build b/meson.b

Re: [Mesa-dev] [PATCH] ac/nir: Make the GFX9 buffer size fix apply to image loads/atomics too.

2018-04-16 Thread Nicolai Hähnle
Reviewed-by: Nicolai Hähnle On 16.04.2018 00:09, Bas Nieuwenhuizen wrote: No clue how I missed those ... Fixes: 4503ff760c "ac/nir: Add workaround for GFX9 buffer views." CC: Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105320 --- src/amd/common/ac_nir_to_llvm.c | 39 +

Re: [Mesa-dev] [Mesa-stable] [PATCH] mesa: call DrawBuffer(s) driver hook in update_framebuffer for windows-system FB

2018-04-16 Thread Juan A. Suarez Romero
On Fri, 2018-04-13 at 08:17 -0600, Brian Paul wrote: > > Hi Brain, are you happy if we push this in the meantime? It seems to > > impact a number of apps running on Wine? > > I don't have time to look at it myself right now. So if it looks good > to you and you can check it in, go for it. I

Re: [Mesa-dev] [Mesa-stable] [PATCH] radv: fix radv_layout_dcc_compressed() when image doesn't have DCC

2018-04-16 Thread Samuel Pitoiset
On 04/15/2018 08:52 PM, Juan A. Suarez Romero wrote: On Fri, 2018-04-13 at 13:55 -0700, Mark Janes wrote: Hi Samuel, When this patch is applied directly to the 18.0 branch, I get a mesa compile error: radv_image.c:1175:9: error: implicit declaration of function ‘radv_image_has_dcc’; did you

Re: [Mesa-dev] [PATCH 1/3] radeonsi: implement mechanism for IBs without partial flushes at the end (v6)

2018-04-16 Thread Christian König
Am 15.04.2018 um 20:46 schrieb Nicolai Hähnle: On 07.04.2018 04:31, Marek Olšák wrote: From: Marek Olšák (This patch doesn't enable the behavior. It will be enabled in a later commit.) Draw calls from multiple IBs can be executed in parallel. v2: do emit partial flushes on SI v3: invalidate

Re: [Mesa-dev] [PATCH 01/10] radv: disable prediction only if it has been enabled

2018-04-16 Thread Bas Nieuwenhuizen
Reviewed-by: Bas Niuwenhuizen for the series. Thanks for the cleanup. On Fri, Apr 13, 2018 at 7:14 PM, Samuel Pitoiset wrote: > When decompressing DCC we don't enable it, so it's useless > to disable it. This reduces the number of prediction packets > sent to the GPU when performing color decom

Re: [Mesa-dev] [PATCH 1/3] radeonsi: implement mechanism for IBs without partial flushes at the end (v6)

2018-04-16 Thread Nicolai Hähnle
On 16.04.2018 10:51, Christian König wrote: Am 15.04.2018 um 20:46 schrieb Nicolai Hähnle: On 07.04.2018 04:31, Marek Olšák wrote: From: Marek Olšák (This patch doesn't enable the behavior. It will be enabled in a later commit.) Draw calls from multiple IBs can be executed in parallel. v2:

Re: [Mesa-dev] [PATCH] dri3: Prevent multiple freeing of buffers.

2018-04-16 Thread Sergii Romantsov
Hello (ping) Thomas and Daniel, any more suggestions? As i can see Eero has done a test-run and v2 also looks good. As alternative solution we also may try to call '*dri3_fence_await(draw->conn, draw, buffer)'* with '*draw*'-parameter as '*NULL'.* What do you think? On Tue, Apr 10, 2018 at 11:10

Re: [Mesa-dev] [PATCH v2] anv: fix number of planes for depth & stencil

2018-04-16 Thread Juan A. Suarez Romero
On Thu, 2018-04-12 at 14:54 -0700, Lionel Landwerlin wrote: > We're not counting correctly with depth & stencil images. > > Additionally we need to move an assert that is meant just for color > attachments. > > v2: Move an assert() (Reported by Craig) > Change aspect mask checks (Francesco) >

Re: [Mesa-dev] [Mesa-stable] [PATCH] ac/nir: Make the GFX9 buffer size fix apply to image loads/atomics too.

2018-04-16 Thread Juan A. Suarez Romero
On Mon, 2018-04-16 at 00:09 +0200, Bas Nieuwenhuizen wrote: > No clue how I missed those ... > > Fixes: 4503ff760c "ac/nir: Add workaround for GFX9 buffer views." > CC: > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105320 Hi, Bas! This commit is a candidate for next 17.3 and 18.0 st

[Mesa-dev] [Bug 106074] radv: si_scissor_from_viewport returns incorrect result when using half-pixel viewport offset

2018-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=106074 Bug ID: 106074 Summary: radv: si_scissor_from_viewport returns incorrect result when using half-pixel viewport offset Product: Mesa Version: git Hardware: Other

[Mesa-dev] [Bug 106074] radv: si_scissor_from_viewport returns incorrect result when using half-pixel viewport offset

2018-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=106074 soredake changed: What|Removed |Added CC||fds...@krutt.org -- You are receiving this

Re: [Mesa-dev] [Mesa-stable] [PATCH] mesa: call DrawBuffer(s) driver hook in update_framebuffer for windows-system FB

2018-04-16 Thread Timothy Arceri
On 16/04/18 18:19, Juan A. Suarez Romero wrote: On Fri, 2018-04-13 at 08:17 -0600, Brian Paul wrote: Hi Brain, are you happy if we push this in the meantime? It seems to impact a number of apps running on Wine? I don't have time to look at it myself right now. So if it looks good to you and y

Re: [Mesa-dev] [Mesa-stable] [PATCH] mesa: call DrawBuffer(s) driver hook in update_framebuffer for windows-system FB

2018-04-16 Thread Juan A. Suarez Romero
On Mon, 2018-04-16 at 22:17 +1000, Timothy Arceri wrote: > > Thanks for the feedback. J.A. > On 16/04/18 18:19, Juan A. Suarez Romero wrote: > > > On Fri, 2018-04-13 at 08:17 -0600, Brian Paul wrote: > > > > Hi Brain, are you happy if we push this in the meantime? It seems to > > >

[Mesa-dev] [PATCH v7 01/35] st/glsl_to_nir: run lower_output_reads on !PIPE_CAP_TGSI_CAN_READ_OUTPUTS

2018-04-16 Thread Karol Herbst
this is required for Drivers which don't allow reading from outputs. Reviewed-by: Timothy Arceri Signed-off-by: Karol Herbst --- src/mesa/state_tracker/st_glsl_to_nir.cpp | 6 ++ 1 file changed, 6 insertions(+) diff --git a/src/mesa/state_tracker/st_glsl_to_nir.cpp b/src/mesa/state_tracke

[Mesa-dev] [PATCH v7 07/35] nouveau: add env var to make nir default

2018-04-16 Thread Karol Herbst
v2: allow for non debug builds as well v3: move reading out env var more global disable tg4 with multiple offsets with nir disable caps for 64 bit types v6: nv50 support disable MS images disable bindless textures Signed-off-by: Karol Herbst --- src/gallium/drivers/nouveau/nouvea

[Mesa-dev] [PATCH v7 00/35] Nouveau NIR support

2018-04-16 Thread Karol Herbst
Changes to v6: * fixed automake build * fixed shader cache collision with TGSI shaders * fixed handling of inot * fixed location of images * fixed load_output of fragment shaders (FBFETCH) * added load_barycentric_sample handling * some preparation for bindless_texture support There will be some f

[Mesa-dev] [PATCH v7 02/35] nv50/ir/ra: Fix copying compound for moves

2018-04-16 Thread Karol Herbst
From: Connor Abbott In order to reduce moves when coalescing multiple registers into a larger register, RA will try to coalesce MERGE instructions with their definitions. For example, for something like this in GLSL: uint a = ...; uint b = ...; uint64 x = packUint2x32(a, b); The compiler will t

[Mesa-dev] [PATCH v7 04/35] nvir: move common converter code in base class

2018-04-16 Thread Karol Herbst
v2: remove TGSI related bits Signed-off-by: Karol Herbst Reviewed-by: Pierre Moreau --- src/gallium/drivers/nouveau/Makefile.sources | 2 + .../nouveau/codegen/nv50_ir_from_common.cpp| 107 + .../drivers/nouveau/codegen/nv50_ir_from_common.h | 58 ++

[Mesa-dev] [PATCH v7 06/35] nouveau: add support for nir

2018-04-16 Thread Karol Herbst
not all those nir options are actually required, it just made the work a little easier. v2: fix asserts parse compute shaders don't lower bitfield_insert v3: fix memory leak v4: don't lower fmod32 v5: set lower_all_io_to_temps to false fix memory leak because we take over ownership of

[Mesa-dev] [PATCH v7 03/35] nvir: print the shader type when dumping headers

2018-04-16 Thread Karol Herbst
this makes debugging the shader header a little easier Signed-off-by: Karol Herbst Acked-by: Pierre Moreau --- src/gallium/drivers/nouveau/nvc0/nvc0_program.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_program.c b/src/gallium/drivers/nouveau/nvc0/

[Mesa-dev] [PATCH v7 05/35] nvir: add lowering helper

2018-04-16 Thread Karol Herbst
this is mostly usefull for lazy IR converters not wanting to deal with 64 bit lowering and other illegal stuff v5: also handle SAT v6: rename type variables fixed lowering of NEG add lowering of NOT Signed-off-by: Karol Herbst --- src/gallium/drivers/nouveau/Makefile.sources | 2

[Mesa-dev] [PATCH v7 11/35] nvir/nir: add nir type helper functions

2018-04-16 Thread Karol Herbst
v4: treat imul as unsigned v5: remove pointless !! v7: inot is unsigned as well Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 116 + 1 file changed, 116 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp

[Mesa-dev] [PATCH v7 08/35] nouveau: fix nir and TGSI shader cache collision

2018-04-16 Thread Karol Herbst
Signed-off-by: Karol Herbst --- src/gallium/drivers/nouveau/nouveau_screen.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/nouveau_screen.c b/src/gallium/drivers/nouveau/nouveau_screen.c index 2598c78a45b..655d2d090f6 100644 --- a/src/galliu

[Mesa-dev] [PATCH v7 10/35] nvir/nir: track defs and provide easy access functions

2018-04-16 Thread Karol Herbst
v2: add helper function for indirects v4: add new getIndirect overload for easier use v5: use getSSA for ssa values we can just create the values for unassigned registers in getSrc v6: always create at least 32 bit values Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_fr

[Mesa-dev] [PATCH v7 13/35] nvir/nir: add loadFrom and storeTo helpler

2018-04-16 Thread Karol Herbst
Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 72 ++ 1 file changed, 72 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp index 1d1c4526d2b..00

[Mesa-dev] [PATCH v7 12/35] nvir/nir: run assignSlots

2018-04-16 Thread Karol Herbst
v2: add support for geometry shaders set idx add some missing mappings fix for 64bit inputs/outputs fix up some FP color output index messup parse centroid flag v3: fix arrays in outputs as well fix input/ouput size calculation for tessellation shaders v4: add getSlotAddress

[Mesa-dev] [PATCH v7 15/35] nvir/nir: implement CFG handling

2018-04-16 Thread Karol Herbst
v6: fix loops with blocks at the end nothing points to skip blocks with no instructions and no predecessors Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 270 - 1 file changed, 268 insertions(+), 2 deletions(-) diff --git a/src/gall

[Mesa-dev] [PATCH v7 16/35] nvir/nir: implement nir_load_const_instr

2018-04-16 Thread Karol Herbst
Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 18 ++ 1 file changed, 18 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp index c2512b01d5a..f4

[Mesa-dev] [PATCH v7 14/35] nvir/nir: parse NIR shader info

2018-04-16 Thread Karol Herbst
v2: parse a few more fields v3: add special handling for GL_ISOLINES Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 60 ++ 1 file changed, 60 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gall

[Mesa-dev] [PATCH v7 09/35] nvir/nir: run some passes to make the conversion easier

2018-04-16 Thread Karol Herbst
v2: add constant_folding v6: print non final NIR only for verbose debugging Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 39 ++ 1 file changed, 39 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/s

[Mesa-dev] [PATCH v7 21/35] nvir/nir: implement load_(interpolated_)input/output

2018-04-16 Thread Karol Herbst
v3: and load_output v4: use smarter getIndirect helper use new getSlotAddress helper v5: don't use const_offset directly fix for indirects v6: add support for interpolateAt v7: fix compiler warnings add load_barycentric_sample handle load_output for fragment shaders Signed-off-by:

[Mesa-dev] [PATCH v7 25/35] nvir/nir: implement nir_instr_type_tex

2018-04-16 Thread Karol Herbst
a lot of those fields are not valid for a lot of tex ops. Not quite sure if it's worth the effort to check for those or just keep it like that. It seems to kind of work. v2: reworked offset handling add tex support with indirect R/S arguments handle GLSL_SAMPLER_DIM_EXTERNAL drop refer

[Mesa-dev] [PATCH v7 22/35] nvir/nir: implement intrinsic_discard(_if)

2018-04-16 Thread Karol Herbst
Signed-off-by: Karol Herbst --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 14 ++ 1 file changed, 14 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp index 740dee5c95a..40bc

[Mesa-dev] [PATCH v7 19/35] nvir/nir: implement nir_intrinsic_load_uniform

2018-04-16 Thread Karol Herbst
v2: use new getIndirect helper fixes symbols for 64 bit types v4: use smarter getIndirect helper simplify address calculation use loadFrom helper Signed-off-by: Karol Herbst --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 10 ++ 1 file changed, 10 insertions(+)

[Mesa-dev] [PATCH v7 31/35] nvir/nir: implement ssbo intrinsics

2018-04-16 Thread Karol Herbst
v4: use loadFrom helper v5: support indirect buffer access Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 90 ++ 1 file changed, 90 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/driver

[Mesa-dev] [PATCH v7 34/35] nvir/nir: implement load_per_vertex_output

2018-04-16 Thread Karol Herbst
v4: use smarter getIndirect helper use new getSlotAddress helper v5: use loadFrom helper Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 23 ++ 1 file changed, 23 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_

[Mesa-dev] [PATCH v7 23/35] nvir/nir: implement loading system values

2018-04-16 Thread Karol Herbst
v2: support more sys values fixed a bug where for multi component reads all values ended up in x v3: add load_patch_vertices_in v4: add subgroup stuff v5: add helper invocation v6: fix loading 64 bit system values Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.c

[Mesa-dev] [PATCH v7 27/35] nvir/nir: implement vote and ballot

2018-04-16 Thread Karol Herbst
v2: add vote_eq support use the new subop intrinsic helper add ballot v3: add read_(first_)invocation Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 42 ++ 1 file changed, 42 insertions(+) diff --git a/src/gallium/drivers/nouveau

[Mesa-dev] [PATCH v7 20/35] nvir/nir: implement nir_intrinsic_store_(per_vertex_)output

2018-04-16 Thread Karol Herbst
v3: add workaround for RA issues indirects have to be multiplied by 0x10 fix indirect access v4: use smarter getIndirect helper use storeTo helper v5: don't use const_offset directly Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 46 +

[Mesa-dev] [PATCH v7 26/35] nvir/nir: add getOperation for intrinsics

2018-04-16 Thread Karol Herbst
v7: don't assert in default case Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 22 ++ 1 file changed, 22 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_

[Mesa-dev] [PATCH v7 18/35] nvir/nir: implement nir_alu_instr handling

2018-04-16 Thread Karol Herbst
v2: user bitfield_insert instead of bfi rework switch helper macros remove some lowering code (LoweringHelper is now used for this) v3: add pack_half_2x16_split add unpack_half_2x16_split_x/y v5: replace first argument with nullptr in loadImm calls prefer getSSA over getScratch Sig

[Mesa-dev] [PATCH v7 35/35] nvir/nir: implement intrinsic shader_clock

2018-04-16 Thread Karol Herbst
Signed-off-by: Karol Herbst --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 8 1 file changed, 8 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp index dd73acb2366..d9ea665b9e1

[Mesa-dev] [PATCH v7 32/35] nvir/nir: implement images

2018-04-16 Thread Karol Herbst
v3: fix compiler warnings v4: use loadFrom helper v5: fix signed min/max v6: set tex mask add support for indirect image access set cache mode v7: make compatible with 884d27bcf688d36c3bbe01bceca525595add3b33 rework the whole deref thing to prepare for bindless Signed-off-by: Karol Her

[Mesa-dev] [PATCH v7 17/35] nvir/nir: add skeleton for nir_intrinsic_instr

2018-04-16 Thread Karol Herbst
Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp| 17 + 1 file changed, 17 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp index f4f844021a2..8a

[Mesa-dev] [PATCH v7 28/35] nvir/nir: implement variable indexing

2018-04-16 Thread Karol Herbst
we store those arrays in local memory and reserve some space for each of the arrays. The arrays are stored in a packed format, because we know quite easily the context of each index. We don't do that in TGSI so far. This causes various issues to come up in the MemoryOpt pass, because ld/st with in

[Mesa-dev] [PATCH v7 29/35] nvir/nir: implement geometry shader nir_intrinsics

2018-04-16 Thread Karol Herbst
v4: use smarter getIndirect helper use new getSlotAddress helper use loadFrom helper Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 27 ++ 1 file changed, 27 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_

[Mesa-dev] [PATCH v7 24/35] nvir/nir: implement nir_ssa_undef_instr

2018-04-16 Thread Karol Herbst
v2: use mkOp Signed-off-by: Karol Herbst --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 13 + 1 file changed, 13 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp index 4606

[Mesa-dev] [PATCH v7 30/35] nvir/nir: implement nir_intrinsic_load_ubo

2018-04-16 Thread Karol Herbst
v4: use loadFrom helper Signed-off-by: Karol Herbst --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 14 ++ 1 file changed, 14 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cp

[Mesa-dev] [PATCH v7 33/35] nvir/nir: add memory barriers

2018-04-16 Thread Karol Herbst
v5: add more barrier intrinsics Signed-off-by: Karol Herbst --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 19 +++ 1 file changed, 19 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_f

Re: [Mesa-dev] [PATCH] nir: fix ir_binop_gequal glsl_to_nir conversion

2018-04-16 Thread Erico Nunes
On Sun, Apr 15, 2018 at 2:30 AM, Jason Ekstrand wrote: > On April 14, 2018 12:43:35 Connor Abbott wrote: > I think that it's probably impractical to use this path, and we should > probably delete it. There are just too many optimizations, e.g. in > nir_opt_algebraic and lowering passes that assum

[Mesa-dev] [PATCH 1/2] vulkan: Update the XML and headers to 1.1.73

2018-04-16 Thread Jason Ekstrand
--- include/vulkan/vulkan_core.h | 2 +- src/vulkan/registry/vk.xml | 10 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/include/vulkan/vulkan_core.h b/include/vulkan/vulkan_core.h index ed0d596..2cafcdd 100644 --- a/include/vulkan/vulkan_core.h +++ b/include/vulkan/v

[Mesa-dev] [PATCH 2/2] anv, radv: Drop XML workarounds for VK_ANDROID_native_buffer

2018-04-16 Thread Jason Ekstrand
--- src/amd/vulkan/radv_extensions.py | 7 +-- src/intel/vulkan/anv_extensions_gen.py | 7 +-- 2 files changed, 2 insertions(+), 12 deletions(-) diff --git a/src/amd/vulkan/radv_extensions.py b/src/amd/vulkan/radv_extensions.py index db37d61..099cae7 100644 --- a/src/amd/vulkan/radv

Re: [Mesa-dev] [PATCH 1/2] vulkan: Update the XML and headers to 1.1.73

2018-04-16 Thread Samuel Pitoiset
Acked-by: Samuel Pitoiset On 04/16/2018 04:38 PM, Jason Ekstrand wrote: --- include/vulkan/vulkan_core.h | 2 +- src/vulkan/registry/vk.xml | 10 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/include/vulkan/vulkan_core.h b/include/vulkan/vulkan_core.h index ed

Re: [Mesa-dev] [PATCH 2/2] anv, radv: Drop XML workarounds for VK_ANDROID_native_buffer

2018-04-16 Thread Samuel Pitoiset
Reviewed-by: Samuel Pitoiset On 04/16/2018 04:38 PM, Jason Ekstrand wrote: --- src/amd/vulkan/radv_extensions.py | 7 +-- src/intel/vulkan/anv_extensions_gen.py | 7 +-- 2 files changed, 2 insertions(+), 12 deletions(-) diff --git a/src/amd/vulkan/radv_extensions.py b/src/amd

Re: [Mesa-dev] [PATCH v2] anv: fix number of planes for depth & stencil

2018-04-16 Thread Lionel Landwerlin
Thanks a lot Juan, it looks all good to me :) On 16/04/18 04:09, Juan A. Suarez Romero wrote: On Thu, 2018-04-12 at 14:54 -0700, Lionel Landwerlin wrote: We're not counting correctly with depth & stencil images. Additionally we need to move an assert that is meant just for color attachments.

Re: [Mesa-dev] [PATCH 1/3] radeonsi: implement mechanism for IBs without partial flushes at the end (v6)

2018-04-16 Thread Marek Olšák
On Mon, Apr 16, 2018, 4:52 AM Christian König < ckoenig.leichtzumer...@gmail.com> wrote: > Am 15.04.2018 um 20:46 schrieb Nicolai Hähnle: > > On 07.04.2018 04:31, Marek Olšák wrote: > >> From: Marek Olšák > >> > >> (This patch doesn't enable the behavior. It will be enabled in a later > >> commit

[Mesa-dev] [Bug 106074] radv: si_scissor_from_viewport returns incorrect result when using half-pixel viewport offset

2018-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=106074 --- Comment #1 from Philip Rebohle --- Created attachment 138867 --> https://bugs.freedesktop.org/attachment.cgi?id=138867&action=edit Proposed patch The attached patch fixes the issue in FF XIV. I'm not sure if that is entirely correct, but

Re: [Mesa-dev] [PATCH] nir: fix ir_binop_gequal glsl_to_nir conversion

2018-04-16 Thread Jason Ekstrand
On Mon, Apr 16, 2018 at 6:45 AM, Erico Nunes wrote: > On Sun, Apr 15, 2018 at 2:30 AM, Jason Ekstrand > wrote: > > On April 14, 2018 12:43:35 Connor Abbott wrote: > > I think that it's probably impractical to use this path, and we should > > probably delete it. There are just too many optimizat

[Mesa-dev] [PATCH 1/2] mesa: GL_EXT_texture_norm16 extension plumbing

2018-04-16 Thread Tapani Pälli
Patch enables use of short and unsigned short data for texture uploads, rendering and reading of framebuffers within the restrictions specified in GL_EXT_texture_norm16 spec. Patch also enables those 16bit format layout qualifiers listed in GL_NV_image_formats that depend on EXT_texture_norm16. S

[Mesa-dev] [PATCH 2/2] i965: enable EXT_texture_norm16 for i965

2018-04-16 Thread Tapani Pälli
Signed-off-by: Tapani Pälli --- src/mesa/drivers/dri/i965/intel_extensions.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri/i965/intel_extensions.c b/src/mesa/drivers/dri/i965/intel_extensions.c index 73a6c73f53..88a66e9e26 100644 --- a/src/mesa/drivers/dri/i965/intel_e

Re: [Mesa-dev] [PATCH 3/3] meson: Version libMesaOpenCL like autotools does

2018-04-16 Thread Aaron Watry
Yes, please. Fixes clover platform and device detection when installed in /usr/local/ using ocl-icd for me when building with meson. I think that was the last thing blocking me from switching over from autotools on the rest of my machines. Not familiar enough with the versioning/linking in meson,

Re: [Mesa-dev] [PATCH 1/2] mesa: GL_EXT_texture_norm16 extension plumbing

2018-04-16 Thread Ilia Mirkin
You never check EXT_texture_norm16 anywhere... is that right? Should probably respect that in the _mesa_is_es3_* helpers. Also what about shader support? I see no mention in the spec that these should be usable as images, except with NV_image_formats is enabled. You're just exposing them no matter

[Mesa-dev] [Bug 106074] radv: si_scissor_from_viewport returns incorrect result when using half-pixel viewport offset

2018-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=106074 gloriouseggr...@gmail.com changed: What|Removed |Added CC||gloriouseggr...@gmail.com --

Re: [Mesa-dev] [PATCH 1/2] intel/compiler: grf127 can not be dest when src and dest overlap in send

2018-04-16 Thread Chema Casanova
On 15/04/18 08:55, Matt Turner wrote: > On Wed, Apr 11, 2018 at 7:30 PM, Jose Maria Casanova Crespo > wrote: >> Implement at brw_eu_validate the restriction from Intel Broadwell PRM, vol >> 07, >> section "Instruction Set Reference", subsection "EUISA Instructions", Send >> Message (page 990): >>

Re: [Mesa-dev] [PATCH] swr: Remove unnecessary memset call

2018-04-16 Thread Kyriazis, George
Reviewed-By: George Kyriazis mailto:george.kyria...@intel.com>> On Apr 12, 2018, at 8:49 PM, Vlad Golovkin mailto:vlad.golovkin.m...@gmail.com>> wrote: Zeroing memory after calloc is not necessary. This also allows to avoid possible crash when allocation fails, because memset is called before

Re: [Mesa-dev] [PATCH 3/3] radeonsi: don't emit partial flushes for internal CS flushes only

2018-04-16 Thread Marek Olšák
On Sun, Apr 15, 2018 at 2:47 PM, Nicolai Hähnle wrote: > How much testing have you done with the radeon drm? It may be safer to > just skip that part of the changes. > Piglit on CIK. Marek ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https

[Mesa-dev] [Bug 106090] Compiling compute shader crashes RADV

2018-04-16 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=106090 Bug ID: 106090 Summary: Compiling compute shader crashes RADV Product: Mesa Version: 18.0 Hardware: Other OS: All Status: NEW Severity: normal

Re: [Mesa-dev] [PATCH] nir: fix ir_binop_gequal glsl_to_nir conversion

2018-04-16 Thread Jason Ekstrand
Pushed. Thanks and welcome to Mesa! On April 14, 2018 12:26:18 Jason Ekstrand wrote: Reviewed-by: Jason Ekstrand What driver is hitting this path? The !supports_ints path isn't used to my knowledge so if some driver has started using it, they're liable to find more bugs than just this one.

Re: [Mesa-dev] [PATCH v2] virgl: disable virgl when no 3D for virtio gpu.

2018-04-16 Thread Lepton Wu
On Thu, Apr 5, 2018 at 12:38 PM, Lepton Wu wrote: > If users are running mesa under old version of qemu or have turned off > GL at runtime, virtio gpu driver actually doesn't work. Adds a detection > here so mesa can fall back to software rendering. > > v2: > - move detection from loader to virgl

[Mesa-dev] [PATCH v2 3/3] nvc0: use a macro to write query result availability to a buffer

2018-04-16 Thread Rhys Perry
Both the availability and result paths shared a bit of code so they were marged. Signed-off-by: Rhys Perry --- src/gallium/drivers/nouveau/nvc0/mme/com9097.mme | 45 src/gallium/drivers/nouveau/nvc0/mme/com9097.mme.h | 34 ++ src/gallium/drivers/nouveau/nvc0/nvc0_macros.h |

[Mesa-dev] [PATCH v2 0/3] nvc0: Various improvements to nvc0_hw_get_query_result_resource

2018-04-16 Thread Rhys Perry
This patch set applies improvements related to the query buffer object functionality of the nvc0 driver. Changes in v2: - Increase space requirement in patch 3 to ensure there is room for fence emission. Rhys Perry (3): nvc0: set current bufctx to nvc0->bufctx at the end of nvc0_draw_vbo()

[Mesa-dev] [PATCH] nv50: Extract needed value bits without shifting them before calling bitcount

2018-04-16 Thread Vlad Golovkin
This can save one instruction since bitcount doesn't care about specific bits' positions. --- src/gallium/drivers/nouveau/nv50/nv50_screen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/nv50/nv50_screen.c b/src/gallium/drivers/nouveau/nv50/nv50_s

[Mesa-dev] [PATCH] glsl_to_tgsi: try harder to lower unsupported ir_binop_vector_extract

2018-04-16 Thread Marek Olšák
From: Marek Olšák Cc: 18.0 --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 5 + 1 file changed, 5 insertions(+) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp index 01a58d7d2c6..b321112cf88 100644 --- a/src/mesa/state_tracker/st_glsl_

Re: [Mesa-dev] [PATCH 3/3] radeonsi: don't emit partial flushes for internal CS flushes only

2018-04-16 Thread Nicolai Hähnle
On 16.04.2018 20:44, Marek Olšák wrote: On Sun, Apr 15, 2018 at 2:47 PM, Nicolai Hähnle > wrote: How much testing have you done with the radeon drm? It may be safer to just skip that part of the changes. Piglit on CIK. Probably good enough. May be worth che

Re: [Mesa-dev] [PATCH 1/3] meson: Define NDEBUG for non-debug-builds

2018-04-16 Thread Dylan Baker
Quoting Jan Alexander Steffens (heftig) (2018-04-14 10:23:20) > This is for parity with autotools. We were suddenly getting assertion > failures after switching to meson, see [1]. > > [1]: https://bugs.archlinux.org/task/58218 > > Signed-off-by: Jan Alexander Steffens (heftig) > --- > meson.bui

Re: [Mesa-dev] [PATCH 2/3] meson: Add library versions to swr drivers

2018-04-16 Thread Dylan Baker
Quoting Jan Alexander Steffens (heftig) (2018-04-14 10:23:21) > This is for parity with autotools. > > Signed-off-by: Jan Alexander Steffens (heftig) > --- > src/gallium/drivers/swr/meson.build | 4 > 1 file changed, 4 insertions(+) > > diff --git a/src/gallium/drivers/swr/meson.build > b

Re: [Mesa-dev] [PATCH 3/3] meson: Version libMesaOpenCL like autotools does

2018-04-16 Thread Dylan Baker
Quoting Jan Alexander Steffens (heftig) (2018-04-14 10:23:22) > This is for parity with autotools. It names the library > libMesaOpenCL.so.1.0.0 and points mesa.icd to the .1 symlink. > > opencl_version now matches configure.ac's OPENCL_VERSION. > > Signed-off-by: Jan Alexander Steffens (heftig)

Re: [Mesa-dev] [PATCH 2/2] anv, radv: Drop XML workarounds for VK_ANDROID_native_buffer

2018-04-16 Thread Dylan Baker
Quoting Jason Ekstrand (2018-04-16 07:38:53) > --- > src/amd/vulkan/radv_extensions.py | 7 +-- > src/intel/vulkan/anv_extensions_gen.py | 7 +-- > 2 files changed, 2 insertions(+), 12 deletions(-) > > diff --git a/src/amd/vulkan/radv_extensions.py > b/src/amd/vulkan/radv_extensions

Re: [Mesa-dev] [PATCH 1/2] bin/install_megadrivers: fix DESTDIR and -D*-path

2018-04-16 Thread Dylan Baker
Quoting Dylan Baker (2018-04-13 08:46:46) > Quoting Dylan Baker (2018-04-09 14:02:51) > > This fixes -Ddri-drivers-path, -Dvdpau-libs-path, etc. with DESTDIR when > > those paths are absolute. Currently due to the way python's os.path.join > > handles absolute paths these will ignore DESTDIR, which

Re: [Mesa-dev] [PATCH] clover: Fix host access validation for sub-buffer creation

2018-04-16 Thread Francisco Jerez
Aaron Watry writes: > From CL 1.2 Section 5.2.1: > CL_INVALID_VALUE if buffer was created with CL_MEM_HOST_WRITE_ONLY and > flags specify CL_MEM_HOST_READ_ONLY , or if buffer was created with > CL_MEM_HOST_READ_ONLY and flags specify CL_MEM_HOST_WRITE_ONLY , or if > buffer was c

  1   2   >