[Mesa-dev] [PATCH v2 14/31] nvir/nir: implement nir_load_const_instr

2018-01-04 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 20 1 file changed, 20 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH v2 11/31] nvir/nir: run assignSlots

2018-01-04 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 Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp

[Mesa-dev] [PATCH v2 10/31] nvir/nir: use lowering helper

2018-01-04 Thread Karol Herbst
this helps with a bunch of piglit tests testing 64 bit types Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 5 + 1 file changed, 5 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp

[Mesa-dev] [PATCH v2 08/31] nvir/nir: track defs and provide easy access functions

2018-01-04 Thread Karol Herbst
v2: add helper function for indirects Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 125 + 1 file changed, 125 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/g

[Mesa-dev] [PATCH v2 13/31] nvir/nir: implement CFG handling

2018-01-04 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 255 - 1 file changed, 253 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/c

[Mesa-dev] [PATCH v2 12/31] nvir/nir: parse NIR shader info

2018-01-04 Thread Karol Herbst
v2: parse a few more fields Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 55 ++ 1 file changed, 55 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/n

[Mesa-dev] [PATCH v2 09/31] nvir/nir: add nir type helper functions

2018-01-04 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../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 b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH v2 07/31] nvir/nir: run some passes to make the conversion easier

2018-01-04 Thread Karol Herbst
v2: add constant_folding Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 40 ++ 1 file changed, 40 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/n

[Mesa-dev] [PATCH v2 01/31] st/nir: treat tess shader input/outputs the same as geom shaders

2018-01-04 Thread Karol Herbst
this is enough to get tessellation working in Unigine heaven Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/mesa/state_tracker/st_glsl_to_nir.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/mesa/state_tracker/st_glsl_to_nir.cpp b/src/mesa/state_t

[Mesa-dev] [PATCH v2 04/31] nvir: add lowering helper

2018-01-04 Thread Karol Herbst
this is mostly usefull for lazy IR converters not wanting to deal with 64 bit lowering and other illegal stuff Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/Makefile.sources | 2 + .../nouveau/codegen/nv50_ir_lowering_helper.cpp

[Mesa-dev] [PATCH v2 02/31] nvir: print the shader type when dumping headers

2018-01-04 Thread Karol Herbst
this makes debugging the shader header a little easier Signed-off-by: Karol Herbst <kher...@redhat.com> --- 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/nouvea

[Mesa-dev] [PATCH v2 00/31] Nir support for Nouveau

2018-01-04 Thread Karol Herbst
(related to above mentioned packing issue) * glsl-4.20.execution.vs_in * some variable-indexing issues related to unaligned memory accesses * some geometry shader fails Karol Herbst (31): st/nir: treat tess shader input/outputs the same as geom shaders nvir: print the shader type when dumping headers

[Mesa-dev] [PATCH v2 05/31] nvc0: add support for NIR

2018-01-04 Thread Karol Herbst
bitfield_insert Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/Makefile.sources | 1 + src/gallium/drivers/nouveau/codegen/nv50_ir.cpp| 3 + src/gallium/drivers/nouveau/codegen/nv50_ir.h | 1 + .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp

[Mesa-dev] [PATCH v2 06/31] nvc0/debug: add env var to make nir default

2018-01-04 Thread Karol Herbst
v2: allow for non debug builds as well Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/nvc0/nvc0_screen.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c b/src/gallium/drivers/n

[Mesa-dev] [PATCH v2 03/31] nvir: move common converter code in base class

2018-01-04 Thread Karol Herbst
v2: remove TGSI related bits Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/Makefile.sources | 2 + .../nouveau/codegen/nv50_ir_from_common.cpp| 107 + .../drivers/nouveau/codegen/nv50_ir_from_common.h

Re: [Mesa-dev] [PATCH v3 17/20] st/glsl_to_nir/radeonsi: enable tessellation shaders

2018-01-03 Thread Karol Herbst
in case v3 doesn't get into mesa, could you extract the src/mesa/state_tracker/st_glsl_to_nir.cpp change into a seperate patch and just push that one? I kind of needs this as well and have a patch doing exactly this in my repository as well. A patch with only this would be Reviewed-by: Karol

