Commit Graph

149429 Commits

Author SHA1 Message Date
Adam Jackson
6c984b1469 dri_interface: Remove the remaining DRI1 API definitions
None of these are used anymore, and as a bonus we can drop the dance
around the libdrm headers.

Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14738>
2022-01-26 23:56:16 +00:00
Nanley Chery
57445adc89 anv: Re-enable CCS_E on TGL+
Commit e614789588 ("anv: Also disallow CCS_E for multi-LOD images")
accidentally disabled CCS_E on TGL+ because it checked for
image->vk.mip_levels > 0 instead of image->vk.mip_levels > 1.

Instead of reverting it, we remove the code which disables CCS_E for
mipmapped or arrayed images now that we've sufficiently handled the
clear color issue in other ways.

Fixes: e614789588 ("anv: Also disallow CCS_E for multi-LOD images")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14723>
2022-01-26 23:34:33 +00:00
Nanley Chery
c48401404c anv: Use ANV_FAST_CLEAR_DEFAULT_VALUE for CCS on TGL+
On TGL, if a block of fragment shader outputs match the surface's clear
color, the HW may convert them to fast-clears (see HSD 14010672564).
This can lead to rendering corruptions if not handled properly. We
restrict the clear color to zero to avoid issues that can occur with:

   - Texture view rendering (including blorp_copy calls)
   - Images with multiple levels or array layers

Fixes: e614789588 ("anv: Also disallow CCS_E for multi-LOD images")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14723>
2022-01-26 23:34:33 +00:00
Nanley Chery
d68b2db89c anv: Disable CCS_E for some 8/16bpp copies on TGL+
CCS_E is currently disabled on TGL+, but we'll enable it soon. We choose
to explicitly disable it for certain copy operations to avoid CTS
failures in the following groups:

- dEQP-VK.drm_format_modifiers.export_import.*
- dEQP-VK.synchronization*

Fixes: e614789588 ("anv: Also disallow CCS_E for multi-LOD images")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14723>
2022-01-26 23:34:33 +00:00
Nanley Chery
09ca089144 anv: Drop assert against modifier with aux on gfx12
Commit b664349973 ("anv: Enable implicit CCS for external images")
introduced support for implicit CCS with I915_FORMAT_MOD_Y_TILED.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14723>
2022-01-26 23:34:33 +00:00
Erik Faye-Lund
f07f4d5ec5 docs: use http-redirect when possible
GitLab Pages has added a feature to do proper HTTP redirects, which
are genreally better than the HTML redirects we currently use.

Unfortunately, it doesn't support redirecting to other domains, all
paths must start with a slash. So there's sadly *one* redirect this
doesn't work for. So let's leave that one using a HTML redirect, and
use HTTP redirects when we can.

Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14369>
2022-01-26 23:26:50 +00:00
Emma Anholt
53426d26c3 softpipe: Dispatch 4 CS invocations per tgsi_exec thread.
We were executing 1 non-helper invocation and 3 helpers per CS tgsi_exec
machine, which was a total waste of the CPU when we could trivially have
all 4 invocations do real work (at least in the common case of a
gl_WorkGroupSize.x >= 4).

This didn't have the effect on dEQP that I was hoping for, as it turns out
that its shaders are almost all 1x1x1 workgroups.  However, it does reduce
the runtime of piglit arb_compute_shader-local-id from 2:10 to 47 seconds
on my system.

Part of #4097

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14728>
2022-01-26 22:52:19 +00:00
Emma Anholt
62dc4be470 softpipe: Initialize the CS dispatch mask at machine setup time.
It's not modified later, so no need to reset it per barrier or per
workgroup.

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14728>
2022-01-26 22:52:19 +00:00
Emma Anholt
2fe2a2b080 softpipe: Improve some local var naming in compute shaders.
These aren't dimensions, they're gl_LocalInvocationID.xyz.

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14728>
2022-01-26 22:52:19 +00:00
Emma Anholt
13b57a8cad tgsi_exec: Fix shared var stores for >1 real invocation, and overflow checks.
The shared var store overflow checks left a lot of overflowing
opportunities available, while the buffer storage path did proper
checking.  But, more importantly for this branch, it always used the first
invocation's offset for each invocation in the quad (which only worked so
far because softpipe only dispatched a single non-helper invocation
per quad).

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14728>
2022-01-26 22:52:19 +00:00
Hyunjun Ko
8a5b949a3e turnip: fix leaks of submit requests.
Fixes: 479a1c40 ("turnip: Porting to common vulkan implementation for synchronization.")

Signed-off-by: Hyunjun Ko <zzoon@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14727>
2022-01-26 22:22:33 +00:00
Mike Blumenkrantz
8bca29dcf0 zink: return 256 for PIPE_CAP_MIN_MAP_BUFFER_ALIGNMENT
this isn't the minimum allowed by the driver, but zink doesn't return
the minimum allowed by the driver anyway and hasn't in a very long time

