Re: [Mesa-dev] gitlab.fd.o financial situation and impact on services

2020-02-27 Thread Tom Stellard
On 02/27/2020 05:00 PM, Tom Stellard wrote: > On 02/27/2020 01:27 PM, Daniel Vetter wrote: >> Hi all, >> >> You might have read the short take in the X.org board meeting minutes >> already, here's the long version. >> >> The good news: gitlab.fd.o has beco

Re: [Mesa-dev] gitlab.fd.o financial situation and impact on services

2020-02-27 Thread Tom Stellard
On 02/27/2020 01:27 PM, Daniel Vetter wrote: > Hi all, > > You might have read the short take in the X.org board meeting minutes > already, here's the long version. > > The good news: gitlab.fd.o has become very popular with our > communities, and is used extensively. This especially includes

Re: [Mesa-dev] [Mesa-stable] [PATCH] radeonsi: add a workaround for bitfield_extract when count is 0

2018-10-25 Thread Tom Stellard
On 09/27/2018 10:01 PM, Timothy Arceri wrote: > On 28/9/18 2:53 am, Tom Stellard wrote: >> On 09/24/2018 11:51 PM, Samuel Pitoiset wrote: >>> >>> >>> On 9/25/18 6:46 AM, Timothy Arceri wrote: >>>> On 25/9/18 10:35 am, Marek Olšák wrote: >>>

Re: [Mesa-dev] [Mesa-stable] [PATCH] radeonsi: add a workaround for bitfield_extract when count is 0

2018-10-01 Thread Tom Stellard
On 09/27/2018 10:01 PM, Timothy Arceri wrote: > On 28/9/18 2:53 am, Tom Stellard wrote: >> On 09/24/2018 11:51 PM, Samuel Pitoiset wrote: >>> >>> >>> On 9/25/18 6:46 AM, Timothy Arceri wrote: >>>> On 25/9/18 10:35 am, Marek Olšák wrote: >>>

Re: [Mesa-dev] [Mesa-stable] [PATCH] radeonsi: add a workaround for bitfield_extract when count is 0

2018-09-27 Thread Tom Stellard
On 09/24/2018 11:51 PM, Samuel Pitoiset wrote: > > > On 9/25/18 6:46 AM, Timothy Arceri wrote: >> On 25/9/18 10:35 am, Marek Olšák wrote: >>> Do you know what's broken in LLVM? Or is it a problem with the ISA? >> >> I haven't actually dug any further. Adding Samuel to see if he remembers >>

Re: [Mesa-dev] [PATCH] radeonsi: Add debug option to enable LLVM GlobalISel (v2)

2018-07-19 Thread Tom Stellard
On 07/19/2018 08:18 PM, Marek Olšák wrote: > From: Tom Stellard > > R600_DEBUG=gisel will tell LLVM to use GlobalISel rather than > SelectionDAG for instruction selection. > > v2: mareko: move the helper to src/amd/common > Thanks for picking this up. Reviewed-by: Tom St

[Mesa-dev] [PATCH] radeonsi: Add debug option to enable LLVM GlobalISel

2018-06-26 Thread Tom Stellard
R600_DEBUG=gisel will tell LLVM to use GlobalISel rather than SelectionDAG for instruction selection. --- src/amd/common/ac_llvm_util.c | 14 -- src/amd/common/ac_llvm_util.h | 1 + src/gallium/auxiliary/gallivm/lp_bld_misc.cpp | 7 +++

Re: [Mesa-dev] [PATCH] radv: run the EarlyCSEMemSSA LLVM pass

2018-05-24 Thread Tom Stellard
On 05/24/2018 01:55 PM, Samuel Pitoiset wrote: > It's recommended by the instruction combining pass, and > RadeonSI also runs it. > > This pass used to segfault with one shader of F12017 but it > has been fixed somewhere in LLVM 7. > Do you know which patch fixes this? Or do you have an LLVM

Re: [Mesa-dev] [PATCH] gallium: move ddebug, noop, rbug, trace to auxiliary to improve build times

2018-04-13 Thread Tom Stellard
On 04/09/2018 02:27 PM, Marek Olšák wrote: > See: > https://cgit.freedesktop.org/mesa/mesa/commit/?id=f55d1f806e6b6c33af559de166d08ec8fa3ebe90 > This happens when mesa is built with rtti enabled and llvm is not. -Tom > Marek > > On Mon, Apr 9, 2018 at 5:08 PM, Dylan Baker

Re: [Mesa-dev] [PATCH 7/7] configure.ac: static link LLVM by default

2017-10-12 Thread Tom Stellard
On 10/12/2017 07:14 AM, Emil Velikov wrote: > On 5 October 2017 at 18:11, Tom Stellard <tstel...@redhat.com> wrote: >> On 10/05/2017 08:40 AM, Emil Velikov wrote: >>> On 5 October 2017 at 16:16, Tom Stellard <tstel...@redhat.com> wrote: >>>> On 10/05/2017

Re: [Mesa-dev] [PATCH 7/7] configure.ac: static link LLVM by default

2017-10-05 Thread Tom Stellard
On 10/05/2017 08:40 AM, Emil Velikov wrote: > On 5 October 2017 at 16:16, Tom Stellard <tstel...@redhat.com> wrote: >> On 10/05/2017 06:33 AM, Michel Dänzer wrote: >>> On 05/10/17 12:19 PM, Emil Velikov wrote: >>>> From: Emil Velikov <emil.veli...@colla

Re: [Mesa-dev] [PATCH 7/7] configure.ac: static link LLVM by default