Re: [Mesa-dev] [PATCH 02/22] nvir: move common converter code in base class

2017-12-21 Thread Karol Herbst
the glsl values to the tgsi ones with the code I wrote for assignSlots and because the conversion from TGSI to NVIR already existed, I just used that for now. > On Dec 21, 2017 11:26 AM, "Karol Herbst" <kher...@redhat.com> wrote: >> >> On Thu, Dec 21, 2017 at 5:2

Re: [Mesa-dev] [PATCH 02/22] nvir: move common converter code in base class

2017-12-21 Thread Karol Herbst
On Thu, Dec 21, 2017 at 5:21 PM, Ilia Mirkin <imir...@alum.mit.edu> wrote: > On Thu, Dec 21, 2017 at 10:51 AM, Karol Herbst <kher...@redhat.com> wrote: >> this is more or less a todo list of things I should move elsewhere. Not all >> of >> it should be actual

Re: [Mesa-dev] [PATCH 00/22] Nir support for Nouveau

2017-12-21 Thread Karol Herbst
uhm, actually that should have been marked as a RFC, sorry for that. On Thu, Dec 21, 2017 at 4:51 PM, Karol Herbst <kher...@redhat.com> wrote: > Plans are to get SPIR-V support for Nouveau with a cheap way. Before that I > was looking into Pierres work on his direct SPIR-V to nvir pas

[Mesa-dev] [PATCH 21/22] nvir/nir: implement vote

2017-12-21 Thread Karol Herbst
TODO: there is more Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 16 1 file changed, 16 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/c

[Mesa-dev] [PATCH 22/22] nvir/nir: implement variable indexing

2017-12-21 Thread Karol Herbst
with indirects aren't guarenteed to be aligned to 0x10 anymore. Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 58 ++ 1 file changed, 58 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.

[Mesa-dev] [PATCH 20/22] nvir/nir: implement nir_instr_type_tex

2017-12-21 Thread Karol Herbst
TODO: 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. Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp

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

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 15 +++ 1 file changed, 15 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 19/22] nvir/nir: implement nir_ssa_undef_instr

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 15 +++ 1 file changed, 15 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 14/22] nvir/nir: implement nir_intrinsic_load_input

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 30 ++ 1 file changed, 30 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 18/22] nvir/nir: implement loading system values

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 26 ++ 1 file changed, 26 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 15/22] nvir/nir: run assignSlots

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 427 + 1 file changed, 427 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 10/22] nvir/nir: add skeleton for nir_intrinsic_instr

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../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_n

[Mesa-dev] [PATCH 16/22] nvir/nir: parse NIR shader info

2017-12-21 Thread Karol Herbst
TODO: this is far from being complete, but at least this let the basics things work already. Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 26 ++ 1 file changed, 26 insertions(+) diff --git a/src/gallium/d

[Mesa-dev] [PATCH 11/22] nvir/nir: implement nir_alu_instr handling

2017-12-21 Thread Karol Herbst
code duplication can be eliminated through templates Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 524 - 1 file changed, 523 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/c

[Mesa-dev] [PATCH 09/22] nvir/nir: implement nir_load_const_instr

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 20 1 file changed, 20 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 13/22] nvir/nir: implement nir_intrinsic_store_output

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 43 ++ 1 file changed, 43 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 12/22] nvir/nir: implement nir_intrinsic_load_uniform

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp| 21 + 1 file changed, 21 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 07/22] nvir/nir: add nir type helper functions

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../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 b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 06/22] nvir/nir: track defs and provide easy access functions

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 108 + 1 file changed, 108 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 08/22] nvir/nir: implement CFG handling

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 255 - 1 file changed, 253 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/c

[Mesa-dev] [PATCH 05/22] nvir/nir: run some passes to make the conversion easier

2017-12-21 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_from_nir.cpp | 37 ++ 1 file changed, 37 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_nir.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_n

