Dave Airlie [Mon, 26 Sep 2022 04:11:30 +0000 (14:11 +1000)]
gallivm/llvmpipe: add opaque pointers support to sampler
This adds explicit context types wiring through the sampler code
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18947>
Dave Airlie [Mon, 3 Oct 2022 23:41:00 +0000 (09:41 +1000)]
llvmpipe/tests: port to new pointer interfaces.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18947>
José Roberto de Souza [Fri, 2 Sep 2022 13:55:22 +0000 (06:55 -0700)]
anv: Split the debug part of anv_queue_exec_locked()
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18942>
José Roberto de Souza [Wed, 17 Aug 2022 19:44:29 +0000 (12:44 -0700)]
anv: Use Vulkan types for priority as much as possible
Continuing the work to split i915_drm.h specific code.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18942>
José Roberto de Souza [Wed, 10 Aug 2022 18:33:33 +0000 (11:33 -0700)]
anv: Split i915 specific parts of anv_queue_submit_simple_batch()
This will make easier to spot more places where the code can
simplified after the hasvk split.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18942>
José Roberto de Souza [Mon, 8 Aug 2022 20:26:59 +0000 (13:26 -0700)]
anv: Move fetch of i915 physical device parameters
Move everything that depends on i915_drm.h to its own function,
in a future MR will move the parameters that are also needed by
Iris to intel_device_info.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18942>
José Roberto de Souza [Mon, 8 Aug 2022 16:18:34 +0000 (09:18 -0700)]
intel/dev: Split i915 specific parts of intel_get_device_info_from_fd()
Continuing the work to split i915_drm.h specific code.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18942>
José Roberto de Souza [Mon, 8 Aug 2022 18:25:26 +0000 (11:25 -0700)]
intel: Make engine related functions and types not i915 dependent
There is too much i915_drm.h code spread, this patch start to fix that
by re-organizing engine related code.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18942>
Yiwei Zhang [Mon, 3 Oct 2022 19:39:24 +0000 (19:39 +0000)]
docs: move VK_EXT_extended_dynamic_state3 out from 1.3
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Ryan Neph <ryanneph@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18941>
Connor Abbott [Wed, 21 Sep 2022 14:46:53 +0000 (16:46 +0200)]
tu: Implement extendedDynamicState2PatchControlPoints
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18773>
Connor Abbott [Wed, 21 Sep 2022 12:38:21 +0000 (14:38 +0200)]
tu: DS primitive stride does not use patch control points
Previously we would use patch control points if there was no GS, but
it wasn't immediately obvious that this driver param is unused if there
is no GS. Make it output 0 instead, making it clear that we can emit it
even if we don't know the patch control points. This change in the
cmdstream is split out from the next commit.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18773>
Connor Abbott [Wed, 21 Sep 2022 11:46:27 +0000 (13:46 +0200)]
tu: Fix param_stride placement
Even though it's tessellation-related, it's set based on the
tessellation variant which is only known after linking. The param stride
may change due to LTO if fast linking is not used.
Fixes:
e9f5de11d40 ("tu: Initial implementation of VK_EXT_graphics_pipeline_library")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18773>
Simon Zeni [Mon, 3 Oct 2022 18:25:22 +0000 (14:25 -0400)]
mesa: fix GL_INVALID_OPERATION in glEGLImageTargetTexStorageEXT
Using EGLImages from DMA-BUF as target storage should return
GL_INVALID_OPERATION if the target is not GL_TEXTURE_2D or
GL_TEXTURE_EXTERNAL_OES.
Fixes:
6a3f5c65 ("mesa: simplify st_egl_image binding process for texture storage")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18939
Signed-off-by: Simon Zeni <simon@bl4ckb0ne.ca>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18939>
Connor Abbott [Mon, 26 Sep 2022 16:40:53 +0000 (18:40 +0200)]
ir3: Add missing cat5 encoding to asm parser
We were missing the case where there is a sampler and texture but the
texture offset is encoded in a1.x.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18840>
Connor Abbott [Mon, 26 Sep 2022 16:31:48 +0000 (18:31 +0200)]
ir3/analyze_ubo_ranges: Account for reserved consts better
It turns out that the ir3_setup_const_state() already includes reserved
consts, so we were accidentally counting it twice. This makes us use
less consts, and if there are enough reserved consts can make it go
negative and wrap around. Fix this while also making sure the previous
bug remains fixed.
Fixes:
8cb1deded60 ("ir3/analyze_ubo_ranges: Account for reserved consts")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18840>
Connor Abbott [Mon, 26 Sep 2022 16:27:53 +0000 (18:27 +0200)]
ir3: Move fixup_regfootprint() to ir3_collect_info()
This fixes the case where fixup_regfootprint() adds to the reg footprint
but it isn't accounted for when determining whether we should double
threadsize in ir3_collect_info(). This would produce a hang on a650 and
above where we have a reg footprint of 33 and doubled threadsize.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18840>
Connor Abbott [Mon, 26 Sep 2022 16:12:04 +0000 (18:12 +0200)]
ir3: Delete outputs from fixup_regfootprint()
We weren't considering the number of components, which means that we
would overestimate the output size, which could result in nonsensical
things like a reg footprint of larger than r48.x. In addition, in some
cases we can force double regsize which would go badly if this
miscalculated the reg footprint, although currently this only happens
with compute shaders where there are no outputs. It's not actually
necessary anyway, because any output must come from an input or
something in the shader - this is how RA works. Just delete it.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18840>
Alejandro Piñeiro [Thu, 29 Sep 2022 13:03:27 +0000 (15:03 +0200)]
v3dv/pipeline: use a array instead of individual pointer to stages
Before this commit we were using individual pointers to each pipeline
stage struct. We did that instead of an array because we needed to had
a pointer for the binner stages too, and at that time we didn't have a
enum to handle those stages.
Since then we introduced broadcom_shader_stage, and started to use in
a lot of places (and per-stage arrays) so we can now use an array.
The main advantage is being able to handle several cases as
loops. This also adds some consistency to the code (because as
mentioned, in a lot of other places we use an array).
Reviewed-by: Eric Engestrom <eric@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18943>
Georg Lehmann [Mon, 3 Oct 2022 09:18:40 +0000 (11:18 +0200)]
aco: Use s_pack_ll for s_bfe operand on GFX9+.
Foz-DB Navi21:
Totals from 1 (0.00% of 134913) affected shaders:
CodeSize: 340 -> 336 (-1.18%)
Instrs: 77 -> 76 (-1.30%)
Latency: 1065 -> 1063 (-0.19%)
InvThroughput: 4260 -> 4252 (-0.19%)
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18936>
Tapani Pälli [Mon, 3 Oct 2022 15:56:46 +0000 (18:56 +0300)]
intel: revert preemption disable via VFG changes
This register will not be whitelisted and this change will be
done in kernel instead.
This change reverts commits
d5d4604a,
ddcd6b38,
27c5b93d.
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18897>
Gert Wollny [Fri, 30 Sep 2022 13:27:13 +0000 (15:27 +0200)]
nir_lower_to_source_mods: Don't sneek in an abs modifier from parent
If the abs source modifiers is not supported for the current
instruction because it is an instruction with three sources we
may still see a parent mov that has the `abs` modifier. In this
case we must not propagate that abs modifier from that parent
instructions.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7350
Fixes:
cd73b6174b093b75f581c3310bf784bed7c74c1f
nir/lower_to_source_mods: Stop turning add, sat, and neg into mov
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18902>
Dave Airlie [Mon, 3 Oct 2022 22:44:38 +0000 (08:44 +1000)]
vulkan: update beta and video headers to 1.3.230
Acked-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18945>
Dave Airlie [Thu, 29 Sep 2022 04:24:20 +0000 (14:24 +1000)]
gallium/tgsi: handle temps/outputs array.
The old code used GetElementType on a pointer, to pick a path,
I cant find a test to hit the second path, so just hardcode it
for now.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Dave Airlie [Wed, 28 Sep 2022 22:10:37 +0000 (08:10 +1000)]
gallivm/tgsi: port tgsi to explicit types.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Dave Airlie [Tue, 27 Sep 2022 05:26:23 +0000 (15:26 +1000)]
draw: handle primid for tess being a different pointer type
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Dave Airlie [Mon, 26 Sep 2022 07:29:08 +0000 (17:29 +1000)]
draw: fix gs/tes explicit pointer handling
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Dave Airlie [Mon, 26 Sep 2022 08:35:39 +0000 (18:35 +1000)]
llvmpipe/fs/linear: port to explicit pointers.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Dave Airlie [Tue, 27 Sep 2022 05:34:56 +0000 (15:34 +1000)]
gallivm/llvmpipe: hand sample position type in for loading.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Dave Airlie [Mon, 26 Sep 2022 06:21:12 +0000 (16:21 +1000)]
gallivm/sample: move border color load to explicit pointers
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Dave Airlie [Mon, 26 Sep 2022 08:16:08 +0000 (18:16 +1000)]
gallivm/nir: fixup atomic path for explicit pointers.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Dave Airlie [Mon, 26 Sep 2022 07:05:35 +0000 (17:05 +1000)]
gallivm/nir: move to explicit pointer interfaces.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18932>
Yiwei Zhang [Mon, 3 Oct 2022 19:32:28 +0000 (19:32 +0000)]
docs: update venus extension support
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18940>
Yiwei Zhang [Mon, 3 Oct 2022 19:31:23 +0000 (19:31 +0000)]
venus: move vendor ext to bottom and sort the ext list
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18940>
Konstantin Seurer [Sat, 1 Oct 2022 18:15:03 +0000 (20:15 +0200)]
radv: Fix incorrect build info indexing
Fixes: 8666b1f ("radv: Build acceleration structures using BVH IR")
Reviewed-by: Friedrich Vock <friedrich.vock@gmx.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18928>
Emma Anholt [Thu, 8 Sep 2022 00:11:47 +0000 (17:11 -0700)]
ci/iris: Update iris traces checksums.
The previous commits in this MR caused a minor rendering change for
Unvanquished.
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18466>
Emma Anholt [Wed, 7 Sep 2022 14:03:43 +0000 (07:03 -0700)]
glsl: Remove lower_vec_index_to_swizzle.
GLSL's lower_vector_derefs already does this, and even if it didn't
nir_vector_extract() would when glsl-to-nir happens.
No effect on freedreno shader-db.
Reviewed-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18466>
Emma Anholt [Wed, 7 Sep 2022 13:34:03 +0000 (06:34 -0700)]
glsl: remove opt_structure_splitting.
nir_lower_vars_to_ssa will split temp structs up anyway. This fixes a bug
where mediump wouldn't be propagated to the split vars.
The effect is tiny, I think just shuffling some code scheduling from
optimizing at different places. Affects Natural Selection 2, Serious Sam
3, 3dmark slingshot, and Lego Legacy.
freedreno shader-db:
total instructions in shared programs:
11315637 ->
11315993 (<.01%)
instructions in affected programs: 24861 -> 25217 (1.43%)
Reviewed-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18466>
Emma Anholt [Wed, 7 Sep 2022 13:28:14 +0000 (06:28 -0700)]
glsl: Remove opt_array_splitting.
nir_lower_vars_to_ssa will split temp arrays up anyway. Fixes a bug where
split arrays wouldn't get their precision qualifier.
Helps mostly Android and skia shaders. Also affects Civ5, Witcher 2, and
Borderlands 2.
freedreno shader-db:
total instructions in shared programs:
11319395 ->
11319355 (<.01%)
instructions in affected programs: 65744 -> 65704 (-0.06%)
Reviewed-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18466>
Emma Anholt [Wed, 7 Sep 2022 14:05:28 +0000 (07:05 -0700)]
glsl: Remove do_set_program_inouts.
No longer used since
214c774ba6c7 ("mesa/st: Remove st_glsl_to_tgsi.").
Reviewed-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18466>
Emma Anholt [Wed, 7 Sep 2022 13:01:54 +0000 (06:01 -0700)]
glsl: Remove lower_output_reads.
No longer used since
214c774ba6c7 ("mesa/st: Remove st_glsl_to_tgsi.").
Reviewed-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18466>
Emma Anholt [Thu, 29 Sep 2022 23:57:38 +0000 (16:57 -0700)]
nir/vars_to_ssa: Always do OOB load/store removal.
We elminated OOB loads while renaming vars to SSA. However, if the OOB
load only appeared after some other passes had constant folded, there may
be no renaming work to do, at which point we'd leave the OOB load deref
around without renaming it or deleting it. For vc4, this was quite a
surprise and caused a regression when we stop eliminating some OOB
accesses at the GLSL level.
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18466>
Ruijing Dong [Fri, 30 Sep 2022 14:08:45 +0000 (10:08 -0400)]
d3d12: Updating refactored fields in pipe_h264_enc_picture_desc
Updating accesses to refactored fields in pipe_h264_enc_picture_desc
Reviewed-By: Sil Vilerino <sivileri@microsoft.com>
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18877>
Ruijing Dong [Thu, 29 Sep 2022 20:08:44 +0000 (16:08 -0400)]
radeonsi/vcn: support aspect ratio and vui timing info
add aspect ratio and vui timing info into vui
for both avc/hevc encoder.
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18877>
Ruijing Dong [Thu, 29 Sep 2022 20:07:11 +0000 (16:07 -0400)]
frontends/va: add aspect ratio and vui timing info
add aspect ratio and vui timing info to va interface
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18877>
Ruijing Dong [Thu, 29 Sep 2022 19:50:19 +0000 (15:50 -0400)]
radeonsi/vcn: use avc seq paramters
- use avc seq parameters
- clean up pipe_264_enc_picture_desc structure
- clean up get_param function
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18877>
Ruijing Dong [Thu, 29 Sep 2022 19:49:23 +0000 (15:49 -0400)]
frontends/va: apply avc seq parameters
using avc seq parameters
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18877>
Ruijing Dong [Thu, 29 Sep 2022 19:47:27 +0000 (15:47 -0400)]
frontends/omx: apply avc seq parameters
change omx according to avc seq parameters
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18877>
Ruijing Dong [Thu, 29 Sep 2022 19:45:56 +0000 (15:45 -0400)]
radeonsi/vce: apply avc seq parameters
just apply avc seq parameters
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18877>
Ruijing Dong [Thu, 29 Sep 2022 19:38:31 +0000 (15:38 -0400)]
gallium/pipe/video: group avc encoder seq structure
Prepare for using new seq structure
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18877>
Emma Anholt [Thu, 29 Sep 2022 18:24:58 +0000 (11:24 -0700)]
nir/nir_opt_copy_prop_vars: Don't leak dynarray memory during the pass.
It was swept at the end, but it meant that in shaders with lots of copies
available at the start of lots of if statements, you'd blow up memory
usage.
turnip memory consumption on dEQP-VK.ssbo.layout.random.scalar.75 drops
from 1.4GB to 110MB, and runtime from 19s to 17s.
Fixes: #7361
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18891>
José Roberto de Souza [Fri, 30 Sep 2022 17:18:13 +0000 (10:18 -0700)]
intel: Share code to read render timestamp
Timestamp read is not in any hot path so there is no down-sides in
share the same function between iris, crocus, anv and hasvk.
Also while at it also dropping the functions to read MMIO from kernel,
the only use is read render timestamp so we don't need it.
v2:
- fix compilaton of ds
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18920>
Rajnesh Kanwal [Wed, 21 Sep 2022 15:19:45 +0000 (16:19 +0100)]
pvr: Implement vkCmdExecuteCommands API.
Signed-off-by: Rajnesh Kanwal <rajnesh.kanwal@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18871>
Rajnesh Kanwal [Wed, 21 Sep 2022 18:12:59 +0000 (19:12 +0100)]
pvr: Add support to copy a control stream to another control stream.
Signed-off-by: Rajnesh Kanwal <rajnesh.kanwal@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18871>
Rajnesh Kanwal [Wed, 21 Sep 2022 15:56:49 +0000 (16:56 +0100)]
pvr: Reserve space for vdm state for deferred secondary buffer.
For secondary buffer we need to emit additional vdm state along
with additional ppp state words to provide depthbias and scissor
indexes. These are indexes into depthbias and scissor tables.
In vkCmdExecuteCommands we append secondary buffer tables to primary
buffer tables, so the depthbias and scissor indexes change and
need fixing. This is why we need to emit these separatly.
Signed-off-by: Rajnesh Kanwal <rajnesh.kanwal@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18871>
Rajnesh Kanwal [Wed, 21 Sep 2022 15:54:59 +0000 (16:54 +0100)]
pvr: Create deferred control stream for secondary command buffers.
Signed-off-by: Rajnesh Kanwal <rajnesh.kanwal@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18871>
Rajnesh Kanwal [Wed, 21 Sep 2022 15:45:13 +0000 (16:45 +0100)]
pvr: Add support for PVR_CMD_STREAM_TYPE_GRAPHICS_DEFERRED stream.
This adds support for PVR_CMD_STREAM_TYPE_GRAPHICS_DEFERRED type control
stream. The main difference is that this is backed by host memory.
This is mainly needed for secondary command buffers allocated with
VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT. In this case we need
to copy secondary command buffer's control stream over to primary
stream in vkCmdExecuteCommands.
Signed-off-by: Rajnesh Kanwal <rajnesh.kanwal@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18871>
Rajnesh Kanwal [Wed, 21 Sep 2022 15:43:57 +0000 (16:43 +0100)]
pvr: Fix check in pvr_cmd_uses_deferred_cs_cmds.
Signed-off-by: Rajnesh Kanwal <rajnesh.kanwal@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18871>
Rajnesh Kanwal [Wed, 21 Sep 2022 15:18:19 +0000 (16:18 +0100)]
pvr: Add pvr_csb_emit_link function to support secondary buffer links.
Signed-off-by: Rajnesh Kanwal <rajnesh.kanwal@imgtec.com>
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18871>
Pavel Ondračka [Tue, 20 Sep 2022 14:55:52 +0000 (16:55 +0200)]
r300: fix reader detection with breaks
We were previously ignoring the breaks completelly. This patch
is heavily based on analysis and draft patch from Filip Gawin.
It mostly mirrors the current behavior for ENDIF with minor
differences. If the reader is in a branch leading directly to BRK,
we set the AbortOnRead mask as when encountering ENDIF but jump to
the ENDLOOP. If the reader was before the branch, we save the
AbortOnRead mask as if in normal branch handling and restore it
at the end of the loop.
Besides the single dEQP fix, this also fixes one more dEQP and few
piglits when the loop unrolling is disabled.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7249
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18900>
Pavel Ondračka [Wed, 21 Sep 2022 19:20:32 +0000 (21:20 +0200)]
Revert "r300: be less agresive with copy propagate in loops"
This reverts commit
2bdffe7eb212ddc10f2ed9ef51095886a55109b4.
This solution was mostly a workaround to fix the copy propagation.
A (hopefully) proper fix to the reader detection is in the next commit.
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18900>
Dylan Baker [Fri, 30 Sep 2022 19:13:28 +0000 (12:13 -0700)]
meson: run genxml sort tests
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 18:59:19 +0000 (11:59 -0700)]
intel/genxml: run gen_sort_tags on all of the xml
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 18:58:10 +0000 (11:58 -0700)]
intel/genxml: add a validation mode to gen_sort_tags
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 18:42:52 +0000 (11:42 -0700)]
intel/genxml: add 'nonzero' to gen_sort_tags
which was added in
ebe2a2b5f6a461ec4644accb4e7b02c430bb8f16.
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 18:40:29 +0000 (11:40 -0700)]
intel/genxml: don't overwrite the input of gen_sort_tags in place
otherwise we can be left with garbage
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 18:34:06 +0000 (11:34 -0700)]
intel/genxml: remove unused variable in gen_sort_tags.py
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 18:29:30 +0000 (11:29 -0700)]
intel/genxml: use `a not in {x, y}` instead of `a != x or a != y`
It's faster, less code, and more idiomatic
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 18:27:44 +0000 (11:27 -0700)]
intel/genxml: add type annotations to gen_sort_tags.py
let static analysis help us out
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 18:00:57 +0000 (11:00 -0700)]
intel/genxml: don't use parens with python assert statement
assert is a statement in python, not a function. Useing parens with it
leads to madness, because assert takes two arguments in the form `assert
expression: bool, message: str`. With parens though it's tempting to
write `assert(expression, message)`, which results in an assert that is
*always* true, because a non-empty tuple (which is what is written) is
*never* false.
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 17:59:15 +0000 (10:59 -0700)]
intel/genxml: use a set for lookups
Python will pre-compute the set since it's const, and the performance of
a set search is significantly better than that of a list search
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Dylan Baker [Fri, 30 Sep 2022 17:58:16 +0000 (10:58 -0700)]
intel/genxml: use a single pattern for res
regex is expensive, do less of it.
Reviewd-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18917>
Eric Engestrom [Thu, 22 Sep 2022 14:11:41 +0000 (16:11 +0200)]
docs/release-calendar: add 22.3 schedule
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18756>
Caio Oliveira [Sat, 1 Oct 2022 07:36:59 +0000 (00:36 -0700)]
intel/compiler: Explicitly include build-id when linking intel_clc
Ensure that the program will have a build-id.
Reviewed-by: Ivan Briano <ivan.briano@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18924>
Karol Herbst [Tue, 27 Sep 2022 17:08:41 +0000 (19:08 +0200)]
radeonsi: stop vectorizing unpack_32_2x16_split
nir_to_llvm can't deal with them being vectors.
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18802>
Karol Herbst [Tue, 27 Sep 2022 22:22:39 +0000 (00:22 +0200)]
ac/llvm: fix load_ubo for vectors with more than 4 elements
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18802>
Karol Herbst [Tue, 27 Sep 2022 18:10:37 +0000 (20:10 +0200)]
ac/llvm: fix load/store_shared for vectors with more than 4 elements
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18802>
Karol Herbst [Tue, 27 Sep 2022 14:45:05 +0000 (16:45 +0200)]
ac/llvm: fix load_const for vectors with more than 4 elements
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18802>
Karol Herbst [Sat, 24 Sep 2022 22:49:09 +0000 (00:49 +0200)]
ac/llvm: support non 32 bit sized workgroup ids
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18802>
Karol Herbst [Sat, 24 Sep 2022 22:01:05 +0000 (00:01 +0200)]
rusticl/kernel: assign locations before passing the nir to drivers
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18802>
Karol Herbst [Sat, 24 Sep 2022 19:09:32 +0000 (21:09 +0200)]
rusticl: limit global mem to 2GB
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18802>
Martin Roukala (né Peres) [Sat, 1 Oct 2022 03:46:19 +0000 (06:46 +0300)]
ci/b2c: add support for the new format of CI_RUNNER_TAGS
Seems like Gitlab did not follow their own documentation:
```
CI_RUNNER_TAGS 8.10 0.5 A comma-separated list of the runner tags.
```
But it would seem like a gitlab update brought json-style lists which
broke:
```
CI_RUNNER_TAGS = '["keywords-gateway", "CI-gateway"]'
```
This commit adds support for both style.
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Reviewed-by: John Brooks <john@fastquake.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18923>
Karol Herbst [Wed, 28 Sep 2022 00:01:45 +0000 (02:01 +0200)]
rusticl/mem: align fill pattern buffer to 4 bytes
drivers might treat it as a uint32_t* buffer.
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18853>
Caio Oliveira [Thu, 29 Sep 2022 20:30:31 +0000 (13:30 -0700)]
spirv: Enable OpEmitMeshTasksEXT workaround for Clay Shader Compiler
Clay Shader Compiler is the SPIR-V generator used by GravityMark benchmark.
Fixes #7368.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18894>
Karol Herbst [Tue, 27 Sep 2022 22:49:00 +0000 (00:49 +0200)]
rusticl/mem: fix image OOB checks
The CL API puts the array layer on the height, where gallium puts it on
the depth. This is taken into account everywhere else, except for API
validation.
Fixes:
8b9a5adf8be ("rusticl/mem: return errors for OOB accesses")
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18852>
Mike Blumenkrantz [Fri, 30 Sep 2022 03:00:41 +0000 (23:00 -0400)]
delete graw tests
These seem abandoned and they make interfaces changes less easy.
Acked-by: Marek Olšák <marek.olsak@amd.com>
Acked-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18705>
Mike Blumenkrantz [Fri, 30 Sep 2022 03:00:28 +0000 (23:00 -0400)]
delete rbug
These seem abandoned and they make interfaces changes less easy.
Acked-by: Marek Olšák <marek.olsak@amd.com>
Acked-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18705>
Mike Blumenkrantz [Fri, 30 Sep 2022 02:59:29 +0000 (22:59 -0400)]
remove xvmc
These seem abandoned and they make interfaces changes less easy.
Acked-by: Marek Olšák <marek.olsak@amd.com>
Acked-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18705>
Mike Blumenkrantz [Tue, 27 Sep 2022 18:39:56 +0000 (14:39 -0400)]
zink: set depth clamp
this is correct according to spec
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Fri, 30 Sep 2022 15:40:58 +0000 (11:40 -0400)]
zink: define zink_pipeline_dynamic_state3 as zink_rasterizer_hw_state
this ensures the structs are kept in sync
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Fri, 30 Sep 2022 04:38:07 +0000 (00:38 -0400)]
zink: reenable GPL
this is now functional again
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Sun, 25 Sep 2022 16:40:57 +0000 (12:40 -0400)]
zink: use an extra pipeline state bit to track coherent fbfetch usage for gpl outputs
bringing parity to non-gpl codepath
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Sun, 25 Sep 2022 16:18:59 +0000 (12:18 -0400)]
zink: don't deref prog->shaders during pipeline construction
this may or may not be valid depending on (upcoming) threading changes,
and the nir pointers are all readily available
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Sun, 25 Sep 2022 16:18:12 +0000 (12:18 -0400)]
zink: reorder zink_destroy_gfx_program()
this ensures that pipeline cache entries are freed before shaders
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Fri, 23 Sep 2022 16:11:35 +0000 (12:11 -0400)]
zink: move binding_map to hw_state part of vertex state
this is used when dynamic states aren't used
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Fri, 23 Sep 2022 02:24:49 +0000 (22:24 -0400)]
zink: add param to disable optimization when combining pipeline libraries
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Fri, 23 Sep 2022 02:24:25 +0000 (22:24 -0400)]
zink: require optimal_keys for GPL
this is pointless otherwise
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Fri, 23 Sep 2022 02:23:22 +0000 (22:23 -0400)]
zink: set VK_PIPELINE_CREATE_RETAIN_LINK_TIME_OPTIMIZATION_INFO_BIT_EXT
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Thu, 22 Sep 2022 21:23:44 +0000 (17:23 -0400)]
zink: further compress zink_gfx_output_key lookups
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Thu, 22 Sep 2022 21:13:10 +0000 (17:13 -0400)]
zink: compress zink_gfx_output_key members
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>
Mike Blumenkrantz [Tue, 27 Sep 2022 13:54:18 +0000 (09:54 -0400)]
zink: don't access prog->shaders array during pipeline compile
this may or may not have valid data
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18911>