2017-10-05 Thread Tom Stellard
On 10/05/2017 06:33 AM, Michel Dänzer wrote: > On 05/10/17 12:19 PM, Emil Velikov wrote: >> From: Emil Velikov >> >> A while back Michel reported that LLVM has symbol versioning to avoid >> symbol collisions. Based on observations LLVM 5.0 is the first upstream >>

[Mesa-dev] [PATCH] gallivm: Make sure module has the correct data layout when pass manager runs

2017-05-07 Thread Tom Stellard
The datalayout for modules was purposely not being set in order to work around the fact that the ExecutionEngine requires that the module's datalayout matches the datalayout of the TargetMachine that the ExecutionEngine is using. When the pass manager runs on a module with no datalayout, it uses

Re: [Mesa-dev] [PATCH] radv: setup llvm target data layout

2017-03-13 Thread Tom Stellard
end to fold immediate offsets into the > instruction. This also prevents some incorrect code generation for > ptrtoint and inttoptr instructions." > > Signed-off-by: Dave Airlie <airl...@redhat.com> Reviewed-by: Tom Stellard <tstel...@redhat.com> > --- > src/amd/common/ac_nir_to

Re: [Mesa-dev] [PATCH] radv/ac: enable loop unrolling.

2017-02-27 Thread Tom Stellard
On Fri, Feb 24, 2017 at 03:30:50PM -0800, Matt Arsenault wrote: > > > On Feb 24, 2017, at 14:39, Marek Olšák wrote: > > > > On Fri, Feb 24, 2017 at 7:20 PM, Matt Arsenault wrote: > >> > >> On Feb 24, 2017, at 01:45, Marek Olšák wrote: >

[Mesa-dev] [PATCH] radeonsi: Fix build on LLVM < 3.9 v2

2017-01-31 Thread Tom Stellard
This was broken by: e0cc0a614c96011958bc3a1b84da9168e0e1ccbb v2: - Use preprocessor macro --- src/gallium/drivers/radeonsi/si_shader_tgsi_setup.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader_tgsi_setup.c

[Mesa-dev] [PATCH] radeonsi: Fix build on LLVM < 3.9

2017-01-31 Thread Tom Stellard
This was broken by: e0cc0a614c96011958bc3a1b84da9168e0e1ccbb --- src/gallium/drivers/radeonsi/si_shader_tgsi_setup.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader_tgsi_setup.c

[Mesa-dev] [PATCH 1/2] radeonsi: Use build_buffer_load helper function for geometry shaders

2017-01-31 Thread Tom Stellard
Also modify build_buffer_load to always pass soffset to an intrinsic if it is set. This is required to avoid failing buffer range checks in some cases. --- src/gallium/drivers/radeonsi/si_shader.c | 67 ++-- 1 file changed, 20 insertions(+), 47 deletions(-) diff

[Mesa-dev] [PATCH 2/2] radeonsi: Use llvm.amdgcn.s.buffer.load instead of llvm.SI.load.const

2017-01-31 Thread Tom Stellard
Advantages of using llvm.amdgcn.s.buffer.load - We can use a real pointer type, which LLVM can better reason about and do alias analysis on. This will also ease the transition to using fat pointers and LLVM IR loads. - llvm.amdgcn.s.buffer.load is defined in IntrinsicsAMDGPU.td so passes

Re: [Mesa-dev] [PATCH 1/2] radeonsi: add Polaris12 support

2016-12-19 Thread Tom Stellard
On Mon, Dec 19, 2016 at 02:04:05PM -0500, Alex Deucher wrote: > From: Junwei Zhang > > Signed-off-by: Junwei Zhang > Reviewed-by: Nicolai Hähnle > Acked-by: Christian König > --- >

[Mesa-dev] [PATCH] radeonsi: Use build_buffer_load helper function for geometry shaders

2016-12-15 Thread Tom Stellard
Also add a need_range_checks parameter to this function, which can be set to false to enable some additional optimizations. Currently, this will cause the compiler to emit the llvm.SI.buffer.load.dword intrinsic instead of llvm.amdgcn.buffer.load. Eventually, this information will be passed to

[Mesa-dev] [PATCH] radeonsi: Set datalayout on the llvm module

2016-12-15 Thread Tom Stellard
This prevents LLVM from using sext instructions for local memory offsets and allows the backend to fold immediate offsets into the instruction. This also prevents some incorrect code generation for ptrtoint and inttoptr instructions. --- src/gallium/drivers/radeonsi/si_shader_tgsi_setup.c | 6

Re: [Mesa-dev] [PATCH 2/2] radeonsi: Use buffer_load intrinsics instead of llvm.SI.vs.load.input

2016-11-18 Thread Tom Stellard
On Sat, Nov 19, 2016 at 01:09:00AM +0100, Marek Olšák wrote: > On Wed, Nov 16, 2016 at 4:38 PM, Tom Stellard <t...@stellard.net> wrote: > > On Wed, Nov 16, 2016 at 11:13:45AM +0100, Nicolai Hähnle wrote: > >> Have you looked at the shader-db impact? > >> >

[Mesa-dev] [PATCH] mesa: Add missing call to _mesa_unlock_debug_state(ctx);

2016-11-16 Thread Tom Stellard
cd724208d3e1e3307f84a794f2c1fc83b69ccf8a added a call to _mesa_lock_debug_state(ctx) but wasn't unlocking the debug state. This fixes a hang in glsl-fs-loop piglit test with MESA_DEBUG=context. --- src/gallium/drivers/radeonsi/si_pipe.c | 8 +--- src/mesa/main/debug_output.c | 5

[Mesa-dev] [PATCH] mesa: Add missing call to _mesa_unlock_debug_state(ctx); v2