[Mesa-dev] [PATCH 04/22] nvc0/debug: add env var to make nir default

2017-12-21 Thread Karol Herbst
can't be turned on for release builds for now. Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/nvc0/nvc0_screen.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c b/src/gallium/d

[Mesa-dev] [PATCH 03/22] nvc0: add support for NIR

2017-12-21 Thread Karol Herbst
not all those nir options are actually required, it just made the work a little easier. TODO: there is a little memory leak, because the nir shader is duplicated twice. this has to be done though, we just need to clean it up properly Signed-off-by: Karol Herbst <kher...@redhat.com> --

[Mesa-dev] [PATCH 02/22] nvir: move common converter code in base class

2017-12-21 Thread Karol Herbst
this is more or less a todo list of things I should move elsewhere. Not all of it should be actually moved, but... Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/Makefile.sources | 2 + .../nouveau/codegen/nv50_ir_from_common.cpp

[Mesa-dev] [PATCH 00/22] Nir support for Nouveau

2017-12-21 Thread Karol Herbst
on: * Geometry shaders * UBOs ./piglit run -x glx -x egl -x streaming-texture-leak -x max-texture-size tests/gpu.py: [26073/26073] skip: 1574, pass: 13451, warn: 9, fail: 5287, crash: 5752 Note: a lot of crashes are geometry/tesselation stuff hitting asserts. Karol Herbst (22): nvir: print

[Mesa-dev] [PATCH 01/22] nvir: print the shader type when dumping headers

2017-12-21 Thread Karol Herbst
this makes debugging a little easier Signed-off-by: Karol Herbst <kher...@redhat.com> --- 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/nvc0_program.c

Re: [Mesa-dev] [Nouveau] [PATCH] gm107/ir: use lane 0 for manual textureGrad handling

2017-12-21 Thread Karol Herbst
tex->setSrc(0, arr); >> + if (i->tex.target.isShadow()) >> +tex->setSrc(array + dim, shadow); >> + } >>for (c = 0; c < dim; ++c) >> tex->setSrc(c + array, src[c]); >> + // broadcast results from la

Re: [Mesa-dev] [PATCH] nvir/nvc0: fix CVT lowering for dType == sType

2017-12-05 Thread Karol Herbst
uhh, seems like this code isn't in master yet, so ignore this please. On Tue, Dec 5, 2017 at 3:17 PM, Karol Herbst <kher...@redhat.com> wrote: > The lowering code can't really handle that situation well and we just get away > with converting it to OP_MOV in this case. > > Si

[Mesa-dev] [PATCH] nvir/nvc0: fix CVT lowering for dType == sType

2017-12-05 Thread Karol Herbst
The lowering code can't really handle that situation well and we just get away with converting it to OP_MOV in this case. Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_lowering_nvc0.cpp | 5 + 1 file changed, 5 insertions(+) diff

[Mesa-dev] [PATCH 1/2] nvir/gm107: iterate over all defs in SchedDataCalculatorGM107::findFirstUse

2017-12-05 Thread Karol Herbst
In the sched data calculator we have to track first use of defs by iterating over all defs of an instruction, not just the first one. Signed-off-by: Karol Herbst <kher...@redhat.com> --- .../drivers/nouveau/codegen/nv50_ir_emit_gm107.cpp | 26 -- 1 file changed, 14 inse

[Mesa-dev] [PATCH 2/2] nvir/gm107: consider FILE_FLAGS dependencies in SchedDataCalculatorGM107

2017-12-05 Thread Karol Herbst
Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gm107.cpp | 11 ++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gm107.cpp b/src/gallium/drivers/nouveau/c

Re: [Mesa-dev] [PATCH] nvir: Always split 64-bit IMAD/IMUL operations

2017-12-05 Thread Karol Herbst
perations" > Signed-off-by: Pierre Moreau <pierre.mor...@free.fr> Reviewed-by: Karol Herbst <kher...@redhat.com> yeah, this is totally required to do in any case. > --- > src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp | 2 +- > 1 file changed, 1 insertion(+)