instead, it suballocates using a minimum alignment of 256 bytes, so use
that instead

fixes (in caselists):
KHR-GL46.map_buffer_alignment.functional

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14720>
2022-01-26 22:05:53 +00:00
Michel Zou
a7ae3bcdf8 zink: fix unused variable warning
fixes: 4ed30be3

Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14739>
2022-01-26 21:51:13 +00:00
Eric Engestrom
dcbabb9c9d docs/release-calendar: add another 21.3.x since 22.0 has been delayed a bit
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14737>
2022-01-26 20:43:36 +00:00
Eric Engestrom
956c93e154 docs: update calendar and link releases notes for 21.3.5
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14737>
2022-01-26 20:43:36 +00:00
Eric Engestrom
b486dfd1a4 docs: add release notes for 21.3.5
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14737>
2022-01-26 20:43:36 +00:00
Jason Ekstrand
fe71f4d9ec .mailmap: Switch Jason Ekstrand to @collabora.com
Jason is starting at Collabora on the 24th.  More details at
https://www.jlekstrand.net/jason/blog/2022/01/hello-collabora/

Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14586>
2022-01-26 20:08:31 +00:00
Yiwei Zhang
96acd0933e tu: VkExternalImageFormatProperties is optional
..even if external image info has valid external handles.

Fixes: 26380b3a9f ("turnip: Add driver skeleton (v2)")

Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14730>
2022-01-26 16:35:10 +00:00
Ruijing Dong
49e02d076d radeon/vcn: Updating render_pic_list for correction
In order to keep track of reference frame buffer address changing,
using past_ref to compare with render_pic_list, once the one in
past_ref is valid and if render_pic_list has that entry, it will
need to update it to the latest one in ref[i].

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5868

Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Reviewed-by: Leo Liu <leo.liu@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14646>
2022-01-26 15:28:55 +00:00
Ruijing Dong
cf16368977 frontend/va: Keep surface buf addr before reallocation
The reference buffer address is used as the indication in h264 DPB
Tier2, when reference buffer was reallocated, h264 DPB would lose
track of that reference picture. Adding a pointer obsolete_buf in
vlVaSurface data structure for tracking this released buffer, also
in h264_picture_desc adding a private field, which contains
past_ref[16] for tracking previously released buffer vs current
buffer for reference frames.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5868

Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Reviewed-by: Leo Liu <leo.liu@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14646>
2022-01-26 15:28:55 +00:00
Mike Blumenkrantz
8747715aec zink: reorder fbfetch flag-setting to avoid null deref
this avoids dereferencing pg->dd which is allocated a few lines later

Fixes: 417477f60e ("zink: always use lazy (non-push) updating for fbfetch descriptors")

fixes (radv):
dEQP-GLES31.functional.blend_equation_advanced.basic.multiply

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14718>
2022-01-26 14:59:56 +00:00
Rhys Perry
7a0cf7f6d1 radv: fix optimized MSAA copies with suballocated images
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Fixes: deb4685df3 ("radv: implement optimized MSAA copies using FMASK")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5829
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14705>
2022-01-26 10:54:33 +00:00
Mike Blumenkrantz
e4218e5c4d zink: handle bogus xfb draws
drawing unpopulated xfb data is legal(?) and tested in cts, and the correct
operation is to just drop the draw, so do that here

fixes (nvidia):
GTF-GL46.gtf40.GL3Tests.transform_feedback2.transform_feedback2_api

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14694>
2022-01-26 04:00:42 +00:00
Iván Briano
61ece8f6a4 anv: Enable VK_KHR_dynamic_rendering
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Iván Briano
5d9e8bc9be anv: implement the meat of VK_KHR_dynamic_rendering
Includes a fake framebuffer allocation that's necessary for the code we
still use from the regular render passes.

v3: (Lionel)
- Reuse the attachment count from the faux render pass, remove now
  unused function
- Add a cmd_buffer_end_rendering function to match begin_rendering,
  making use of the split stuff from end_subpass

v4: (Lionel)
- Don't bother with mark_images_writen or resolves on suspend case
- Remove flush at the end of end_rendering, it's not needed

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Iván Briano
4ad9ccd28a anv: split end_subpass into more discrete components
v3: Split cmd_buffer_end_subpass instead of doing parts conditionally (Lionel)

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Iván Briano
2f942f3217 anv: Split attachment clearing code into their own functions
v3: Avoid recalculating parameters the caller already had (Lionel)

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Iván Briano
e41436beec anv: allocate fake render pass for continuation command buffers
v4: Assert if there's no VkCommandBufferInheritanceRenderingInfoKHR (Lionel)

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Iván Briano
b32023573d anv: Split out state attachments allocation
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Iván Briano
5d9aaea31f anv: allocate fake render pass on pipeline creation
v3: (Lionel)
- Handle VkPipelineRenderingCreateInfoKHR not being present
- Rename dynamic_pass and set it for regular render passes too