2016-11-16 Thread Tom Stellard
cd724208d3e1e3307f84a794f2c1fc83b69ccf8a added a call to _mesa_lock_debug_state(ctx) but wasn't unlocking the debug state. This fixes a hang in glsl-fs-loop piglit test with MESA_DEBUG=context. v2: - Remove unrelated changes. --- src/mesa/main/debug_output.c | 4 +++- 1 file changed, 3

Re: [Mesa-dev] [PATCH 2/2] radeonsi: Use buffer_load intrinsics instead of llvm.SI.vs.load.input

2016-11-16 Thread Tom Stellard
, but I think as long as it has non-pointer arguments this combination behaves the same as ReadNone, which would be incorrect. -Tom > Cheers, > Nicolai > > On 16.11.2016 03:14, Tom Stellard wrote: > >--- > > src/gallium/drivers/radeonsi/si_shader.c | 69 > >

[Mesa-dev] [PATCH 2/2] radeonsi: Use buffer_load intrinsics instead of llvm.SI.vs.load.input

2016-11-15 Thread Tom Stellard
--- src/gallium/drivers/radeonsi/si_shader.c | 69 +++- 1 file changed, 50 insertions(+), 19 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader.c b/src/gallium/drivers/radeonsi/si_shader.c index 306e12f..ee4fe2f 100644 ---

[Mesa-dev] [PATCH 1/2] radeonsi: Use amdgcn intrinsics for fs interpolation

2016-11-15 Thread Tom Stellard
--- src/gallium/drivers/radeonsi/si_shader.c | 197 ++- 1 file changed, 143 insertions(+), 54 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader.c b/src/gallium/drivers/radeonsi/si_shader.c index 0410a32..306e12f 100644 ---

Re: [Mesa-dev] [PATCH] clover: adapt to new error API since LLVM r286752

2016-11-14 Thread Tom Stellard
On Mon, Nov 14, 2016 at 01:44:18PM +0100, Dieter Nützel wrote: > Tested-by: Dieter Nützel > > Thanks Vedran! > Pushed, thanks! -Tom > Dieter > > Am 14.11.2016 12:17, schrieb Vedran Miletić: > > --- > > src/gallium/state_trackers/clover/llvm/codegen/bitcode.cpp | 10 >

Re: [Mesa-dev] [PATCH] clover: fix building since llvm r286566

2016-11-11 Thread Tom Stellard
On Fri, Nov 11, 2016 at 02:00:26PM +0100, Laurent Carlier wrote: Reviewed-by: Tom Stellard <thomas.stell...@amd.com> > pretty trivial fix > --- > src/gallium/state_trackers/clover/llvm/codegen/bitcode.cpp | 5 + > 1 file changed, 5 insertions(+) > > diff --git a/sr

Re: [Mesa-dev] [PATCH 1/2] gallivm: Fix build after removal of deprecated attribute API v3

2016-11-10 Thread Tom Stellard
On Wed, Nov 09, 2016 at 11:45:38PM +0100, Roland Scheidegger wrote: > Am 09.11.2016 um 16:22 schrieb Tom Stellard: > > v2: > > Fix adding parameter attributes with LLVM < 4.0. > > > > v3: > > Fix typo. > > Fix parameter index. > &

[Mesa-dev] [PATCH 1/2] gallivm: Fix build after removal of deprecated attribute API v3

2016-11-09 Thread Tom Stellard
v2: Fix adding parameter attributes with LLVM < 4.0. v3: Fix typo. Fix parameter index. Add a gallivm enum for function attributes. --- src/gallium/auxiliary/draw/draw_llvm.c| 6 +- src/gallium/auxiliary/gallivm/lp_bld_intr.c | 70 ++-

[Mesa-dev] [PATCH 2/2] llvmpipe: Fix build after removal of deprecated attribute API v2

2016-11-09 Thread Tom Stellard
From: Aaron Watry <awa...@gmail.com> Applies on top of v3 of Tom's gallivm change. v2: - Tom Stellard: Use enums instread of strings. Signed-off-by: Aaron Watry <awa...@gmail.com> CC: Tom Stellard <thomas.stell...@amd.com> CC: Jan Vesely <jan.ves...@rutgers.edu>

[Mesa-dev] [PATCH] gallivm: Fix build after removal of deprecated attribute API v2

2016-11-07 Thread Tom Stellard
v2: Fix adding parameter attributes with LLVM < 4.0. --- src/gallium/auxiliary/draw/draw_llvm.c| 6 +- src/gallium/auxiliary/gallivm/lp_bld_intr.c | 52 - src/gallium/auxiliary/gallivm/lp_bld_intr.h | 13 -

[Mesa-dev] [PATCH] gallivm: Fix build after removal of deprecated attribute API

2016-11-07 Thread Tom Stellard
--- Build tested only so far. src/gallium/auxiliary/draw/draw_llvm.c| 6 +- src/gallium/auxiliary/gallivm/lp_bld_intr.c | 48 +++- src/gallium/auxiliary/gallivm/lp_bld_intr.h | 13 - src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c | 4 +-

Re: [Mesa-dev] nir/radv: workaround broken kilp support

2016-11-02 Thread Tom Stellard
On Wed, Nov 02, 2016 at 11:26:08AM +1000, Dave Airlie wrote: > So it appears at least the LLVM 3.9 backend can get confused > when it gets hit with if (cond) discard type constructs, and we > have a GLSL optimisation to convert this to discard_if, so I've > ported that to NIR, and enabled it for

[Mesa-dev] [PATCH 2/2] radv: Use new image load/store intrinsic signatures v2