[Mesa-dev] [PATCH v2] nv50/ir: rework the madsp subop handling

2017-12-02 Thread Karol Herbst
From: Karol Herbst <kher...@redhat.com> Creating correct SubOps for OP_MADSP wasn't easy, because devs needed to know the proper values for each data type. Also the third source doesn't know any explicit signess and the current code tried to work around this fact. To make the cr

[Mesa-dev] [PATCH] nv50/ir: rework the madsp subop handling

2017-11-30 Thread Karol Herbst
the data type out of 32, 24 and 16L Now: bits 0-1 choose the data type out of 32, 24 and 16L This change also lead to an additional << 2 shift in the emmiter for src2 Signed-off-by: Karol Herbst <kher...@redhat.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir

Re: [Mesa-dev] [PATCH v2 2/2] main/format: skip format conversion if src and dst format are equal

2017-10-08 Thread Karol Herbst
org> wrote: > From: Karol Herbst <karolher...@gmail.com> > > Fixes 'KHR-GL45.copy_image.functional' on Nouveau and i965. > > v2: (by Kenneth Graunke) > Rewrite patch according to Jason Ekstrand's review feedback. > This makes it handle differing strides, which i965

Re: [Mesa-dev] [Mesa-stable] [PATCH] st/query: init result data with 0

2017-08-29 Thread Karol Herbst
gt; Marek > > On Sat, Aug 26, 2017 at 1:15 AM, Karol Herbst <karolher...@gmail.com> wrote: >> otherwise the result might contain random data. >> >> fixes on nvc0: >> * KHR-GL45.pipeline_statistics_qu

[Mesa-dev] [PATCH] nvc0/query: write 0 to pipeline_statistics.cs_invocations

2017-08-27 Thread Karol Herbst
-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/nvc0/nvc0_query_hw.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_query_hw.c b/src/gallium/drivers/nouveau/nvc0/nvc0_query_hw.c index 0991af872b..d8d82de865 100644 ---

[Mesa-dev] [PATCH] gallium: add PIPE_SHADER_CAP_MAX_VARYINGS

2017-08-27 Thread Karol Herbst
this way Nouveau can report 128 inputs, but only 124 varyings. Fixes: 'KHR-GL45.limits.max_fragment_input_components' Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/auxiliary/gallivm/lp_bld_limits.h| 1 + src/gallium/auxiliary/tgsi/tgsi_exec.h | 1

Re: [Mesa-dev] [PATCH] st/query: init result data with 0

2017-08-26 Thread Karol Herbst
On Sat, Aug 26, 2017 at 3:36 AM, Ilia Mirkin <imir...@alum.mit.edu> wrote: > On Fri, Aug 25, 2017 at 8:23 PM, Karol Herbst <karolher...@gmail.com> wrote: >> On Sat, Aug 26, 2017 at 1:38 AM, Ilia Mirkin <imir...@alum.mit.edu> wrote: >>> On Fri, Aug 25, 201

Re: [Mesa-dev] [PATCH] st/query: init result data with 0

2017-08-25 Thread Karol Herbst
On Sat, Aug 26, 2017 at 1:38 AM, Ilia Mirkin <imir...@alum.mit.edu> wrote: > On Fri, Aug 25, 2017 at 7:37 PM, Karol Herbst <karolher...@gmail.com> wrote: >> On Sat, Aug 26, 2017 at 1:30 AM, Ilia Mirkin <imir...@alum.mit.edu> wrote: >>> Why is this n

[Mesa-dev] [PATCH] st/query: init result data with 0

2017-08-25 Thread Karol Herbst
otherwise the result might contain random data. fixes on nvc0: * KHR-GL45.pipeline_statistics_query_tests_ARB.functional_default_qo_values * KHR-GL45.pipeline_statistics_query_tests_ARB.functional_non_rendering_commands_do_not_affect_queries Signed-off-by: Karol Herbst <karolher...@gmail.

