Rob Clark [Tue, 10 Mar 2020 23:07:40 +0000 (16:07 -0700)]
freedreno/ir3/print: print (r) flag
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
Rob Clark [Tue, 10 Mar 2020 23:01:30 +0000 (16:01 -0700)]
freedreno/ir3/legalize: don't allow (nopN) if (rptN)
These two encodings are mutually exclusive. If the instruction is a
vector(ish) `(rptN)` instruction, then we can't fold a `(nopN)` post-
delay into it.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
Rob Clark [Wed, 13 May 2020 16:54:57 +0000 (09:54 -0700)]
freedreno/a6xx: emit shader names in debug builds
To simplify mapping a shader in a cmdstream trace back to glsl.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
Rob Clark [Wed, 13 May 2020 16:53:43 +0000 (09:53 -0700)]
freedreno: splitup emit_string_marker
So that we can use it internally to emit string markers into a specified
rb.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
Rob Clark [Sun, 7 Jun 2020 18:14:18 +0000 (11:14 -0700)]
freedreno/ir3/cp: properly handle already-folded RELATIV
In the `try_swap_mad_two_srcs()` case, valid_flags() gets called both
for the src that we want to try to fold, and for the other src that we
are trying to swap to make that possible. It can happen in the 2nd case
that a RELATIV src has already been folded. Since `ssa()` returns non-
null in both the `IR3_REG_SSA` and `IR3_REG_ARRAY` cases (in the later
case, it is the dependent array access that the current instruction
cannot be moved ahead of), we need to explicitly check that the src
reg we are looking at is still an SSA src.
Reported-by: Jonathan Marek <jonathan@marek.ca>
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
Rob Clark [Sun, 7 Jun 2020 18:11:23 +0000 (11:11 -0700)]
freedreno/ir3/validate: also check instr->address
Verify that instructions which have a relative src and/or dest, have
`instr->address`.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
Rob Clark [Mon, 25 May 2020 19:08:03 +0000 (12:08 -0700)]
freedreno/sched: reset delay counters at start of block
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
Rob Clark [Mon, 11 May 2020 16:15:50 +0000 (09:15 -0700)]
freedreno/log-parser: fix compute times
We also need to clear the table of compute times at the end of the
frame, otherwise results shown will include all the compute jobs since
the beginning of the trace.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
Eric Anholt [Mon, 15 Jun 2020 19:02:10 +0000 (12:02 -0700)]
docs: Replace ancient swrast conformance docs with more current information.
I don't think Mesa 4.0 swrast conformance is relevant at this point, just
point people to the current Khronos list. Also, add some more information
on submitting results.
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5482>
Erik Faye-Lund [Mon, 15 Jun 2020 10:31:34 +0000 (12:31 +0200)]
docs/relnotes: update internal references
This time, let's use proper Sphinx roles for the referenes, so we can
reference documents and inline refs.
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5471>
Erik Faye-Lund [Mon, 15 Jun 2020 10:31:36 +0000 (12:31 +0200)]
docs: update internal references
This time, let's use proper Sphinx roles for the referenes, so we can
reference documents and inline refs.
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5471>
Lionel Landwerlin [Mon, 8 Jun 2020 17:33:14 +0000 (20:33 +0300)]
anv: add an option to disable secondary command buffer calls
Those are currently hurting Felix' ability to look at the batches.
We can probably detect this in the aubinator but that's a bit more
work than falling back to the previous behavior.
v2: Condition VK_KHR_performance_query to not using this variable (Jason)
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5391>
Jason Ekstrand [Sat, 13 Jun 2020 15:51:01 +0000 (10:51 -0500)]
nir/intrinsics: Put the _intel intrinsics together at the end
All the other driver-specific intrinsics are at the end of the file so
Intel's should go there too.
Reviewed-by: Sagar Ghuge<sagar.ghuge@intel.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5503>
Dave Airlie [Mon, 15 Jun 2020 22:33:34 +0000 (08:33 +1000)]
softpipe: change vendor name to something more generic.
For consistency with the llvmpipe driver.
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Reviewed by: Jose Fonseca <jfonseca@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5483>
Dave Airlie [Mon, 15 Jun 2020 22:32:57 +0000 (08:32 +1000)]
llvmpipe: change vendor to be more generic.
If submitting for conformance it is probably better to have a generic
name for vendor here.
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Reviewed by: Jose Fonseca <jfonseca@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5483>
Dave Airlie [Mon, 15 Jun 2020 21:22:40 +0000 (07:22 +1000)]
virgl: change vendor id to reflect reality more.
virgl vendor id should probably be little more generic now.
I think I picked this becuase the virtio pci id space was under
RH's name and they did pay for it, but at this point I think it's
better to just use something generic.
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5483>
Jason Ekstrand [Sat, 13 Jun 2020 18:57:32 +0000 (13:57 -0500)]
anv: Add anv_pipeline_init/finish helpers
This cleans up pipline create/destroy a bit after the compute/gfx split.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5457>
Jason Ekstrand [Tue, 16 Jun 2020 15:50:19 +0000 (10:50 -0500)]
anv: Add an anv_batch_set_storage helper
Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5457>
Jan Beich [Sat, 30 May 2020 22:37:45 +0000 (22:37 +0000)]
anv,iris: unbreak on BSDs after
812cf5f522ab,
abf8aed68047
../src/intel/vulkan/anv_gem.c:31:10: fatal error: 'linux/sync_file.h' file not found
#include <linux/sync_file.h>
^~~~~~~~~~~~~~~~~~~
../src/gallium/drivers/iris/iris_fence.c:29:10: fatal error: 'linux/sync_file.h' file not found
#include <linux/sync_file.h>
^~~~~~~~~~~~~~~~~~~
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5463>
Jan Beich [Mon, 15 Jun 2020 17:55:51 +0000 (17:55 +0000)]
drm-uapi: Add sync_file.h
Based on <linux/sync_file.h> with BSD portability conditional.
At least FreeBSD supports SYNC_IOC_* via LinuxKPI in DRM.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5463>
Daniel Schürmann [Tue, 16 Jun 2020 09:03:52 +0000 (10:03 +0100)]
aco: don't allow SGPRs on logical phis
aco_validate() is called after phi lowering, now.
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5496>
Daniel Schürmann [Tue, 16 Jun 2020 09:03:00 +0000 (10:03 +0100)]
aco: reorder calls to aco_validate() and cleanup aco_compile_shader()
The first call of aco_validate should happen after phi lowering.
Otherwise, subdword restrictions might be violated
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5496>
Icecream95 [Thu, 14 May 2020 03:58:04 +0000 (15:58 +1200)]
panfrost: Implement ARB_depth_clamp
This significantly improves the quality of shadows in OpenMW.
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5453>
Icecream95 [Thu, 14 May 2020 03:54:09 +0000 (15:54 +1200)]
panfrost: Clean up panfrost_frag_meta_rasterizer_update
Create a pointer to ctx->rasterizer->base so it isn't repeatedly
referred to.
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5453>
Rohan Garg [Mon, 15 Jun 2020 10:25:56 +0000 (12:25 +0200)]
iris: Fix documentation for _iris_batch_flush
_iris_batch_flush has no in_fence and out_fence parameters
Signed-off-by: Rohan Garg <rohan.garg@collabora.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5470>
Erik Faye-Lund [Mon, 3 Feb 2020 16:41:46 +0000 (17:41 +0100)]
zink: expose GLSL 1.30
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5479>
Erik Faye-Lund [Thu, 30 Jan 2020 21:23:39 +0000 (22:23 +0100)]
zink: enable cull-distance if supported
This is already implemented, and we just need to flip the switch to turn
it on.
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5479>
Erik Faye-Lund [Thu, 11 Jun 2020 11:03:22 +0000 (13:03 +0200)]
gallium/hud: don't use user vertex buffers
This gains back some performance lost in the previous commit, by
bypassing u_vbuf.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5417>
Erik Faye-Lund [Wed, 10 Jun 2020 17:56:49 +0000 (19:56 +0200)]
Revert "gallium/hud: don't use user vertex buffers"
The approach taken in this commit only works on drivers that expose
the PIPE_CAP_BUFFER_MAP_PERSISTENT_COHERENT capability. For drivers
that don't, the buffer has been unmapped by the time we get to
hud_draw_colored_prims, leading to crashes.
It's not easy to fix the code, but drivers that do support coherent
mapping will most likely do the right think themseleves, so let's just
go back to using user-buffers here.
This reverts commit
4fe1fd4df40ac91b2783e3604fd81e6a6faf0cd2.
Fixes: 4fe1fd4df40 ("gallium/hud: don't use user vertex buffers")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3106
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5417>
Rob Clark [Mon, 8 Jun 2020 16:52:28 +0000 (09:52 -0700)]
nir/validate: validate intr->num_components
Validate that num_components is only set for vectorized instructions, to
prevent other nir passes or driver backends from mistakenly relying on
num_components for non-vectorized instructions.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
Jose Maria Casanova Crespo [Sat, 13 Jun 2020 23:48:39 +0000 (01:48 +0200)]
vc4: don't relay on intr->num_components for non-vectorized intrinsics
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
Rob Clark [Thu, 11 Jun 2020 00:27:08 +0000 (17:27 -0700)]
v3d: don't use intr->num_components for non-vectorized intrinsics
Squashed-in-fix-from: Jose Maria Casanova Crespo <jmcasanova@igalia.com>
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
Rob Clark [Tue, 9 Jun 2020 15:35:26 +0000 (08:35 -0700)]
spriv: don't set num_components for non-vectorised intrinsics
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
Rob Clark [Mon, 8 Jun 2020 21:02:16 +0000 (14:02 -0700)]
nir/lower-atomics-to-ssbo: don't set num_components
Of the possible intrinsics generated, only load_ssbo is vectorized (and
store_ssbo is never generated)
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
Rob Clark [Mon, 8 Jun 2020 18:52:14 +0000 (11:52 -0700)]
nir/builder: don't set intr->num_components
The "load-sysval" intrinsics are not vectorized.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
Rob Clark [Mon, 8 Jun 2020 19:35:18 +0000 (12:35 -0700)]
radv: don't set num_components for non-vectorized intrinsics
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
Rob Clark [Sat, 6 Jun 2020 01:25:50 +0000 (18:25 -0700)]
freedreno/ir3: don't rely on intr->num_components
It is better to use `nir_intrinsic_dest_components()` which also handles
the case of intrinsics with a fixed number of dest components.
Somehow this starts showing up with a nir_serialize round-trip with
shader-cache. But we really shouldn't have been relying on
`intr->num_components` directly.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5371>
Dave Airlie [Tue, 16 Jun 2020 01:02:23 +0000 (11:02 +1000)]
mesa/gles3: add support for GL_EXT_shader_group_vote
This is the GLES equivalent to ARB_shader_group_vote.
Passes: KHR-GLES31.core.shader_group_vote.*
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5490>
Dave Airlie [Mon, 15 Jun 2020 00:16:06 +0000 (10:16 +1000)]
gallivm/cache: don't require a null terminator for cache data.
Fixes crashes seen with
./bin/egl_ext_device_base
since cache support was added.
Fixes: 4962d3e10733 ("gallivm: add cache interface to mcjit")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3118
Tested-by: Michel Dänzer <mdaenzer@redhat.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5467>
Alyssa Rosenzweig [Thu, 4 Jun 2020 21:36:16 +0000 (17:36 -0400)]
panfrost: Simplify AFBC format check
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5484>
Alyssa Rosenzweig [Thu, 4 Jun 2020 21:35:40 +0000 (17:35 -0400)]
panfrost: Enable AFBC for RGB565
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5484>
Alyssa Rosenzweig [Mon, 15 Jun 2020 16:42:40 +0000 (12:42 -0400)]
panfrost: Correctly calculate tiled stride
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Fixes: bde19c0e7ba ("panfrost: Fix tiled texture "stride"s on Bifrost")
Tested-by: Christian Hewitt <christianshewitt@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5474>
Alyssa Rosenzweig [Mon, 15 Jun 2020 16:37:40 +0000 (12:37 -0400)]
panfrost: Fix level_2
We're not sure what this is but I've always seen it equal to levels.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Tested-by: Christian Hewitt <christianshewitt@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5474>
Alyssa Rosenzweig [Mon, 15 Jun 2020 13:23:27 +0000 (09:23 -0400)]
panfrost: Update sampler view in Bifrost path
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Fixes: fafc305600c ("panfrost: Create a new sampler view bo when the layout changes")
Tested-by: Christian Hewitt <christianshewitt@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5474>
Alyssa Rosenzweig [Mon, 15 Jun 2020 13:20:39 +0000 (09:20 -0400)]
panfrost: Merge bifrost_bo/midgard_bo
The content is difference but a BO is a BO. Let's reduce code repition
between Midgard and Bifrost paths.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Tested-by: Christian Hewitt <christianshewitt@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5474>
Dave Airlie [Tue, 9 Jun 2020 00:41:58 +0000 (10:41 +1000)]
llvmpipe/setup: add planes for draw regions if no scissor.
Some tests were using a 1x1 fb bound, with a 2x2 viewport,
and all 4 pixels were getting rendered. Test if the fb bounds
need planes added or not.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3101
v2: add lines support
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5394>
Jonathan Marek [Sun, 14 Jun 2020 23:21:45 +0000 (19:21 -0400)]
turnip: simplify stage2 helpers
Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5455>
Jonathan Marek [Sat, 13 Jun 2020 17:52:45 +0000 (13:52 -0400)]
turnip: remove duplicated stage2opcode and stage2shaderdb
Reduce 3 copies of this same logic into a single one.
Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5455>
Rhys Perry [Thu, 11 Jun 2020 13:06:32 +0000 (14:06 +0100)]
aco: fix encoding of certain s_setreg_imm32_b32 instructions
If the mode is too small, the operand will be an inline constant and the
literal dword won't be written.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Thu, 11 Jun 2020 13:22:13 +0000 (14:22 +0100)]
aco: improve check for moving temporaries out of fixed definitions
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Thu, 11 Jun 2020 13:05:48 +0000 (14:05 +0100)]
aco: allow GFX9 partial writes with instructions which use opsel
Some instructions such as v_mad_f16 can do partial writes on GFX9.
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Tue, 19 May 2020 12:41:43 +0000 (13:41 +0100)]
aco: add more opcodes to can_swap_operands
fossil-db (Navi, fp16 enabled):
Totals from 310 (0.24% of 127638) affected shaders:
CodeSize:
1290508 ->
1289716 (-0.06%)
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Samuel Pitoiset [Thu, 9 Apr 2020 14:41:00 +0000 (16:41 +0200)]
aco: allow to swap operands for some 16-bit float instructions
No fossil-db changes.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Tue, 19 May 2020 10:45:12 +0000 (11:45 +0100)]
aco: validate sub-dword pseudo instructions
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Fri, 15 May 2020 19:26:39 +0000 (20:26 +0100)]
aco: optimize 16-bit and 64-bit float comparisons
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Mon, 18 May 2020 18:42:40 +0000 (19:42 +0100)]
aco: copy-propagate constants through p_extract_vector/p_split_vector
fossil-db (Navi, fp16 enabled):
Totals from 1 (0.00% of 127638) affected shaders:
CodeSize: 4388 -> 4392 (+0.09%)
VMEM: 465 -> 458 (-1.51%)
Copies: 54 -> 55 (+1.85%)
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Fri, 15 May 2020 15:28:03 +0000 (16:28 +0100)]
aco: improve 8/16-bit constants
fossil-db (Navi, fp16 enabled):
Totals from 1 (0.00% of 127638) affected shaders:
CodeSize: 4540 -> 4388 (-3.35%)
Instrs: 861 -> 830 (-3.60%)
Cycles: 3444 -> 3320 (-3.60%)
VMEM: 489 -> 465 (-4.91%)
SMEM: 107 -> 110 (+2.80%)
SClause: 31 -> 30 (-3.23%)
Copies: 58 -> 54 (-6.90%)
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Mon, 15 Jun 2020 13:30:34 +0000 (14:30 +0100)]
aco: use 32-bit inline constants for 16-bit integer instructions
See https://reviews.llvm.org/D81841
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Mon, 15 Jun 2020 13:21:03 +0000 (14:21 +0100)]
aco: fix half_pi constant for 16-bit fsin/fcos
This worked because the optimizer didn't consider that the 16-bit
instruction would interpret the inline constant differently. This will
change in the next commit.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Mon, 18 May 2020 14:26:58 +0000 (15:26 +0100)]
aco: improve sub-dword check for sgpr/constant propagation
p_create_vector can have sub-dword operands with a v1 definition.
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Fri, 15 May 2020 14:12:33 +0000 (15:12 +0100)]
aco: create 16-bit input and output modifiers
fossil-db (Navi, fp16 enabled):
Totals from 1 (0.00% of 127638) affected shaders:
CodeSize: 4552 -> 4540 (-0.26%)
Instrs: 863 -> 861 (-0.23%)
Cycles: 3452 -> 3444 (-0.23%)
VMEM: 490 -> 489 (-0.20%)
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Tue, 19 May 2020 12:24:45 +0000 (13:24 +0100)]
aco: update comment about preserving fp16/fp64 denormals
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Thu, 14 May 2020 20:09:36 +0000 (21:09 +0100)]
aco: create 16-bit mad/fma
fossil-db (Navi, fp16 enabled):
Totals from 1 (0.00% of 127638) affected shaders:
CodeSize: 4868 -> 4552 (-6.49%)
Instrs: 956 -> 863 (-9.73%)
Cycles: 3824 -> 3452 (-9.73%)
VMEM: 504 -> 490 (-2.78%)
SMEM: 109 -> 107 (-1.83%)
VClause: 19 -> 20 (+5.26%)
Copies: 54 -> 58 (+7.41%)
PreVGPRs: 43 -> 41 (-4.65%)
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Fri, 15 May 2020 13:03:15 +0000 (14:03 +0100)]
aco: try to use fma instead of mad when denormals are enabled
v_mad_f32 doesn't support denormals but v_fma_f32 does.
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Fri, 15 May 2020 13:24:12 +0000 (14:24 +0100)]
aco: create mads when signed zeros should be preserved
This check was added because I thought v_mad_f32 didn't preserve the
signess of zero, but I can't reproduce that and this isn't mentioned
anywhere in LLVM.
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Fri, 15 May 2020 12:58:20 +0000 (13:58 +0100)]
aco: add and set precise flag
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Thu, 11 Jun 2020 13:35:13 +0000 (14:35 +0100)]
aco: use p_as_uniform in emit_vop1_instruction
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Tue, 19 May 2020 10:53:44 +0000 (11:53 +0100)]
aco: improve code for f2{i,u}{8,16}
Use sub-dword definitions so that the RA can use SDWA
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Rhys Perry [Tue, 19 May 2020 12:26:21 +0000 (13:26 +0100)]
aco: use num_opcodes instead of last_opcode
No fossil-db changes.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5245>
Erik Faye-Lund [Thu, 4 Jun 2020 10:38:08 +0000 (12:38 +0200)]
nir: do not try to merge xfb-outputs
It's tricky to merge XFB-outputs correctly, because we need there to not
be any overlaps when we get to `nir_gather_xfb_info_with_varyings` later
on. We currently trigger an assert there if we end up merging here.
So let's not even try. This is an optimization, and we can optimize this
in safe cases later if needed. For now, let's play it safe.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5329>
Rob Clark [Mon, 15 Jun 2020 15:32:22 +0000 (08:32 -0700)]
turnip: drop linking libfreedreno_drm
Now that it is no longer required.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5476>
Rob Clark [Fri, 5 Jun 2020 19:56:04 +0000 (12:56 -0700)]
freedreno/ir3: move the libdrm dependency out of shared code
The only reason for this dependency was the fd_bo used for the uploaded
shader. But this isn't used by turnip. Now that we've unified the
cleanup path from gallium, it isn't hard to pull the fd_bo upload/free
parts into ir3_gallium.
This cleanup has the added benefit that the shader disk-cache will not
have to deal with it.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5476>
Rob Clark [Fri, 5 Jun 2020 19:41:29 +0000 (12:41 -0700)]
freedreno/ir3: unify shader create/delete paths
In particular, to move the fd_bo create/delete (which is unneeded by
turnip) out of the shared ir3 code, it is useful to have a single
delete path.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5476>
Mike Blumenkrantz [Wed, 10 Jun 2020 19:26:07 +0000 (15:26 -0400)]
zink: rework input/output location emission
glsl builtins that have no analog in spirv are emitted as regular varyings,
which means they take up a slot.
we need to ensure that there's no conflict between these regular varying
slots (from user-defined varyings) and the glsl translated builtins, so
we do that by "reserving" the max number of varying slots that can be used
by a given stage, then remapping all glsl builtins with no spirv builtin
to a packed layout location that can be consistent across stages
sort of addresses mesa/mesa#3113 except now there's 10 fewer varying slots
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5432>
Mike Blumenkrantz [Thu, 11 Jun 2020 19:22:53 +0000 (15:22 -0400)]
zink: handle more glsl->spirv builtin translation
this should be all of them, though the check for vertex shader stage needs
to be changed to !fragment stage at some point
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5432>
Samuel Pitoiset [Tue, 26 May 2020 11:54:34 +0000 (13:54 +0200)]
spirv: fix using OpSampledImage with OpUndef instead of OpType{Image,Sampler}
This seems valid per the SPIR-V spec to use OpSampledImage with
OpUndef instead of OpTypeImage or OpTypeSampler. When the image
operand is undefined, SPIRV->NIR emits an undef instruction that
can be removed later by the compiler.
This fixes shader compilation crashes with Red Dead Redemption II.
Cc: mesa-stable@lists.freedesktop.org>
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5230>
Alyssa Rosenzweig [Fri, 12 Jun 2020 20:45:24 +0000 (16:45 -0400)]
pan/mdg: Precolour blend inputs
Instead of requiring an explicit unoptimized move, we can implicitly
colour the blend input intrinsic to r0, where it will be preloaded; this
is a simple task for RA, and does not conflict with anything. If there
are multiple duplicate loads, the latter ones can just be simple moves
which will be copypropped.
We don't need to include a explicit synthetic load, since (scanning
backwards) the read will cause the input to become live at the right
time and the lack of an explicit write will keep it live from the
beginning of the shader. So no need to make it more complicated than it
needs to be.
Saves a cycle in blend shaders.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5449>
Yevhenii Kolesnikov [Thu, 11 Jun 2020 17:36:26 +0000 (20:36 +0300)]
nvir: don't use designated initialisers in C++ code
This feature only available since C++20.
Fixes: fa0a241b335 ("nvir/nir: move nir options to codegen")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3114
Signed-off-by: Yevhenii Kolesnikov <yevhenii.kolesnikov@globallogic.com>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5430>
Samuel Pitoiset [Thu, 11 Jun 2020 20:25:53 +0000 (22:25 +0200)]
ac: add ac_choose_spi_color_formats() to common code
It's similar between RADV and RadeonSI.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5436>
Jonathan Marek [Sun, 14 Jun 2020 03:50:22 +0000 (23:50 -0400)]
freedreno/ir3: fix ir3_nir_move_varying_inputs
ir3_nir_move_varying_inputs is broken when there a load input outside of
the first block which depends on the result of a previous load input.
This simplification/rework avoids the problem, and should also be faster.
Fixes this dEQP-VK test:
dEQP-VK.pipeline.multisample_interpolation.offset_interpolate_at_pixel_center.128_128_1.samples_2
Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5465>
Eric Engestrom [Wed, 3 Jun 2020 19:58:32 +0000 (21:58 +0200)]
intel/tools: make test aware of the meson test wrapper
Suggested-by: Dylan Baker <dylan@pnwbakers.com>
Signed-off-by: Eric Engestrom <eric@engestrom.ch>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5155>
Eric Engestrom [Wed, 31 Jul 2019 11:19:55 +0000 (12:19 +0100)]
intel/tools: rewrite run-test.sh in python
Old script created files in the source directory, which is generally
considered bad form.
The rewrite to python instead of duct-taping around in the shell script
goes towards the goal of only having cross-platform python scripts,
which is also harder to make mistakes in than shell scripts.
Signed-off-by: Eric Engestrom <eric@engestrom.ch>
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5155>
Eric Engestrom [Sun, 3 May 2020 18:55:55 +0000 (20:55 +0200)]
post_version.py: update script to the new rST way of things
Signed-off-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Eric Engestrom [Wed, 29 Apr 2020 00:02:28 +0000 (02:02 +0200)]
gen_release_notes.py: update script to the new rST way of things
Signed-off-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Mon, 20 Apr 2020 12:12:36 +0000 (14:12 +0200)]
docs/release-calendar: restore missing id
I'm not sure how this got dropped, but it somehow did during conversion.
Let's restore it.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Mon, 20 Apr 2020 11:12:12 +0000 (13:12 +0200)]
bin/perf-annotate-jit.py: update internal reference
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Mon, 20 Apr 2020 11:11:10 +0000 (13:11 +0200)]
radv: update internal reference
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Mon, 20 Apr 2020 11:40:10 +0000 (13:40 +0200)]
docs/relnotes: update internal references
I'm not 100% sure if it feels right to update these. I mean, this keeps
links working as they should, even if exported to something else than
HTML. But it also feels a bit like history revisionism. It's probably
the right thing to do, though.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Mon, 20 Apr 2020 11:10:12 +0000 (13:10 +0200)]
docs: update internal references
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Mon, 20 Apr 2020 11:07:37 +0000 (13:07 +0200)]
README: update references to internal docs
These documents are no longer HTML files, so the internal reference
should be updated.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Thu, 30 Jan 2020 18:27:17 +0000 (19:27 +0100)]
docs: drop news in favour of the introduction as index-page
This kind of only makes sense once we have a separate home-page. But I
think this is a good way of showing why we should do this; Sphinx
doesn't support pagination, because it's not meant as a general-purpose
website framewrork. And for documentation, pagination is not really
something you need.
There's probably a lot more pages that should be moved into a separate
webpage, similar to this. In general, I think this should be done for
pages that don't relate to the source code too much, e.g isn't needed to
understand the code, or for instance explains how to get the source code.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Mon, 27 May 2019 15:12:10 +0000 (17:12 +0200)]
gitlab-ci: build and deploy docs
Dunno if alpine is a good idea. It's what the gitlab docs use for most
of their examples, so that's what I've gone with... Can probably be
changed to something else if wanted.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Sat, 18 Apr 2020 09:54:11 +0000 (11:54 +0200)]
docs: include specs into the generated docs
Unfortunately, it doesn't seem like there's a way to have sphinx copy
this without moving the files, becasue html_extra_path doesn't copy the
directory itself when given a directory, only files inside and
subdirectories.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Sat, 18 Apr 2020 09:44:57 +0000 (11:44 +0200)]
docs: bundle extra files
These are documents that are bundled in the root of the website, and
contains some useful, extra documentation. Let's include them.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Sat, 18 Apr 2020 10:55:14 +0000 (12:55 +0200)]
docs: use rst-note for highlighted text
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Sat, 18 Apr 2020 09:20:31 +0000 (11:20 +0200)]
docs: reformat license table as rst table
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Sat, 18 Apr 2020 09:07:53 +0000 (11:07 +0200)]
docs: use rst footnotes instead of manual ones
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Laura Ekstrand [Mon, 11 Jun 2018 22:42:39 +0000 (15:42 -0700)]
docs: Add the favicon to the new page.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Erik Faye-Lund [Mon, 10 Jun 2019 18:15:08 +0000 (20:15 +0200)]
docs: do not copy source-files to site
These docs have publically available sources in the first place, there's
no point in including a copy of them here as well.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>
Laura Ekstrand [Wed, 6 Jun 2018 21:43:35 +0000 (14:43 -0700)]
docs: Remove version.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4630>