2016-10-13 Thread Tom Stellard
These were changed in LLVM r284024. v2: - Only use float types for vdata of llvm.amdgcn.image.store. LLVM doesn't support integer types for this intrinsic. --- src/amd/common/ac_nir_to_llvm.c | 133 1 file changed, 108 insertions(+), 25

Re: [Mesa-dev] [PATCH 2/2] radv: Use new image load/store intrinsic signatures

2016-10-13 Thread Tom Stellard
applies for me. I hope I didn't butcher anything inadvertently. > Hi, I just sent rebased patches. Can you try those. -Tom > Cheers, > Kai > > > Tom Stellard wrote on 13.10.2016 17:21: > > These were changed in LLVM r284024. &

[Mesa-dev] [PATCH 1/2] radv: Fix incorrect comment

2016-10-13 Thread Tom Stellard
--- src/amd/common/ac_nir_to_llvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c index e6ff7c8..9c764c7 100644 --- a/src/amd/common/ac_nir_to_llvm.c +++ b/src/amd/common/ac_nir_to_llvm.c @@ -2373,8

[Mesa-dev] [PATCH 2/2] radv: Use new image load/store intrinsic signatures

2016-10-13 Thread Tom Stellard
These were changed in LLVM r284024. --- src/amd/common/ac_nir_to_llvm.c | 131 1 file changed, 107 insertions(+), 24 deletions(-) diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c index 9c764c7..4fba7d3 100644 ---

[Mesa-dev] [PATCH 1/2] radv: Fix incorrect comment

2016-10-13 Thread Tom Stellard
--- src/amd/common/ac_nir_to_llvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c index e6ff7c8..9c764c7 100644 --- a/src/amd/common/ac_nir_to_llvm.c +++ b/src/amd/common/ac_nir_to_llvm.c @@ -2373,8

Re: [Mesa-dev] [PATCH 2/2] [RFC] radv: add scratch support for spilling.

2016-10-11 Thread Tom Stellard
On Tue, Oct 11, 2016 at 03:21:24PM +0200, Nicolai Hähnle wrote: > On 11.10.2016 07:36, Dave Airlie wrote: > > On 11 October 2016 at 12:13, Dave Airlie wrote: > >> On 11 October 2016 at 11:42, Dave Airlie wrote: > >>> On 11 October 2016 at 05:50, Dave Airlie

[Mesa-dev] [PATCH 1/3] radeonsi: Refactor image store/load intrinsic name creation

2016-10-11 Thread Tom Stellard
--- src/gallium/drivers/radeonsi/si_shader.c | 29 ++--- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader.c b/src/gallium/drivers/radeonsi/si_shader.c index 49d4121..8254cb2 100644 ---

[Mesa-dev] [PATCH 3/3] radeonsi: Use the new image load/store intrinsic signatures

2016-10-11 Thread Tom Stellard
--- src/gallium/drivers/radeonsi/si_shader.c | 59 +--- 1 file changed, 46 insertions(+), 13 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader.c b/src/gallium/drivers/radeonsi/si_shader.c index 4e07317..1f1fdf2 100644 ---

[Mesa-dev] [PATCH 2/3] radeonsi: Add function for converting LLVM type to intrinsic string

2016-10-11 Thread Tom Stellard
The existing function only worked for integer types. --- src/gallium/drivers/radeonsi/si_shader.c | 42 1 file changed, 32 insertions(+), 10 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader.c b/src/gallium/drivers/radeonsi/si_shader.c index

[Mesa-dev] [PATCH 2/2] radeonsi/compute: Use the HSA abi for non-TGSI compute shaders v2

2016-09-13 Thread Tom Stellard
This patch switches non-TGSI compute shaders over to using the HSA ABI described here: https://github.com/RadeonOpenCompute/ROCm-Docs/blob/master/AMDGPU-ABI.md The HSA ABI provides a much cleaner interface for compute shaders and allows us to share more code in the compiler with the HSA stack.

[Mesa-dev] [PATCH 1/2] radeonsi/compute: Add some more debug printfs

2016-09-13 Thread Tom Stellard
--- src/gallium/drivers/radeonsi/si_compute.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gallium/drivers/radeonsi/si_compute.c b/src/gallium/drivers/radeonsi/si_compute.c index 5041761..a79c224 100644 --- a/src/gallium/drivers/radeonsi/si_compute.c +++

[Mesa-dev] [PATCH] radeonsi: Don't use global variables for tess lds

2016-08-26 Thread Tom Stellard
We were allocating global variables for the maximum LDS size which made the compiler think we were using all of LDS, which isn't the case. --- src/gallium/drivers/radeonsi/si_shader.c | 15 ++- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git

Re: [Mesa-dev] [PATCH] radeonsi: initialize and finalize the LLVM function pass manager

2016-08-18 Thread Tom Stellard
On Fri, Aug 12, 2016 at 01:26:08AM +0200, Marek Olšák wrote: > From: Marek Olšák <marek.ol...@amd.com> > > we should do that allegedly Reviewed-by: Tom Stellard <thomas.stell...@amd.com> > --- > src/gallium/drivers/radeon/radeon_setup_tgsi_llvm.c | 2 ++ >

Re: [Mesa-dev] [PATCH 11/19] gallium/radeon: more descriptive names for LLVM temporaries in debug builds

2016-08-10 Thread Tom Stellard
On Tue, Aug 09, 2016 at 12:36:40PM +0200, Nicolai Hähnle wrote: > From: Nicolai Hähnle <nicolai.haeh...@amd.com> > This is a great idea. Reviewed-by: Tom Stellard <thomas.stell...@amd.com> > --- > src/gallium/drivers/radeon/radeon_setup_tgsi_llvm.c | 14