Re: [Mesa-dev] [RFC PATCH 2/2] main/format: skip format conversion if src and dst format are equal

2017-08-17 Thread Karol Herbst
On Thu, Aug 17, 2017 at 10:52 AM, Erik Faye-Lund <kusmab...@gmail.com> wrote: > On Wed, Aug 16, 2017 at 8:32 PM, Karol Herbst <karolher...@gmail.com> wrote: >> Fixes 'KHR-GL45.copy_image.functional' on Nouveau >> >> Signed-off-by: Karol Herbst <karolher...

[Mesa-dev] [RFC PATCH 1/2] util/f32_to_uf11: make use of optional value range

2017-08-16 Thread Karol Herbst
f32_to_uf11(uf11_to_f32(x)) == x Fixes a few subtests for KHR-GL45.copy_image.functional on Nouveau and i965. Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/util/format_r11g11b10f.h | 10 ++ 1 file changed, 10 insertions(+) diff --git a/src/util/format_r11g11b10f.h b/sr

Re: [Mesa-dev] [PATCH] mesa/st: fix conditional jump depends on uninitialised value

2017-07-31 Thread Karol Herbst
On Mon, Jul 31, 2017 at 2:48 PM, Timothy Arceri <tarc...@itsqueeze.com> wrote: > Reported by valgrind at: > glsl_to_tgsi_visitor::visit(ir_expression*) (st_glsl_to_tgsi.cpp:1560) > > When compiling the Deus Ex shaders. > > Cc: Karol Herbst <karolher...@gmail.com> >

[Mesa-dev] [PATCH] nv50/ir: fix MUL ConstantFolding with saturation

2017-07-30 Thread Karol Herbst
such MOVs. CC: <mesa-sta...@lists.freedesktop.org> Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_emit_nvc0.cpp | 1 + src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp | 4 2 files changed, 5 insertions(+) diff --git a

Re: [Mesa-dev] [PATCH v4 00/10] Add precise/invariant semantics to TGSI

2017-07-12 Thread Karol Herbst
could finish this up soon. Greetings Karol On Fri, Jun 23, 2017 at 8:30 PM, Karol Herbst <karolher...@gmail.com> wrote: > Running Tomb Raider on Nouveau I found some flicker caused by ignoring precise > modifiers on variables inside Nouveau. > > This series add precise/invarian

[Mesa-dev] [PATCH v4 01/10] tgsi: add precise flag to tgsi_instruction

2017-06-23 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> Reviewed-by: Roland Scheidegger <srol...@vmware.com> --- src/gallium/auxiliary/tgsi/tgsi_build.c| 1 + src/gallium/include/pipe/p_shader_tokens.h | 3 ++- 2 files cha

[Mesa-dev] [PATCH v4 02/10] tgsi/dump: print _PRECISE modifier on Instructions

2017-06-23 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> --- src/gallium/auxiliary/tgsi/tgsi_dump.c | 4 1 file changed, 4 insertions(+) diff --git a/src/gallium/auxiliary/tgsi/tgsi_dump.c b/src/gallium/auxiliary/tgsi/tgsi_

[Mesa-dev] [PATCH v4 07/10] st/glsl_to_tgsi: don't optimize mul+add to mad if expression is precise

2017-06-23 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/s

[Mesa-dev] [PATCH v4 08/10] nv50/ir: add precise field to Instruction

2017-06-23 Thread Karol Herbst
v4: initialize field with NULL Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Pierre Moreau <pierre.mor...@free.fr> --- src/gallium/drivers/nouveau/codegen/nv50_ir.cpp | 1 + src/gallium/drivers/nouveau/codegen/nv50_ir.h | 1 + 2 files changed, 2 insertions(+)

[Mesa-dev] [PATCH v4 06/10] gallium/docs: add precise instruction modifier

2017-06-23 Thread Karol Herbst
v4: add comment about intermediate rounding step to MAD Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> Reviewed-by: Roland Scheidegger <srol...@vmware.com> --- src/gallium/docs/source/tgsi.rst | 11 ++-