v4: C99 is good (Lionel)

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Iván Briano
73ed019bec anv: add functions to set up fake render passes
There's two of them because they can be created from three points in the
code that provide different details and this is the least ugly way I
could think of for now.

v2: Avoid allocations (Lionel)

v3: Move definition closer to its usage (Lionel)

v4: (Lionel)
 - Simplify anv_dynamic_pass_init_full
 - Zero out pass/subpass to avoid stall pointers

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Iván Briano
b18bc028ee anv: Remove unused struct member
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Jason Ekstrand
6612dcc425 anv/pass: Don't set first_subpass_layout for stencil-only attachments
Cc: mesa-stable@lists.freedesktop.org

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13980>
2022-01-25 18:13:51 -08:00
Alyssa Rosenzweig
ee044d445d panfrost: Remove NO_BLEND_PACKS quirk
Now unused.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14724>
2022-01-26 01:45:09 +00:00
Alyssa Rosenzweig
5a8d86f69e panfrost: Simplify format class selection
This was made way more complicated than it needs to be for a Midgard-only pass.
The only caller doesn't care about the class, only if it's native or not.
Simplify it appropriately.

It really isn't that hard.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14724>
2022-01-26 01:45:09 +00:00
Alyssa Rosenzweig
da9d6a643a panfrost: Don't set NO_BLEND_PACKS on Bifrost
It doesn't make sense on Bifrost -- the only consumer of the quirk is
pan_lower_framebuffer, a Midgard-only pass.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14724>
2022-01-26 01:45:09 +00:00
Alyssa Rosenzweig
93f6c6586c panfrost: Remove MIDGARD_{NO_TYPED_BLEND_STORES,MISSING_LOADS}
These "quirks" are common for Midgard, yet are only consumed by
pan_lower_framebuffer -- a Midgard-only pass. So the quirks should be removed
and inlined into their users. Thid removes MIDGARD_QUIRKS altogether.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14724>
2022-01-26 01:45:09 +00:00
Alyssa Rosenzweig
db497c27dc panfrost: Remove NO_TILE_ENABLE_MAP quirk
Function of architecture. Add a comment to the sole consumer of the quirk bit
about why it's used.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14724>
2022-01-26 01:45:09 +00:00
Alyssa Rosenzweig
bbe0517481 panfrost: Remove MIDGARD_BROKEN_FP16 quirk
Unused.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14724>
2022-01-26 01:45:09 +00:00
Alyssa Rosenzweig
d4575bcc79 panfrost: Remove MIDGARD_SFBD quirk
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14724>
2022-01-26 01:45:09 +00:00
Alyssa Rosenzweig
47a7e26954 panfrost: Remove HAS_SWIZZLES quirk
It's a function of the major arch.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14724>
2022-01-26 01:45:09 +00:00
Jesse Natalie
ed42b129ef d3d12: Set caps for tesselation
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00
Jesse Natalie
278b30723f d3d12: Handle input clip array size in the shader key
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00
Jesse Natalie
df302f5f90 d3d12: Update varying creation logic to handle location_frac
When multiple variables are packed into the same location, we need
to re-construct variables that read/write the same components of that
register so that the DXIL signature is correct. We could try to
merge these variables, but getting the types right sounds harder than
just preserving the multiple individual variables.

Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00
Jesse Natalie
1a231ec805 d3d12: Add a state variable for patch_vertices_in
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00
Jesse Natalie
de438f381f d3d12: Handle passthrough TCS in the case where eval is bound
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00
Jesse Natalie
224c1562c1 d3d12: Handle patch_vertices and patch topology
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00
Jesse Natalie
c83476ff13 d3d12: Link tesselation control and eval shaders
GLSL puts a bunch of tessellation info in the eval shaders, because
passthrough control shaders can exist. D3D12 puts it in the control
(hull) shader instead. So, when specializing, copy info from domain
to hull. For initial compiles (no domain shader), just make something
up.

D3D12 also requires the domain and hull shaders to have identical
patch constant signatures. Use the existing infrastructure and extend
it to also propagate patch constants. Notably, patch constant locations
are outside of the 64-bit range value so they require a separate pass
to avoid shifts larger than 64.

Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00
Jesse Natalie
0ed7b44f5c d3d12: Initial plumbing for tesselation
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00
Jesse Natalie
22156821ea d3d12: Enable PIPE_CAP_TGSI_TEXCOORD
This is required to be able to use the necessary number of varyings,
otherwise we hit asserts because mesa/st starts assigning varyings
locations above 64 due to the +9 reserving these texcoords.

Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Bill Kristiansen <billkris@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14399>
2022-01-26 01:31:35 +00:00