Re: [Mesa-dev] [PATCH 09/19] gallium/radeon: simplify radeon_llvm_emit_fetch for direct array addressing

2016-08-10 Thread Tom Stellard
On Tue, Aug 09, 2016 at 12:36:38PM +0200, Nicolai Hähnle wrote: > From: Nicolai Hähnle <nicolai.haeh...@amd.com> > > We can use the pointer stored in the temps array directly. Reviewed-by: Tom Stellard <thomas.stell...@amd.com> > --- > src/gallium/drivers/radeon/r

Re: [Mesa-dev] [PATCH 10/19] gallium/radeon: simplify radeon_llvm_emit_store for direct array addressing

2016-08-10 Thread Tom Stellard
On Tue, Aug 09, 2016 at 12:36:39PM +0200, Nicolai Hähnle wrote: > From: Nicolai Hähnle <nicolai.haeh...@amd.com> > > We can use the pointer stored in the temps array directly. Reviewed-by: Tom Stellard <thomas.stell...@amd.com> > --- > src/gallium/drivers/radeon/r

Re: [Mesa-dev] [PATCH 08/19] gallium/radeon: clean up emit_declaration for temporaries

2016-08-10 Thread Tom Stellard
On Tue, Aug 09, 2016 at 12:36:37PM +0200, Nicolai Hähnle wrote: > From: Nicolai Hähnle <nicolai.haeh...@amd.com> > > In the alloca'd array case, no longer create redundant and unused allocas > for the individual elements; create getelementptrs instead. Reviewed-by: Tom Stel

[Mesa-dev] [PATCH 1/2] radeonsi/compute: Add some more debug printfs

2016-07-25 Thread Tom Stellard
--- src/gallium/drivers/radeonsi/si_compute.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gallium/drivers/radeonsi/si_compute.c b/src/gallium/drivers/radeonsi/si_compute.c index 5a40286..949ab1a 100644 --- a/src/gallium/drivers/radeonsi/si_compute.c +++

[Mesa-dev] [PATCH 2/2] radeonsi/compute: Use the HSA abi for non-TGSI compute shaders

2016-07-25 Thread Tom Stellard
This patche switches non-TGSI compute shaders over to using the HSA ABI described here: https://github.com/RadeonOpenCompute/ROCm-Docs/blob/master/AMDGPU-ABI.md The HSA ABI provides a much cleaner interface for compute shaders and allows us to share more code in the compiler with the HSA stack.

[Mesa-dev] [PATCH 2/2] clover: Re-order includes in invocation.cpp to fix build

2016-07-20 Thread Tom Stellard
The build was failing because the official CL headers have a few defines, like: \# define cl_khr_gl_sharing 1 Which have the same name as some class members of clang's OpenCLOptions class. If we include the cl headers first, this breaks the build because the member names of this class are

[Mesa-dev] [PATCH 1/2] clover: Add missing include v2

2016-07-20 Thread Tom Stellard
There was a patch committed to clang to remove unnecessary includes from header files, so we now need to explicitly include clang/Lex/PreprocessorOptions.h v2: - Use <> instead of "" for the include path. --- src/gallium/state_trackers/clover/llvm/invocation.cpp | 2 ++ 1 file changed, 2

[Mesa-dev] [PATCH 2/2] clover: Re-order includes in invocation.cpp to fix build

2016-07-19 Thread Tom Stellard
The build was failing because the official CL headers have a few defines, like: Which have the same name as some class members of clang's OpenCLOptions class. If we include the cl headers first, this breaks the build because the member names of this class are replaced by the literal 1. ---

[Mesa-dev] [PATCH 1/2] clover: Add missing include

2016-07-19 Thread Tom Stellard
There was a patch committed to clang to remove unnecessary includes from header files, so we now need to explicitly include clang/Lex/PreprocessorOptions.h --- src/gallium/state_trackers/clover/llvm/invocation.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git

Re: [Mesa-dev] [PATCH 2/5] radeonsi: set dereferenceable attribute on descriptor arrays

2016-07-13 Thread Tom Stellard
On Wed, Jul 13, 2016 at 03:20:55PM -0400, Tom Stellard wrote: > On Tue, Jul 12, 2016 at 10:52:35PM +0200, Marek Olšák wrote: > > From: Marek Olšák <marek.ol...@amd.com> > > > > This allows moving the loads arbitrarily in the Sinking pass. > > > >

Re: [Mesa-dev] [PATCH 3/5] radeonsi: replace !tbaa with !invariant.load

2016-07-13 Thread Tom Stellard
On Tue, Jul 12, 2016 at 10:52:36PM +0200, Marek Olšák wrote: > From: Marek Olšák <marek.ol...@amd.com> > Reviewed-by: Tom Stellard <thomas.stell...@amd.com> > no change in generated code thanks to dereferenceable(n) > --- > src/gallium/drivers/radeonsi/si_shader.c

Re: [Mesa-dev] [PATCH 2/5] radeonsi: set dereferenceable attribute on descriptor arrays

2016-07-13 Thread Tom Stellard
On Tue, Jul 12, 2016 at 10:52:35PM +0200, Marek Olšák wrote: > From: Marek Olšák > > This allows moving the loads arbitrarily in the Sinking pass. > > 26002 shaders in 14643 tests > Totals: > SGPRS: 2080160 -> 2080160 (0.00 %) > VGPRS: 798875 -> 797826 (-0.13 %) > Spilled

Re: [Mesa-dev] [PATCH RFC 1/1] r600, compute: Use vtx #3 for kernel arguments