[Mesa-dev] [PATCH v4 09/10] nv50/ir/tgsi: handle precise for most ALU instructions

2017-06-23 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Pierre Moreau <pierre.mor...@free.fr> --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp b

[Mesa-dev] [PATCH v4 04/10] tgsi: populate precise

2017-06-23 Thread Karol Herbst
Only implemented for glsl->tgsi. Other converters just set precise to 0. v2: remove precise paramter from ureg_tex_insn and ureg_memory_insn Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> --- src/gallium/auxiliary/tg

[Mesa-dev] [PATCH v4 10/10] nv50/ir: disable mul+add to mad for precise instructions

2017-06-23 Thread Karol Herbst
fixes missrendering in TombRaider KHR-GL44.gpu_shader5.precise_qualifier KHR-GL45.gpu_shader5.precise_qualifier v4: disable opt only for MAD, it's fine for SAD Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Pierre Moreau <pierre.mor...@free.fr> ---

[Mesa-dev] [PATCH v4 05/10] tgsi/text: parse _PRECISE modifier

2017-06-23 Thread Karol Herbst
v2: use str_match_no_case to fix _SAT_PRECISE detection v4: usd is_digit_alpha_underscore to match end of mods Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> --- src/gallium/auxiliary/tgsi/tgsi_text.c | 17 +

[Mesa-dev] [PATCH v4 00/10] Add precise/invariant semantics to TGSI

2017-06-23 Thread Karol Herbst
on having the same result across shaders. This series fixes this bug in Tomb Raider and one CTS test for 4.4 and 4.5 No piglit regression on my nve6 Changes since v3: * more documentation * don't disable SAD opt for nv50 * bug fixes Karol Herbst (10): tgsi: add precise flag to tgsi_instruction

[Mesa-dev] [PATCH v4 03/10] st/glsl_to_tgsi: handle precise modifier

2017-06-23 Thread Karol Herbst
all subexpression inside an ir_assignment needs to be tagged as precise. v2: make precise handling more global inside the visitor Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> --- src/mesa/state_tracker/st_glsl_to_t

Re: [Mesa-dev] [PATCH 2/2] nv50/ir: improve POW lowering

2017-06-22 Thread Karol Herbst
On Thu, Jun 22, 2017 at 9:44 PM, Roland Scheidegger <srol...@vmware.com> wrote: > Am 22.06.2017 um 21:28 schrieb Karol Herbst: >> If the exponent is a small integer immediate value, we can lower POW to >> MULs instead to save a few instructions. Also MUL instructions execute &

[Mesa-dev] [PATCH 2/2] nv50/ir: improve POW lowering

2017-06-22 Thread Karol Herbst
red programs : 39865176 -> 39857712 (-0.02%) localgpr inst bytes helped 0 4 313 313 hurt 0 12 1 1 Signed-off-by: Karol Herbst <karolher...@gmail.com> --- .../dr

[Mesa-dev] [PATCH 1/2] nv50/ir: move POW lowering into BuildUtil

2017-06-22 Thread Karol Herbst
It's the same for all supported chipsets. Signed-off-by: Karol Herbst <karolher...@gmail.com> --- .../drivers/nouveau/codegen/nv50_ir_build_util.cpp| 16 .../drivers/nouveau/codegen/nv50_ir_build_util.h | 2 ++ .../drivers/nouveau/codegen/nv50_ir_lowering_nv50.cp

Re: [Mesa-dev] [PATCH v3 05/10] tgsi/text: parse _PRECISE modifier

2017-06-20 Thread Karol Herbst
On Tue, Jun 20, 2017 at 12:22 PM, Nicolai Hähnle <nhaeh...@gmail.com> wrote: > On 16.06.2017 21:08, Karol Herbst wrote: >> >> v2: use str_match_no_case to fix _SAT_PRECISE detection >> >> Signed-off-by: Karol Herbst <karolher...@gmail.com> >> --- >

[Mesa-dev] [PATCH v3 02/10] tgsi/dump: print _PRECISE modifier on Instructions

