Commit Graph

152232 Commits

Author SHA1 Message Date
Mike Blumenkrantz 9c212e117d nir/lower_point_size_mov: handle case where gl_Position isn't written
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15821>
2022-04-10 16:45:15 +00:00
Mike Blumenkrantz cfca760d6e mesa/st: handle copy_deref cases for adding pointsize
these may not have been lowered yet

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15821>
2022-04-10 16:45:15 +00:00
Mike Blumenkrantz a2823747bb mesa/st: fix pointsize adding check
* components is already multiplied by 4
* also verify base maxcomponents for gs

fixes #6282

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15821>
2022-04-10 16:45:15 +00:00
Mike Blumenkrantz 6357ce2b8e mesa: set PointSizeIsOne on context creation
forgot to add this when inverting the flag's meaning previously

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15821>
2022-04-10 16:45:15 +00:00
Mike Blumenkrantz f567a832ee ci: disable v3dv arm64 jobs
these have been broken for almost 48 hours

Acked-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15841>
2022-04-10 12:25:39 -04:00
Icecream95 5da8c280b7 panfrost: Remove BO mapping from import
BOs will be mapped when needed, so there is no need to mmap BOs when
importing them.

Fixes crashes when exporting a non-AFBC resource and importing it back
in the same context.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15818>
2022-04-10 01:51:04 +00:00
Mihai Preda 279eea5bda amd/llvm: Transition to LLVM "opaque pointers"
For context, see LLVM opaque pointers:
https://llvm.org/docs/OpaquePointers.html
https://llvm.org/devmtg/2015-10/slides/Blaikie-OpaquePointerTypes.pdf

This fixes the deprecation warnings in src/amd/llvm only.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15572>
2022-04-09 05:20:29 +00:00
Emma Anholt 6c0150c389 ci/zink: Mark a new GLX flake that hit an innocent MR.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15834>
2022-04-09 00:30:34 +00:00
Yiwei Zhang a263da69ec venus: prepare and feed renderer protocol info into cs
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15495>
2022-04-09 00:19:05 +00:00
Yiwei Zhang 440705d78f venus: update protocol for mask helper and ignore renderer unknown pNext
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15495>
2022-04-09 00:19:05 +00:00
Yiwei Zhang 0de968f71c venus: add cs helper stubs to be used by protocol
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15495>
2022-04-09 00:19:05 +00:00
Yiwei Zhang 2223f13b26 venus: store extension mask in renderer info
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15495>
2022-04-09 00:19:05 +00:00
Emma Anholt be713e15ab ci/softpipe: Mark some flakes that have appeared across a few MRs.
This MR got hit by one, so I checked the logs for the recent NEW flakes.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15540>
2022-04-08 23:56:11 +00:00
Emma Anholt 00e9c4f3c9 st/glsl-to-tgsi: Fix handling of csel(bool, vec, vec).
We were throwing an assertion failure across shader-db on nv92.  I'm
guessing this is a regression from !14573.

Cc: mesa-stable
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15540>
2022-04-08 23:56:11 +00:00
Emma Anholt 9b02587c5b ci/crocus: Disable pixmark-piano trace testing.
It hangchecked for me on hsw recently, too.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15832>
2022-04-08 23:32:11 +00:00
Emma Anholt 8238658a81 ci/iris: Disable pixmark-piano trace testing.
It gave me a spurious hangcheck on
https://gitlab.freedesktop.org/mesa/mesa/-/jobs/20946403, and this trace
causes trouble for a lot of drivers so just disable it on all iris.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15832>
2022-04-08 23:32:11 +00:00
Emma Anholt 5a1d19e945 tgsi/transform: Drop a stale comment.
This method returns void.

Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15782>
2022-04-08 21:31:44 +00:00
Emma Anholt ef9f2e8829 tgsi/transform: Make tgsi_transform_shader() manage token allocation.
Previously, the caller allocated storage and tgsi_transform_shader() would
emit into that, returning how many tokens it emitted.  All the callers had
to guess at how much storage was necessary, trying not to over-allocate
but also getting enough that you wouldn't (effectively) silently run out
of space.

Instead, make tgsi_transform_shader() do the allocation for you, taking
just a hint of how much space you think you need, and internally double
size when necessary.  Fixes failures on virgl with fp64 since we've added
more fp64 virglrenderer workarounds and its old "XXX: is this enough?"
allocation wasn't any more.

Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15782>
2022-04-08 21:31:44 +00:00
Emma Anholt e15154a735 nir_to_tgsi: Fix the address reg mapping for images and SSBOs to match G-T-T.
I missed these in the previous fix to mimic GLSL-to-TGSI address reg
behavior, which r600 relies on.