2016-07-11 Thread Tom Stellard
aybe add a comment explaining why we are using vtx#3. With that change: Reviewed-by: Tom Stellard <thomas.stell...@amd.com> > --- > Hi, > > I ran into problem when using VTX_READ from constant buffer would work only > for 0 index. The LLVM code implied that it should work (or ma

Re: [Mesa-dev] [PATCH] radeonsi: don't interleave R600_DEBUG-enabled shader dumps

2016-07-06 Thread Tom Stellard
On Wed, Jul 06, 2016 at 11:55:03PM +0200, Nicolai Hähnle wrote: > From: Nicolai Hähnle > > Only setting R600_DEBUG doesn't set any debug callback. Conversely, the debug > callback is only called when R600_DEBUG is set. I don't get any output from shader-db with this

Re: [Mesa-dev] [PATCH] gallivm: set LLVMNoUnwindAttribute on all intrinsics

2016-07-05 Thread Tom Stellard
On Tue, Jul 05, 2016 at 11:36:03AM +0200, Marek Olšák wrote: > From: Marek Olšák > > RadeonSI stats: Mostly 0% difference, but Valley shows a small improvement: > Do you know which intrinsic this made a difference for? I'm guessing this is required for all the intrinsics

Re: [Mesa-dev] clover: Implement linking of multiple CL programs.

2016-07-04 Thread Tom Stellard
On Sun, Jul 03, 2016 at 05:51:09PM -0700, Francisco Jerez wrote: > This series is the result of a long back and forth of patches between > Serge and me. Most of the changes are already reviewed by either of > us, but I'm sending them again over the mailing list just in case > somebody else wants

Re: [Mesa-dev] [PATCH] radeonsi: add a debug flag for unsafe math LLVM optimizations

2016-06-21 Thread Tom Stellard
On Tue, Jun 21, 2016 at 10:42:45PM +0200, Marek Olšák wrote: > On Tue, Jun 21, 2016 at 9:27 PM, Tom Stellard <t...@stellard.net> wrote: > > On Tue, Jun 21, 2016 at 08:17:15PM +0200, Marek Olšák wrote: > >> On Tue, Jun 21, 2016 at 7:21 PM, Tom Stellard <t...@stellard.net

Re: [Mesa-dev] [PATCH] radeonsi: add a debug flag for unsafe math LLVM optimizations

2016-06-21 Thread Tom Stellard
On Tue, Jun 21, 2016 at 08:17:15PM +0200, Marek Olšák wrote: > On Tue, Jun 21, 2016 at 7:21 PM, Tom Stellard <t...@stellard.net> wrote: > > On Mon, Jun 13, 2016 at 06:27:02PM +0200, Marek Olšák wrote: > >> From: Marek Olšák <marek.ol...@amd.com> > >> &g

Re: [Mesa-dev] [PATCH] radeonsi: add a debug flag for unsafe math LLVM optimizations

2016-06-21 Thread Tom Stellard
On Mon, Jun 13, 2016 at 06:27:02PM +0200, Marek Olšák wrote: > From: Marek Olšák > > --- > src/gallium/drivers/radeon/r600_pipe_common.c | 1 + > src/gallium/drivers/radeon/r600_pipe_common.h | 1 + > src/gallium/drivers/radeonsi/si_shader.c | 16 >

[Mesa-dev] [PATCH 1/3] radeon/llvm: Remove uses_temp_indirect_addressing() function

2016-05-25 Thread Tom Stellard
bld->indirect_files is never set, so this function always returns false. --- .../drivers/radeon/radeon_setup_tgsi_llvm.c| 24 +- 1 file changed, 1 insertion(+), 23 deletions(-) diff --git a/src/gallium/drivers/radeon/radeon_setup_tgsi_llvm.c

[Mesa-dev] [PATCH 3/3] radeon/llvm: Use alloca instructions for larger arrays

2016-05-25 Thread Tom Stellard
We were storing arrays in vectors, which was leading to some really bad spill code for large arrays. allocas instructions are a better fit for arrays and LLVM optimizations are more geared toward dealing with allocas instead of vectors. For arrays that have 16 or less 32-bit elements, we will

[Mesa-dev] [PATCH 2/3] radeon/llvm: Add helpers for loading and storing data from arrays.

2016-05-25 Thread Tom Stellard
--- .../drivers/radeon/radeon_setup_tgsi_llvm.c| 51 +- 1 file changed, 41 insertions(+), 10 deletions(-) diff --git a/src/gallium/drivers/radeon/radeon_setup_tgsi_llvm.c b/src/gallium/drivers/radeon/radeon_setup_tgsi_llvm.c index 759c674..93bc307 100644 ---

Re: [Mesa-dev] [PATCH 02/14] Revert "mesa: Build EGL without X11 headers after interop patchset"

2016-05-24 Thread Tom Stellard
On Tue, May 24, 2016 at 03:32:44PM +0100, Emil Velikov wrote: > From: Emil Velikov <emil.veli...@collabora.com> > > This reverts commit 4e2c9a04354b6b133845b8b93c0c5d34261a91d0. > > The solution was incomplete and fragile. An alternative one is coming > shortly.

Re: [Mesa-dev] [PATCH] mesa: Build EGL without X11 headers after interop patchset

2016-05-20 Thread Tom Stellard
On Fri, May 20, 2016 at 04:29:07PM -0700, Mark Janes wrote: > Tom Stellard <t...@stellard.net> writes: > > > On Wed, Apr 27, 2016 at 10:33:14PM +, Youry Metlitsky wrote: > >> --- > >> include/GL/mesa_glinterop.h | 15 ++- > >>

Re: [Mesa-dev] [PATCH] mesa: Build EGL without X11 headers after interop patchset