2017-06-16 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> --- src/gallium/auxiliary/tgsi/tgsi_dump.c | 4 1 file changed, 4 insertions(+) diff --git a/src/gallium/auxiliary/tgsi/tgsi_dump.c b/src/gallium/auxiliary/tgsi/tgsi_

[Mesa-dev] [PATCH v3 07/10] st/glsl_to_tgsi: don't optimize mul+add to mad if expression is precise

2017-06-16 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp index 6cc5a39510..6ac267be94

[Mesa-dev] [PATCH v3 08/10] nv50/ir: add precise field to Instruction

2017-06-16 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir.h b/src/gallium/drivers/nouveau/codegen/nv50_ir.h index 5c09fed05c..6835c4fa8c 100644 ---

[Mesa-dev] [PATCH v3 10/10] nv50/ir: disable mul+add to mad for precise instructions

2017-06-16 Thread Karol Herbst
fixes missrendering in TombRaider KHR-GL44.gpu_shader5.precise_qualifier KHR-GL45.gpu_shader5.precise_qualifier Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp | 6 +- 1 file changed, 5 insertions(+), 1 de

[Mesa-dev] [PATCH v3 09/10] nv50/ir/tgsi: handle precise for most ALU instructions

2017-06-16 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp

[Mesa-dev] [PATCH v3 04/10] tgsi: populate precise

2017-06-16 Thread Karol Herbst
Only implemented for glsl->tgsi. Other converters just set precise to 0. v2: remove precise paramter from ureg_tex_insn and ureg_memory_insn Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/auxiliary/tgsi/tgsi_build.c | 3 +++ src/gallium/auxiliary/tgsi/tg

[Mesa-dev] [PATCH v3 06/10] gallium/docs: add precise instruction modifier

2017-06-16 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/docs/source/tgsi.rst | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/gallium/docs/source/tgsi.rst b/src/gallium/docs/source/tgsi.rst index c65d721dec..76c82b3e88 100644 --- a/src/gallium/docs/

[Mesa-dev] [PATCH v3 05/10] tgsi/text: parse _PRECISE modifier

2017-06-16 Thread Karol Herbst
v2: use str_match_no_case to fix _SAT_PRECISE detection Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/auxiliary/tgsi/tgsi_text.c | 17 ++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/src/gallium/auxiliary/tgsi/tgsi_text.c b/src/g

[Mesa-dev] [PATCH v3 03/10] st/glsl_to_tgsi: handle precise modifier

2017-06-16 Thread Karol Herbst
all subexpression inside an ir_assignment needs to be tagged as precise. v2: make precise handling more global inside the visitor Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 13 + 1 file changed, 13 insertions(+) diff

[Mesa-dev] [PATCH v3 01/10] tgsi: add precise flag to tgsi_instruction

2017-06-16 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> Reviewed-by: Roland Scheidegger <srol...@vmware.com> --- src/gallium/auxiliary/tgsi/tgsi_build.c| 1 + src/gallium/include/pipe/p_shader_tokens.h | 3 ++- 2 files cha

[Mesa-dev] [PATCH v3 00/10] Add precise/invariant semantics to TGSI

2017-06-16 Thread Karol Herbst
on having the same result across shaders. This series fixes this bug in Tomb Raider and one CTS test for 4.4 and 4.5 No piglit regression on my nve6 Changes since v2: * documentation for precise modifier * disable TGSI MAD peephole for precise instructions * drop MAD split patch in nv50ir Karol

Re: [Mesa-dev] [PATCH v2 9/9] nv50/ir/tgsi: split mad to mul+add

2017-06-13 Thread Karol Herbst
On Tue, Jun 13, 2017 at 4:12 PM, Roland Scheidegger <srol...@vmware.com> wrote: > Am 13.06.2017 um 15:11 schrieb Karol Herbst: >> On Tue, Jun 13, 2017 at 2:18 PM, Roland Scheidegger <srol...@vmware.com> >> wrote: >>> Am 13.06.2017 um 08:57 schrieb Karol Herbs