Fixes: 4bb9c0a28a ("nir_to_tgsi: Use the same address reg mappings as GLSL-to-TGSI did.")

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15824>
2022-04-08 21:01:42 +00:00
Emma Anholt 664f69a4d5 nir_to_tgsi: Extract const components of atomic counter offsets into Index.
virglrenderer maps atomic accesses to atomic counter declarations using
the .Index field.  We were previously emitting a .Index of 0 for array
accesses, so virglrenderer would emit
atomicIncrement(first_counter[counter_offset+array_index]).  This would
mostly work because hardware doesn't care about the bounds of counter
declarations, but if the first counter was a non-array, then the [] GLSL
emit gets dropped (can't array access a scalar!) and you'd access the
non-array first_counter instead.

Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15824>
2022-04-08 21:01:42 +00:00
Emma Anholt 8dcf7646ce r600: Add a helper function for rat_index_mode, with documentation and assert.
We have some special requirements on the address regs of our incoming
TGSI, which nir_to_tgsi violated.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15824>
2022-04-08 21:01:42 +00:00
Emma Anholt 9674d96820 r600: Stop using ArrayID to look up atomic counters.
Even if you find a matching array ID, you still need to offset by Index
compared to .start, so the ArrayID lookup didn't help.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15824>
2022-04-08 21:01:42 +00:00
Mike Blumenkrantz 0bfb3b0436 zink/kopper: don't use generated include in kopper interface
this causes build race conditions

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15830>
2022-04-08 16:33:05 -04:00
Mike Blumenkrantz b6ddf8f0a4 zink: don't generate VK_ACCESS_SHADER_READ_BIT barrier for vertex inputs
this is both redundant and illegal

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15827>
2022-04-08 20:05:24 +00:00
Mike Blumenkrantz 3bd9fcfa3d zink: don't rely on implicit access for generated barriers
compute shaders will get this wrong, so calculate access manually
using binding info

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15827>
2022-04-08 20:05:24 +00:00
Mike Blumenkrantz a72f05ff96 zink: add handling for !sync2 in renderpass dependencies
src/dst stage can't be zero without sync2

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15827>
2022-04-08 20:05:24 +00:00
Mike Blumenkrantz b7e05c56a4 zink: hook up sync2 extension
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15827>
2022-04-08 20:05:24 +00:00
Mike Blumenkrantz 46bbf49607 zink: bitcast InterpolateAtOffset offset to fvec
required by spec

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15827>
2022-04-08 20:05:24 +00:00
Mike Blumenkrantz ac8337041c zink: clamp out partial texels when creating bufferviews
this is an illegal alignment, so clamp the range to the nearest
texel offset since the shader should be hitting the robustness
case for the partial texel

affects:
dEQP-GLES31.functional.texture.texture_buffer.modify.mapbuffer_readwrite.range_size_65537

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15827>
2022-04-08 20:05:24 +00:00
Mike Blumenkrantz b3ee943050 zink: only get swapchain present semaphore on batch flush if not presented
otherwise this has already been present-waited and can just be used whenever

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15820>
2022-04-08 19:54:08 +00:00
Mike Blumenkrantz 21496dea9c zink: only get swapchain present semaphore on batch flush after acquire
otherwise this was a no-op flush from the frontend that should be ignored

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15820>
2022-04-08 19:54:08 +00:00
Mike Blumenkrantz 00e846ba88 zink: unset deferred present barrier on flush
don't need to flush this every frame

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15820>
2022-04-08 19:54:08 +00:00
Mike Blumenkrantz f0a3a4d2f1 zink: only trigger deferred present barrier if swapchain has acquired
otherwise this was just pointlessly flushed by the frontend and
can be ignored

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15820>
2022-04-08 19:54:08 +00:00
Dave Airlie 165b016bbe radv: use flush vgt streamout like PAL does.
This uses WRITE_DATA on the ME engine to reset the register, to match what
PAL does on GFX9+.

This fixes
KHR-GL45.transform_feedback_overflow_query_ARB.multiple-streams-one-buffer-per-stream
on zink/radv.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15812>
2022-04-08 18:59:15 +00:00
Vitalii.Lomaka 1407a4db69 intel/batch-decoder: Fix uninitialized scalar variables
CID: 1498516
CID: 1498560

Signed-off-by: Vitalii Lomaka <vitalii.lomaka@globallogic.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15685>
2022-04-08 18:35:34 +00:00
Mike Blumenkrantz 387f6e0173 zink: don't emit SpvCapabilityStorageImageMultisample for fbfetch
Acked-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15823>
2022-04-08 18:24:30 +00:00
Mike Blumenkrantz 538472e279 zink: handle multisampled fbfetch
this uses a shader key to flag the fbfetch as per-sample

it doesn't work, but at least it doesn't error anymore?

Acked-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15823>
2022-04-08 18:24:30 +00:00
Mike Blumenkrantz 1dd89cc09c zink: handle SUBPASS_MS in ntv
for completeness but also maybe fbfetch

Acked-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15823>
2022-04-08 18:24:30 +00:00
Jordan Justen 4862010141 intel/dev: Add ATS-M pci-ids
Ref: Bspec 44477
Ref: https://patchwork.freedesktop.org/series/101907/
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Acked-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15814>
2022-04-08 17:48:13 +00:00
Emma Anholt 949bc15ea5 nir_to_tgsi: Fix emitting the sample number for non-array MSAA image access.
It's always in .w, rather than being the next component after the
x/y/array index.

Fixes: c6d3fd8c21 ("gallium/ntt: Emit sample index when necessary for image load/store.")

Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15825>
2022-04-08 17:17:16 +00:00
Emma Anholt b18374002e virgl: Disable nir_op_ffloor to avoid sending DFLR to virglrenderer.
This means that we send ffract+fsub in place of a normal FLR, but
hopefully virglrenderer can be fixed (or doubles support removed).

Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15825>
2022-04-08 17:17:16 +00:00
Samuel Pitoiset a652c1653a radv: introduce new radv_pipeline_stage structure
This is used to store everything for a pipeline stage like the module,
the NIR, the shader arguments etc. This is inspired from ANV.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15794>
2022-04-08 16:38:30 +00:00
Samuel Pitoiset 86b1a1d5f2 radv: add missing multi inclusion define to radv_shader_args.h
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15794>
2022-04-08 16:38:30 +00:00
Samuel Pitoiset 000e9ac874 radv: rework pipeline and shaders creation feedback
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15794>
2022-04-08 16:38:30 +00:00
Samuel Pitoiset 1387593fbf radv: re-order shader stages directly in radv_create_shaders()
We will have to access pStages::pNext for modules and this will also
allow to rework feedback creation.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15794>
2022-04-08 16:38:30 +00:00
Rajnesh Kanwal 748c1fdf1b pvr: Remove logic to set vk_device::alloc.
The field is being already set by vk_device_init().

Signed-off-by: Rajnesh Kanwal <rajnesh.kanwal@imgtec.com>
Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15768>
2022-04-08 15:12:04 +00:00
Iago Toral Quiroga 40f0c616e8 v3dv: fix bogus VkDrmFormatModifierProperties2EXT usage
The array is allocated for VkDrmFormatModifierPropertiesEXT, so
writring entried with type VkDrmFormatModifierProperties2EXT is
bogus.

It seems this was a mistake added with a change intended to get
rid of VK_OUTARRAY_MAKE, that changed the type of the write by
mistake.

Fixes: 56a2ccf058 ('v3dv: Stop using VK_OUTARRAY_MAKE()')

Reviewed-by: Juan A. Suarez <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15819>
2022-04-08 14:43:25 +00:00
Tomeu Vizoso 30be6788cc ci: Disable Link Power Management with RTL8153
There are reliability problems with the RTL8153 ethernet driver under
certain network loads, related to incompatibility of the device with
Link Power Management.

Add usbcore.quirks=0bda:8153:k to the kernel command line to enable the
USB_QUIRK_NO_LPM option.

Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15791>
2022-04-08 14:07:31 +00:00
Tomeu Vizoso 9d5fa59322 Revert "ci/freedreno: Disable a618 jobs"
This reverts commit 96e17287b4.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15791>
2022-04-08 14:07:31 +00:00
Juan A. Suarez Romero 36066702ad v3d: do not leak BO on query begin
This happens when we have a sequence of multiple beginQuery / endQuery
with the same target and query identifier.

As a BO is created on beginQuery but not free on endQuery (we need to
wait until either explicitly deleting the query or querying the
results), in the above sequence we are basically leaking the BO.

This ensures that any BO created before is unreference before creating
the new one.

Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15796>
2022-04-08 13:51:25 +00:00