2016-05-20 Thread Tom Stellard
On Wed, Apr 27, 2016 at 10:33:14PM +, Youry Metlitsky wrote: > --- > include/GL/mesa_glinterop.h | 15 ++- > 1 file changed, 14 insertions(+), 1 deletion(-) > Hi, This patch breaks the build for me: glxcmds.c:2699:1: error: no previous prototype for

Re: [Mesa-dev] [PATCH] r600, compute: create vtx buffer for text + rodata

2016-05-03 Thread Tom Stellard
nt offsets from the start of the buffer and they could be folded into other instructions. However, this would be a little more involved because you would have to change llvm to emit the read-only data fro R600 into a separate section. I think your appro

Re: [Mesa-dev] [PATCH] radeonsi: Add config parameter to si_shader_apply_scratch_relocs.

2016-04-21 Thread Tom Stellard
On Thu, Apr 21, 2016 at 06:28:15PM +0200, Bas Nieuwenhuizen wrote: > shader->config is not updated for compute kernels. > > Signed-off-by: Bas Nieuwenhuizen <b...@basnieuwenhuizen.nl> This fixes compute shaders that use scratch. Thanks. Reviewed-by: Tom Stellard <th

Re: [Mesa-dev] [PATCH 2/4] radeonsi: Set range metadata on calls to llvm.SI.tid

2016-04-19 Thread Tom Stellard
On Tue, Apr 19, 2016 at 08:12:08PM +0200, Michael Schellenberger Costa wrote: > Hi Tom, > > Am 19.04.2016 um 19:52 schrieb Tom Stellard: > > The range metadata tells LLVM the range of expected values for this > > intrinsic, > > so it can do some additional

Re: [Mesa-dev] [PATCH] configure.ac: fix the --disable-llvm-shared-libs build

2016-04-19 Thread Tom Stellard
On Tue, Apr 19, 2016 at 07:39:13PM +0100, Emil Velikov wrote: > Hi Chuck, > > Thanks for chipping in. > > On 19 April 2016 at 15:47, Chuck Atkins wrote: > > This still doesn't quite give what you want. One can also have an llvm with > > component shared libs. So

[Mesa-dev] [PATCH 2/4] radeonsi: Set range metadata on calls to llvm.SI.tid

2016-04-19 Thread Tom Stellard
The range metadata tells LLVM the range of expected values for this intrinsic, so it can do some additional optimizations on the result. --- src/gallium/drivers/radeonsi/si_shader.c | 29 ++--- 1 file changed, 26 insertions(+), 3 deletions(-) diff --git

[Mesa-dev] [PATCH 4/4] radeonsi: Implement ddx/ddy on VI using ds_bpermute

2016-04-19 Thread Tom Stellard
The ds_bpermute instruction allows threads to transfer data directly to or from the vgprs of other threads. These instructions use the lds hardware to transfer data, but do not read or write lds memory. DDX BEFORE:| DDX AFTER: |

[Mesa-dev] [PATCH 3/4] radeonsi: Use llvm.amdgcn.mbcnt.* intrinsics instead of llvm.SI.tid v2

2016-04-19 Thread Tom Stellard
We're trying to move to more of the new style intrinsics with include the correct target name, and map directly to ISA instructions. v2: - Only do this with LLVM 3.8 and newer. --- src/gallium/drivers/radeonsi/si_shader.c | 17 - 1 file changed, 16 insertions(+), 1 deletion(-)

[Mesa-dev] [PATCH 1/4] radeonsi: Create a helper function for computing the thread id

2016-04-19 Thread Tom Stellard
--- src/gallium/drivers/radeonsi/si_shader.c | 17 +++-- 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_shader.c b/src/gallium/drivers/radeonsi/si_shader.c index c26960b..3b6d6e9 100644 --- a/src/gallium/drivers/radeonsi/si_shader.c +++

Re: [Mesa-dev] [PATCH 8/9] llvmpipe: Test more vector lengths.

2016-04-18 Thread Tom Stellard
On Mon, Apr 18, 2016 at 10:14:35AM +0100, Jose Fonseca wrote: > All power of two of up native vector length. > > There is actually a bug in lp_build_round for v2, whereby it doesn't > round to nearest. Fixing is left to the future, but the test is now > able to expect it to fail. > --- >

[Mesa-dev] [PATCH 2/2] radeonsi: Implement ddx/ddy on VI using ds_bpermute

2016-04-15 Thread Tom Stellard
The ds_bpermute instruction allows threads to transfer data directly to or from the vgprs of other threads. These instructions use the lds hardware to transfer data, but do not read or write lds memory. DDX BEFORE:| DDX AFTER: |

[Mesa-dev] [PATCH 1/2] radeonsi: Use llvm.amdgcn.mbcnt.* intrinsics instead of llvm.SI.tid

2016-04-15 Thread Tom Stellard
We're trying to move to more of the new style intrinsics with include the correct target name, and map directly to ISA instructions. --- src/gallium/drivers/radeonsi/si_shader.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git

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

2016-04-13 Thread Tom Stellard
On Wed, Apr 13, 2016 at 03:59:36PM +0900, Michel Dänzer wrote: > From: Michel Dänzer <michel.daen...@amd.com> > > createInternalizePass now takes a callback instead of a StringSet. > > Signed-off-by: Michel Dänzer <michel.daen...@amd.com> Reviewed-by: Tom Stella

Re: [Mesa-dev] r600/compute: cleanup evergreen_compute.c

2016-04-06 Thread Tom Stellard
On Wed, Apr 06, 2016 at 10:40:50PM +0100, Dave Airlie wrote: > This probably should have been cleaned up before merging, but we > were a bit lax with it. This is a bunch of cleanups and changes, > that make adding ARB_compute_support less of a task. > Acked-by: Tom Stellard &