Re: [Mesa-dev] [PATCH v2 9/9] nv50/ir/tgsi: split mad to mul+add

2017-06-13 Thread Karol Herbst
On Tue, Jun 13, 2017 at 2:18 PM, Roland Scheidegger <srol...@vmware.com> wrote: > Am 13.06.2017 um 08:57 schrieb Karol Herbst: >> On Tue, Jun 13, 2017 at 2:17 AM, Roland Scheidegger <srol...@vmware.com> >> wrote: >>> I am actually also thinking this should

Re: [Mesa-dev] [PATCH v2 9/9] nv50/ir/tgsi: split mad to mul+add

2017-06-13 Thread Karol Herbst
or we lower something in the driver, because the Instruction isn't supported by the hardware all along. Karol > > Am 12.06.2017 um 20:19 schrieb Karol Herbst: >> fixes >> KHR-GL44.gpu_shader5.precise_qualifier >> KHR-GL45.gpu_shader5.precise_qualifier >> >> Sig

[Mesa-dev] [PATCH v2 3/9] st/glsl_to_tgsi: handle precise modifier

2017-06-12 Thread Karol Herbst
all subexpression inside an ir_assignment needs to be tagged as precise. v2: make precise handling more global inside the visitor Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 13 + 1 file changed, 13 insertions(+) diff

[Mesa-dev] [PATCH v2 6/9] nv50/ir: add precise field to Instruction

2017-06-12 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir.h b/src/gallium/drivers/nouveau/codegen/nv50_ir.h index 5c09fed05c..6835c4fa8c 100644 ---

[Mesa-dev] [PATCH v2 1/9] tgsi: add precise flag to tgsi_instruction

2017-06-12 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> --- src/gallium/auxiliary/tgsi/tgsi_build.c| 1 + src/gallium/include/pipe/p_shader_tokens.h | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/galli

[Mesa-dev] [PATCH v2 9/9] nv50/ir/tgsi: split mad to mul+add

2017-06-12 Thread Karol Herbst
fixes KHR-GL44.gpu_shader5.precise_qualifier KHR-GL45.gpu_shader5.precise_qualifier Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp | 14 ++ 1 file changed, 14 insertions(+) diff --git a/src/gallium/drivers/n

[Mesa-dev] [PATCH v2 8/9] nv50/ir: disable mul+add to mad for precise instructions

2017-06-12 Thread Karol Herbst
fixes missrendering in TombRaider Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp b/src/g

[Mesa-dev] [PATCH v2 7/9] nv50/ir/tgsi: handle precise for most ALU instructions

2017-06-12 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp

[Mesa-dev] [PATCH v2 5/9] tgsi/text: parse _PRECISE modifier

2017-06-12 Thread Karol Herbst
v2: use str_match_no_case to fix _SAT_PRECISE detection Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/auxiliary/tgsi/tgsi_text.c | 17 ++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/src/gallium/auxiliary/tgsi/tgsi_text.c b/src/g

[Mesa-dev] [PATCH v2 4/9] tgsi: populate precise

2017-06-12 Thread Karol Herbst
Only implemented for glsl->tgsi. Other converters just set precise to 0. v2: remove precise paramter from ureg_tex_insn and ureg_memory_insn Signed-off-by: Karol Herbst <karolher...@gmail.com> --- src/gallium/auxiliary/tgsi/tgsi_build.c | 3 +++ src/gallium/auxiliary/tgsi/tg

[Mesa-dev] [PATCH v2 2/9] tgsi/dump: print _PRECISE modifier on Instrutions

2017-06-12 Thread Karol Herbst
Signed-off-by: Karol Herbst <karolher...@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haeh...@amd.com> --- src/gallium/auxiliary/tgsi/tgsi_dump.c | 4 1 file changed, 4 insertions(+) diff --git a/src/gallium/auxiliary/tgsi/tgsi_dump.c b/src/gallium/auxiliary/tgsi/tgsi_

<    3   4   5   6   7   8   9   10   >