Alyssa Rosenzweig [Wed, 30 Mar 2022 20:18:06 +0000 (16:18 -0400)]
pan/bi: Handle shared atomic exchange on Valhall
Need to lower the WLS into a segment addition, since the .seg modifier was
dropped on Valhall.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16410>
Alyssa Rosenzweig [Wed, 30 Mar 2022 19:56:41 +0000 (15:56 -0400)]
pan/bi: Preserve AXCHG.i32 destination
dEQP-GLES31.functional.image_load_store.2d.atomic.exchange_r32f_result
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16410>
Alyssa Rosenzweig [Wed, 30 Mar 2022 19:52:22 +0000 (15:52 -0400)]
pan/bi: Support image loads on Valhall
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16410>
Alyssa Rosenzweig [Wed, 30 Mar 2022 18:12:06 +0000 (14:12 -0400)]
pan/bi: Emit LEA_TEX on Valhall
As opposed to LEA_ATTR_TEX. In principle we could do this for Bifrost too, but
let's keep the Midgard compatible path for now.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16410>
Alyssa Rosenzweig [Fri, 23 Jul 2021 22:04:24 +0000 (18:04 -0400)]
pan/bi: Don't analyze td on Valhall
The implementation is based on clauses, so it won't work on Valhall.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16410>
Autumn on Tape [Thu, 5 May 2022 00:45:22 +0000 (17:45 -0700)]
lavapipe: enable subgroup quad operations
Signed-off-by: Autumn on Tape <autumn@cyfox.net>
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16340>
Corentin Noël [Tue, 10 May 2022 15:23:24 +0000 (17:23 +0200)]
mesa: Make sure to fallback to handling the original choose texture format
It is possible for st_ChooseTextureFormat to return MESA_FORMAT_NONE when
samples is forced to 2. Always allow to fallback to the original case.
Fixes:
89c94502b6650fed222abd3588e9c927811580aa
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6441
Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16432>
Dave Airlie [Mon, 9 May 2022 01:24:59 +0000 (11:24 +1000)]
aco: drop unused radv include
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Dave Airlie [Thu, 5 May 2022 04:27:01 +0000 (14:27 +1000)]
aco: remove radv vs prolog key from aco internals.
This creates an aco specific key, and converts radv to it.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Dave Airlie [Thu, 5 May 2022 03:34:41 +0000 (13:34 +1000)]
aco/radv: convert to aco shader info at the radv level.
This removes the radv shader info type from aco completely.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Dave Airlie [Thu, 5 May 2022 02:42:03 +0000 (12:42 +1000)]
aco/info: add some more fields.
These fields are also used in aco.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Dave Airlie [Thu, 5 May 2022 02:22:13 +0000 (12:22 +1000)]
aco: convert vs and so info over to aco structs.
This renames the vs to vp (vertex pipeline) on the way past.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Dave Airlie [Thu, 5 May 2022 02:17:15 +0000 (12:17 +1000)]
aco: remove radv specific streamout info
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Dave Airlie [Thu, 5 May 2022 02:11:53 +0000 (12:11 +1000)]
aco/info: reduce the gs ring info to what is needed.
Only one member was being used.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Dave Airlie [Thu, 5 May 2022 01:51:50 +0000 (11:51 +1000)]
aco: move to a minimal aco shader info struct.
This should be kept to only things aco uses, and expanded when
radeonsi support is added. Things should be removed if lowered in NIR.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Dave Airlie [Thu, 5 May 2022 01:32:53 +0000 (11:32 +1000)]
aco: move info pointer to a copy.
This is just setup to move this to a different struct later.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16342>
Georg Lehmann [Fri, 6 May 2022 12:48:38 +0000 (14:48 +0200)]
radv: Don't retile read-only images.
Avoid unnessecary work on FOREIGN queue release barriers. If we can't modify
the image there can't be a situation where we need to update the presentable
dcc data.
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16371>
Danylo Piliaiev [Mon, 9 May 2022 17:28:28 +0000 (20:28 +0300)]
pps: Open writable renderer node in DrmDevice::create
DrmDevice::create_all correctly opened the node with O_RDWR, while
DrmDevice::create was not, causing failure to create writable buffer.
Fixes pps-config on Freedreno.
Fixes:
1cc72b2aef82373247466c2e7b81970c867ad0fa
("pps: Gfx-pps v0.3.0")
Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Reviewed-by: Antonio Caggiano <antonio.caggiano@collabora.com>
Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16406>
Jason Ekstrand [Thu, 5 May 2022 17:47:34 +0000 (12:47 -0500)]
panvk: Advertise support for logicOp
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Jason Ekstrand [Tue, 3 May 2022 17:34:44 +0000 (12:34 -0500)]
nir/lower_blend: Expand or shrink output variables as needed
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Jason Ekstrand [Mon, 9 May 2022 20:24:46 +0000 (15:24 -0500)]
midgard: Handle FB fetch from non-vec4 output variables.
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Jason Ekstrand [Mon, 9 May 2022 20:16:16 +0000 (15:16 -0500)]
nir/builder: Add a nir_resize_vector helper
We're about to use this a couple of places.
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Jason Ekstrand [Mon, 9 May 2022 17:15:44 +0000 (12:15 -0500)]
nir/builder: Add a nir_trim_vector helper
This pattern pops up a bunch and the semantics of nir_channels() aren't
very convenient much of the time. Let's add a nir_trim_vector() which
matches nir_pad_vector().
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Jason Ekstrand [Tue, 3 May 2022 15:55:24 +0000 (10:55 -0500)]
nir/lower_blend: Support SNORM and integer formats for logic ops
This fixes 158 of the dEQP-VK.pipeline.logic_op.* tests, once we turn
the feature on.
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Jason Ekstrand [Tue, 3 May 2022 15:44:30 +0000 (10:44 -0500)]
nir/lower_blend: Stop passing the whole options object around
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Jason Ekstrand [Tue, 3 May 2022 14:28:01 +0000 (09:28 -0500)]
nir/lower_blend: Be more explicit about deref assumptions
Because we pull the RT from the variable location and use that to look
up formats, we need a constant RT index. To deal with arrays (possibly
of arrays), we would either need to handle array derefs (we don't today)
or we need to require the variables to be split into one variable per
RT. Given that we have to lower indirect derefs anyway (to get constant
indices), we may as well require the client to split output variables by
calling nir_lower_io_arrays_to_elements_no_indirect().
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Jason Ekstrand [Tue, 3 May 2022 18:08:29 +0000 (13:08 -0500)]
panvk: Call nir_lower_io_arrays_to_elements_no_indirects
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16309>
Martin Roukala (né Peres) [Tue, 10 May 2022 10:08:38 +0000 (13:08 +0300)]
ci/radv: remove amdgpu.gpu_recovery=0 from the kernel cmdline
This was set as an attempt to detect when the GPU got hung, and let
our hangcheck detect this issue and kill the run. This however has
not been working so well, so let's try without it.
Suggested-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16423>
Iago Toral Quiroga [Wed, 11 May 2022 07:16:09 +0000 (09:16 +0200)]
v3dv: expose VK_KHR_spirv_1_4
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16424>
Iago Toral Quiroga [Tue, 10 May 2022 10:53:08 +0000 (12:53 +0200)]
v3dv: expose VK_KHR_shader_float_controls
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16424>
Danylo Piliaiev [Thu, 5 May 2022 17:29:05 +0000 (20:29 +0300)]
tu: Do not flush ccu in clear/blits during renderpass
For clear/blits ccu flush not only worse for perf, but also messes up
flush_bits when executed in a conditional set of commands.
We already don't flush for 3d blits.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6419
Fixes:
487aa807bd1b70602fcb6fbdabd101d4cff7c07b
("tu: Rewrite flushing to use barriers")
Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16352>
Samuel Pitoiset [Tue, 10 May 2022 12:02:09 +0000 (14:02 +0200)]
radv: remove useless check against nir_texop_samples_identical
nir_texop_samples_identical is lowered to
nir_texop_fragment_mask_fetch_amd earlier.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16426>
Marek Olšák [Sat, 7 May 2022 19:37:34 +0000 (15:37 -0400)]
radeonsi: report more missing/broken texture formats as unsupported on gfx6-9
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16386>
Marek Olšák [Sat, 7 May 2022 19:30:44 +0000 (15:30 -0400)]
radeonsi: report 10_10_10_2 scaled formats as unsupported on gfx6-9 as well
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16386>
Dave Airlie [Mon, 11 Apr 2022 03:42:58 +0000 (13:42 +1000)]
radv: optimised command buffer reset of vertex bindings.
This takes the buffer ptrs out of the struct, so they can be memset
separately and optimises the memset to be minimal for them.
Removing them from the struct avoids having to loop to clear them.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16393>
Dave Airlie [Mon, 9 May 2022 06:16:08 +0000 (16:16 +1000)]
radv: only dirty line stipple when necessary.
Line stipple only cares if things changes to/from line strip.
Reduces overheads seen running pixmark volplosion with zink.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16393>
Dave Airlie [Mon, 9 May 2022 06:06:58 +0000 (16:06 +1000)]
radv: cache the slab bo pointer in the pipeline.
Otherwise each emission has to pointer chase across cachelines.
Reduces overhead seen with zink on pixmark volplosion test.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16393>
Dave Airlie [Mon, 9 May 2022 05:51:45 +0000 (15:51 +1000)]
zink: don't finish barriers cmd buffer if not used.
finishing has some cpu overhead, which if the cmd buffer isn't
going to be used is pointless. just let it get reset next time.
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16393>
Dave Airlie [Mon, 9 May 2022 05:51:20 +0000 (15:51 +1000)]
zink: avoid extra submits for empty wait cmdbufs.
This just avoids cpu overheads from processing that won't get used.
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16393>
Vinson Lee [Sat, 7 May 2022 00:17:50 +0000 (17:17 -0700)]
radeonsi: Move NULL check before dereference.
Fix defect reported by Coverity Scan.
Dereference before null check (REVERSE_INULL)
check_after_deref: Null-checking desc suggests that it may be
null, but it has already been dereferenced on all paths leading to
the check.
Fixes:
2f83dce059 ("radeonsi: don't report R64_*INT as a sampler format because it doesn't work")
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16380>
Dave Airlie [Tue, 10 May 2022 01:47:33 +0000 (11:47 +1000)]
radeonsi: port tess ring calcs to the common helper.
This uses the common helper code to implement the tess ring sizing.
One question is if radeonsi should be using tess_offchip_ring_offset
in some places it's using tess_factor_ring_size?
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16415>
Dave Airlie [Tue, 10 May 2022 01:44:01 +0000 (11:44 +1000)]
ac: port radeonsi tess factor calculations to common code.
This was updated in
4e49a05e37232 ("radeonsi: increase the tesselation factor ring size")
and
9fecac091f315 ("radeonsi/gfx11: scattered register deltas")
This will apply this to radv.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16415>
Dave Airlie [Tue, 10 May 2022 01:41:54 +0000 (11:41 +1000)]
radv/ac: introduce a new common function for hs calcs.
This ports the radv code to the new ac code.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16415>
Mike Blumenkrantz [Fri, 29 Apr 2022 15:52:52 +0000 (11:52 -0400)]
zink: create images with modifiers any time there is an import handle
there's no way to pass in a plane offset otherwise, so this is necessary
in order to handle yuv imports
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 15:02:55 +0000 (11:02 -0400)]
zink: rebind resources for export as needed
exporting all resources breaks suballocation, so instead just use the
existing heuristics and then forcibly rebind resources as needed
for this functionality
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 15:01:49 +0000 (11:01 -0400)]
zink: add a LINEAR drm modifier if rebinding to add dmabuf export
this needs to have some kind of modifier, so be conservative here
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 15:01:06 +0000 (11:01 -0400)]
zink: force memory exports if dmabuf bind is specified
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 15:00:12 +0000 (11:00 -0400)]
zink: fix conditional for modifier usage
the shared check here was inaccurate; if the resource has dmabuf
export, then use modifiers
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 14:59:31 +0000 (10:59 -0400)]
zink: add a bind flag to indicate a resource is exported as a dmabuf
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 14:57:53 +0000 (10:57 -0400)]
zink: unset pipe_resource::next pointers when creating resource copies
this otherwise walks the chain and destroys all the resources
cc: mesa-stable
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 14:52:27 +0000 (10:52 -0400)]
zink: always check for fb rebinds when starting renderpass
ensure the right image is being used
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 11:42:05 +0000 (07:42 -0400)]
Revert "zink: export fd info for all 2d images"
This reverts commit
fda7371b4cfc5a15f2207f5165f3a8e14442a522.
this breaks suballocation
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 11:41:52 +0000 (07:41 -0400)]
zink: create a copy context for the screen on init
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 11:41:32 +0000 (07:41 -0400)]
zink: introduce copy contexts
this is for creating a context which is only used for copying images
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 11:41:02 +0000 (07:41 -0400)]
zink: break out resource bind-adding into separate function for reuse
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 11:40:44 +0000 (07:40 -0400)]
zink: add a flag to indicate whether a resource is exportable
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 11:34:33 +0000 (07:34 -0400)]
zink: outdent some code
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Mike Blumenkrantz [Fri, 29 Apr 2022 11:26:09 +0000 (07:26 -0400)]
zink: remove unused headers/struct members/linkage
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252>
Michael Skorokhodov [Tue, 10 May 2022 07:48:53 +0000 (10:48 +0300)]
glsl: Fix ir_quadop_vector validation
Some glcts tests have failed due to incorrect processing of `ir_quadop_vector` in
`ir_validation`. e.g:
`GLES31.functional.shaders.builtin_functions.integer.imulextended.int_highp_geometry`
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6461
Fixes:
23cde71b ("glsl: Stop lowering ir_quadop_vector.")
Reviewed-by: Emma Anholt <emma@anholt.net>
Signed-off-by: Mykhailo Skorokhodov <mykhailo.skorokhodov@globallogic.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16420>
Benjamin Cheng [Mon, 4 Apr 2022 04:35:19 +0000 (00:35 -0400)]
radv: fix memory leak of descriptor set layout
We need to be able to track the descriptor sets explicity to unref the
descriptor sets, otherwise these descriptor sets will not unref the
descriptor set layout it holds.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6222
Fixes:
66f7289d568
("radv: add reference counting for descriptor set layouts")
Tested-by: Jakob Bornecrantz <jakob@collabora.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15741>
Mike Blumenkrantz [Tue, 10 May 2022 19:32:20 +0000 (15:32 -0400)]
kopper: remove unused zink include
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16441>
Daniel Schürmann [Tue, 4 Jan 2022 09:59:07 +0000 (09:59 +0000)]
radv: call nir_lower_vars_to_ssa later
Totals from 599 (0.44% of 134913) affected shaders: (GFX10.3)
CodeSize: 1243732 -> 1240512 (-0.26%); split: -0.26%, +0.00%
Instrs: 223370 -> 222702 (-0.30%); split: -0.30%, +0.00%
Latency: 901762 -> 885446 (-1.81%); split: -1.81%, +0.00%
InvThroughput: 305546 -> 305536 (-0.00%)
SClause: 12690 -> 12554 (-1.07%); split: -1.13%, +0.06%
Copies: 23779 -> 23778 (-0.00%)
PreSGPRs: 17781 -> 17829 (+0.27%)
Acked-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5668>
Daniel Schürmann [Wed, 24 Jun 2020 15:22:54 +0000 (16:22 +0100)]
radv: move two NIR passes out of tight optimization loop
nir_remove_dead_variables
nir_opt_shrink_vectors
Acked-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5668>
Iván Briano [Tue, 10 May 2022 01:30:20 +0000 (18:30 -0700)]
anv: re-alloc push constants after secondary command buffers
If the secondary command buffer executed used push constants on a
different set of stages than the primary is using, we may end up not
reallocating them for the primary, getting misrender artifacts at best,
or a nice GPU hang at worst.
Fixes the tests from a CTS from the future:
dEQP-VK.dynamic_rendering.random.*
Cc: mesa-stable
Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16439>
Adam Jackson [Fri, 6 May 2022 19:31:26 +0000 (15:31 -0400)]
dri: Remove what's left of utils.[ch]
Which is just moving the struct definition for __DRIconfigRec into
dri_util.h.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16377>
Adam Jackson [Fri, 6 May 2022 19:21:53 +0000 (15:21 -0400)]
dri: Move dri{Get,Index}ConfigAttrib near their vtable
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16377>
Adam Jackson [Fri, 6 May 2022 19:15:58 +0000 (15:15 -0400)]
dri: Move driC{reate,oncat}Configs near their only caller
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16377>
Adam Jackson [Fri, 6 May 2022 18:11:04 +0000 (14:11 -0400)]
dri: move driQueryRendererIntegerCommon near its one caller
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16377>
Adam Jackson [Fri, 6 May 2022 14:49:04 +0000 (10:49 -0400)]
dri: Move driCopySubBufferExtension into drisw
drisw is the only consumer so rename things to make it a bit more
obvious.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16377>
Adam Jackson [Thu, 5 May 2022 20:52:07 +0000 (16:52 -0400)]
dri: Inline dri2InvalidateDrawable into its one caller
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16377>
Charmaine Lee [Mon, 9 May 2022 06:42:41 +0000 (23:42 -0700)]
svga/nir: enable lower double option
There is no translation support for dfloor, mod, and pow
in svga_tgsi_vgpu10, just enable the lowering passes in the
nir compile option.
Reviewed-by: Neha Bhende <bhenden@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16412>
Charmaine Lee [Fri, 6 May 2022 21:45:55 +0000 (14:45 -0700)]
svga/tgsi: add translation for DTRUNC
DTRUNC is not lowered in glsl-nir-tgsi path. Add the translation
in svga_tgsi_vgpu10().
Reviewed-by: Neha Bhende <bhenden@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16412>
Charmaine Lee [Tue, 10 May 2022 16:34:57 +0000 (09:34 -0700)]
svga: enable PIPE_CAP_TGSI_TEXCOORD for vgpu10 and up
Revise commit
0d456315f95 to enable PIPE_CAP_TGSI_TEXCOORD for
vgpu10 and up only.
Reviewed-by: Neha Bhende <bhenden@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16434>
Mike Blumenkrantz [Tue, 10 May 2022 17:17:59 +0000 (13:17 -0400)]
zink: ci updates
I don't know how !16167 made this pass, but no driver seems to be able to
pass this test, so ignore
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Tue, 10 May 2022 03:37:34 +0000 (23:37 -0400)]
docs: EXT_robustness2 for lavapipe
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Tue, 26 Apr 2022 13:48:57 +0000 (09:48 -0400)]
lavapipe: ci updates
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Sat, 23 Apr 2022 15:42:34 +0000 (11:42 -0400)]
lavapipe: set robustBufferAccess2 and robustImageAccess2
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Sat, 23 Apr 2022 15:40:48 +0000 (11:40 -0400)]
gallivm: fix oob txf swizzling
this wasn't taking into account the format swizzle, returning broken
alpha values in most cases
Fixes:
0b6554ba6f2 ("gallivm,llvmpipe: handle TXF (texelFetch) instruction, including offsets")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Erik Faye-Lund [Wed, 21 Apr 2021 09:12:35 +0000 (11:12 +0200)]
lavapipe: add support for null-descriptors from EXT_robustness2
Mike says this should be enough for full support, so let's see ;)
Nope, no robust image or buffer access implemented yet.
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Sat, 23 Apr 2022 13:39:06 +0000 (09:39 -0400)]
llvmpipe: always set ssbo data pointers for draw
skipping these would lead to reading the previously-set data if
a null buffer was set after a valid buffer
cc: mesa-stable
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Fri, 22 Apr 2022 18:47:38 +0000 (14:47 -0400)]
gallivm/draw: fix oob ubo reads
the first case in gallivm did no checking, so this was always going to be
broken, so instead just copy the now-correct ssbo logic
cc: mesa-stable
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Tue, 26 Apr 2022 14:23:36 +0000 (10:23 -0400)]
st/draw_feedback: set constant buffer stride
these shaders all do float-based reads, so using vec4 for robustness
checks breaks gallivm
cc: mesa-stable
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Fri, 22 Apr 2022 18:16:42 +0000 (14:16 -0400)]
lavapipe: fix CmdPushDescriptorSetWithTemplateKHR with refcounting
this is a cmdbuf function, which means it gets enqueued, which means
the template can't be destroyed until the cmdbuf has finished using it
cc: mesa-stable
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Fri, 22 Apr 2022 17:52:22 +0000 (13:52 -0400)]
gallivm: fix ssbo oob reads
this was checking (offset < size) when really it needs to be
(offset < size && extent < size && offset >= 0)
Fixes:
591899eedd2 ("gallivm/nir: Add a short circuit uniform-offset mode for load_ssbo/load_shared.")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Mike Blumenkrantz [Sat, 23 Apr 2022 15:42:57 +0000 (11:42 -0400)]
lavapipe: handle null samplerviews
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Erik Faye-Lund [Wed, 14 Jul 2021 08:17:41 +0000 (10:17 +0200)]
lavapipe: tolerate NULL sampler-buffer view descriptors
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Erik Faye-Lund [Mon, 26 Apr 2021 15:11:01 +0000 (17:11 +0200)]
lavapipe: tolerate NULL image-buffer view descriptors
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Erik Faye-Lund [Mon, 26 Apr 2021 15:10:36 +0000 (17:10 +0200)]
lavapipe: tolerate NULL image view descriptors
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Erik Faye-Lund [Mon, 26 Apr 2021 14:44:27 +0000 (16:44 +0200)]
lavapipe: tolerate NULL UBO and SSBO descriptors
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16137>
Georg Lehmann [Mon, 9 May 2022 09:52:26 +0000 (11:52 +0200)]
nir/opt_algebraic: Simple xor/ishr optimizations.
The first pattern here removes the xor-swap pattern.
Foz-DB GFX10_3:
Totals from 305 (0.23% of 134913) affected shaders:
CodeSize: 1589040 -> 1585164 (-0.24%)
Instrs: 284344 -> 283375 (-0.34%)
Latency: 4205148 -> 4198472 (-0.16%); split: -0.16%, +0.00%
InvThroughput: 708745 -> 708739 (-0.00%)
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16411>
Georg Lehmann [Sat, 16 Apr 2022 11:36:17 +0000 (13:36 +0200)]
nir/opt_algebraic: Fix mask in shift by constant combining.
The comment above is correct, but the code to calculate the mask was broken.
No Foz-db changes outside of noise.
Fixes:
0e6581b87dc ("nir/algebraic: Reassociate shift-by-constant of shift-by-constant")
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15990>
Timur Kristóf [Fri, 1 Apr 2022 15:55:28 +0000 (17:55 +0200)]
radv/amdgpu: Use scheduled dependency for submitting to multiple queues.
This code path will be used on kernels that don't have the
"gang submit" feature in amdgpu yet.
It does each submission separately, and uses scheduled dependencies
to connect them.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-By: Tatsuyuki Ishi <ishitatsuyuki@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16361>
Timur Kristóf [Tue, 10 May 2022 10:47:46 +0000 (12:47 +0200)]
radv/amdgpu: Pass correct struct type instead of repeating the cast.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16361>
Timur Kristóf [Thu, 5 May 2022 19:51:44 +0000 (21:51 +0200)]
radv/amdgpu: Pass new queue submit info structure to internal function.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-By: Tatsuyuki Ishi <ishitatsuyuki@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16361>
Timur Kristóf [Thu, 5 May 2022 19:50:44 +0000 (21:50 +0200)]
radv/amdgpu: Initialize semaphore info with a designated initializer.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-By: Tatsuyuki Ishi <ishitatsuyuki@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16361>
Timur Kristóf [Thu, 5 May 2022 19:43:09 +0000 (21:43 +0200)]
radv/amdgpu: Group queue submit info into a structure.
This prepares RADV for submitting to multiple queues at the same time.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-By: Tatsuyuki Ishi <ishitatsuyuki@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16361>
Timur Kristóf [Wed, 23 Mar 2022 18:25:38 +0000 (19:25 +0100)]
ac/llvm: Remove now-superfluous intrinsics and ABI callbacks.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13155>
Timur Kristóf [Wed, 23 Mar 2022 18:20:47 +0000 (19:20 +0100)]
aco: Remove now-superfluous intrinsics.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13155>
Timur Kristóf [Wed, 23 Mar 2022 18:13:20 +0000 (19:13 +0100)]
ac/nir: Remove now-superfluous ac_nir_lower_tess_to_const.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13155>
Timur Kristóf [Wed, 16 Mar 2022 11:39:47 +0000 (12:39 +0100)]
radv: Lower ABI in NIR for tess/ESGS/NGG shader arguments.
Totals from 58720 (45.64% of 128653) affected shaders:
VGPRs: 2056576 -> 2056568 (-0.00%)
CodeSize:
153906488 ->
154609536 (+0.46%); split: -0.00%, +0.46%
MaxWaves: 1665056 -> 1665058 (+0.00%)
Instrs:
29242117 ->
29417265 (+0.60%); split: -0.00%, +0.60%
Latency:
134149608 ->
134238738 (+0.07%); split: -0.00%, +0.07%
InvThroughput:
20348833 ->
20349641 (+0.00%); split: -0.00%, +0.00%
VClause: 489376 -> 489385 (+0.00%)
SClause: 729383 -> 729382 (-0.00%)
Copies: 2672567 -> 2673132 (+0.02%); split: -0.00%, +0.02%
Branches: 1192117 -> 1192121 (+0.00%); split: -0.00%, +0.00%
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13155>