Re: [Mesa-dev] [PATCH] clover: Fix build against clang SVN >= r265359

2016-04-05 Thread Tom Stellard
On Tue, Apr 05, 2016 at 03:43:35PM +0900, Michel Dänzer wrote: > From: Michel Dänzer > > Signed-off-by: Michel Dänzer I pushed this, thanks. -Tom > --- > src/gallium/state_trackers/clover/llvm/invocation.cpp | 3 +++ > 1 file changed, 3

Re: [Mesa-dev] [PATCH 01/20] radeonsi: set shader calling conventions

2016-04-04 Thread Tom Stellard
type; > + enum radeon_llvm_calling_convention calling_conv; > This looks like you will get 'unused variable warnings' with this change. Probably this easiest thing to do is put (void)variable_name somewhere, but I'm not sure this is really a big deal. Either way: Review

Re: [Mesa-dev] [PATCH] gallium/swr: update rasterizer (532172)

2016-03-23 Thread Tom Stellard
On Wed, Mar 23, 2016 at 04:53:29PM +, Rowley, Timothy O wrote: > > > On Mar 23, 2016, at 12:52 AM, Kenneth Graunke wrote: > > > > That's an awkward situation we've not run into before. > > > > If the code is going to live in the upstream Mesa git repository, then > >

Re: [Mesa-dev] [PATCH 1/2] AMDGPU/SI: Add Polaris support

2016-03-23 Thread Tom Stellard
On Wed, Mar 23, 2016 at 02:41:24PM -0400, Alex Deucher via llvm-commits wrote: > From: Sonny Jiang > These two patches need to be squashed, but I can do it before I commit. LGTM. -Tom > Signed-off-by: Sonny Jiang > Reviewed-by: Alex Deucher

Re: [Mesa-dev] Introducing OpenSWR: High performance software rasterizer

2016-02-17 Thread Tom Stellard
On Thu, Feb 18, 2016 at 02:07:25AM +0100, Roland Scheidegger wrote: > Am 17.02.2016 um 22:09 schrieb Rowley, Timothy O: > >> On Nov 18, 2015, at 12:34 PM, Emil Velikov > >> wrote: I have no objections against > >> getting this merged, although here are a couple of things

Re: [Mesa-dev] issues with split llvm libraries and llvmpipe and failing to load library

2016-02-11 Thread Tom Stellard
On Thu, Feb 11, 2016 at 01:59:25PM +1000, Dave Airlie wrote: > Hey, > > So in Fedora rawhide we are now building llvm 3.7.1 into the lots of > little shared libraries format. > This configuration is only recommended for developers. See the documentation for BUILD_SHARED_LIBS:BOOL here:

Re: [Mesa-dev] [PATCH] radeonsi: enable denorms for 64-bit and 16-bit floats

2016-02-09 Thread Tom Stellard
On Mon, Feb 08, 2016 at 09:38:32PM +0100, Marek Olšák wrote: > On Mon, Feb 8, 2016 at 5:08 PM, Tom Stellard <t...@stellard.net> wrote: > > On Sat, Feb 06, 2016 at 01:15:42PM +0100, Marek Olšák wrote: > >> From: Marek Olšák <marek.ol...@amd.com> > >> >

Re: [Mesa-dev] [PATCH] radeonsi: enable denorms for 64-bit and 16-bit floats

2016-02-08 Thread Tom Stellard
On Sat, Feb 06, 2016 at 01:15:42PM +0100, Marek Olšák wrote: > From: Marek Olšák > > This fixes FP16 conversion instructions for VI, which has 16-bit floats, > but not SI & CI, which can't disable denorms for those instructions. Do you know why this fixes FP16 conversions?

Re: [Mesa-dev] [PATCH 2/3] radeon/llvm: Set the target triple on the module

2016-02-05 Thread Tom Stellard
On Thu, Feb 04, 2016 at 02:42:15PM -0800, Matt Arsenault wrote: > > > On Feb 4, 2016, at 13:02, Tom Stellard <thomas.stell...@amd.com> wrote: > > > > + LLVMSetTarget(ctx->gallivm.module, > > + > > +#if HAVE_LLVM < 0x0306

Re: [Mesa-dev] [PATCH 2/2] radeonsi: Allow dumping LLVM IR before optimization passes

2016-02-05 Thread Tom Stellard
On Fri, Feb 05, 2016 at 08:55:17AM -0500, Nicolai Hähnle wrote: > On 04.02.2016 13:52, Tom Stellard wrote: > > On Thu, Feb 04, 2016 at 09:15:26AM +0100, Nicolai Hähnle wrote: > >> From: Nicolai Hähnle <nicolai.haeh...@amd.com> > >> > >> Set R600

[Mesa-dev] [PATCH 2/3] radeon/llvm: Set the target triple on the module

2016-02-04 Thread Tom Stellard
--- src/gallium/drivers/r600/r600_llvm.c| 2 +- src/gallium/drivers/radeon/radeon_llvm.h| 3 ++- src/gallium/drivers/radeon/radeon_setup_tgsi_llvm.c | 9 - src/gallium/drivers/radeonsi/si_shader.c| 4 ++-- 4 files changed, 13 insertions(+), 5

[Mesa-dev] [PATCH 3/3] radeon/llvm: Add TargetLibraryInfo to the pass manager

2016-02-04 Thread Tom Stellard
This will prevent optimization passes from introducing unsupported library calls. --- src/gallium/drivers/radeon/radeon_setup_tgsi_llvm.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/radeon/radeon_setup_tgsi_llvm.c

  1   2   3   4   5   6   7   8   9   10   >