Commit Graph

142403 Commits

Author SHA1 Message Date
Qiang Yu cf66ccf3f0 st/mesa: fix size miss match for some check
While we shrink some variable from "GLuint" to "ubyte",
need to update the check from "x != ~0U" to "x != 0xff" too.

This fixes the crash for SPECviewperf 13 benchmark medical
case.

Fixes: d947e3e2c8 "st/mesa: decrease the size of st_vertex_program"
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11757>
2021-07-08 01:21:51 +00:00
Emma Anholt f2ae76e1a6 nir_to_tgsi: Declare immediates as float on non-native-ints hardware.
Makes the values more legible on i915g, and may keep us from tripping
asserts on nouveau's non-native-integer HW.

Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11744>
2021-07-07 23:39:33 +00:00
Emma Anholt b4ad947135 nir_to_tgsi: Run copy prop (and thus dce) after lower_bool_to_float.
Fixes some i915g instruction count failures by eliminating some MOVs from
translating b2f32s.

Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11744>
2021-07-07 23:39:33 +00:00
Emma Anholt 2008ec8a43 i915g: Fix writemasking of SEQ/SNE/SSG.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11744>
2021-07-07 23:39:33 +00:00
Heinrich Fink a2c92da9a1 softpipe: add missing sentinel to debug option array
Add DEBUG_NAMED_VALUE_END to finalize debug option array (see
lp_screen.c). Otherwise debug_get_flags_option might attempt to read
debug_named_value::name at an offset and SIGSEGV.

Signed-off-by: Heinrich Fink <hfink@snap.com>
Fixes: 991def0edc ("softpipe: Convert to comma-separated SOFTPIPE_DEBUG for debug options.")
Reviewed-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11742>
2021-07-07 23:27:34 +00:00
Erik Faye-Lund b138d2f8a3 ci: fix source-deps for radv on windows
If we're giong to build RADV on Windows, we need to make sure we trigger
the build on all RADV-changes.

Fixes: d18563ea58 ("ci: Update Windows image to build RADV")
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11731>
2021-07-07 21:04:23 +00:00
Kenneth Graunke aefba29cd3 iris: Force device local memory for u_upload_mgr buffers
We try to place persistent/coherent buffers from the application in
system memory, because they want the CPU-GPU coherency.

However, our internal u_upload_mgr buffers are also flagged persistent +
coherent, but we absolutely want most of them in device local memory.

Mark had done this correctly in an earlier patch series, but I made a
mistake when refactoring things during upstreaming, and accidentally
put these in SMEM again.  This fixes that mistake.

Tested-by: Luis Felipe Strano Moraes <luis.strano@intel.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11681>
2021-07-07 13:04:11 -07:00
Dylan Baker 4ef2594056 docs: Add calendar entries for 21.2 release candidates.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11767>
2021-07-07 12:23:11 -07:00
Roman Stratiienko 80f42e1d15 AOSP: Do not add '-Wl,--gc-sections' to the linker arguments
With '-Wl,--gc-sections' meson.build cc.has_function() will never fail,
providing wrong input to the build system.

Fixes: 8621bd8d5e ("android: Add scripts to build using meson")
Signed-off-by: Roman Stratiienko <r.stratiienko@gmail.com>
Tested-by: Mauro Rossi <issor.oruam@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11637>
2021-07-07 18:32:28 +00:00
Mike Blumenkrantz 97c19ac358 lavapipe: disable line rasterization ext
need to add some gallium hooks for line drawing mode before this can
be reliably supported

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11762>
2021-07-07 14:32:16 +00:00
Mike Blumenkrantz b67a4ba4ad nir/format_convert: add ssa version of uint packing
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10619>
2021-07-07 13:41:37 +00:00
Mike Blumenkrantz c948251d2b nir/format_convert: nir_shift -> nir_shift_imm
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10619>
2021-07-07 13:41:37 +00:00
Alyssa Rosenzweig d09948e006 panfrost: Remove unused midgard-pack.h includes
Now only included from the per-gen file.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig 6b2fc9f718 panfrost: Remove pan_cmdstream.h
Now empty.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig b7975c3e90 panfrost: Move sample accessor to pan_cmdstream
Not really arch-dependent but technically uses GenXML. This is pretty
trivial anyway.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig ed56d8f7b7 panfrost: Clean up pan_cmdstream.h
We don't want other files accessing these functions except through the
vtables, since they will soon be architecture dependent.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig 035434658e panfrost: Use vtable for fragment descriptor functions
Arch dependent and not directly from Gallium.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig d4e3f4858c panfrost: Move panfrost_emit_tile_map to pan_job
...where it's actually called. Saves us from using the vtable since this
isn't version-dependent.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig fa2d70aad8 panfrost: Move launch_grid to pan_cmdstream
Same issues apply as for draw_vbo.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig c08dd038dc panfrost: Don't ralloc panfrost_blend_state
Pointless divergence from other CSO creates.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig 25a879e5f9 panfrost: Move blend CSO to cmdstream/context
Create is hardware specifc, bind/delete/set_colour is not.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig 5e992e17de panfrost: Split out prepare_rsd into a vtbl
This needs to be per-gen, but the rest of the caller does not, so let's
split this out. iris makes extensive use of this vtbl pattern for cold
paths like this one.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig cf557909eb panfrost: Move most CSO creates to pan_cmdstream.c
These need to be conditionally compiled per-generation.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Alyssa Rosenzweig a13eb5fcc5 panfrost: Move draw_vbo to pan_cmdstream.c
This needs to be conditionally compiled per-generation.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11745>
2021-07-07 13:19:35 +00:00
Samuel Pitoiset 265a900229 aco: fix emitting a16 for MIMG instructions on GFX10+
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/11734>
2021-07-07 14:44:13 +02:00
Samuel Pitoiset ffdb980a12 aco: fix emitting d16 for MIMG instructions on GFX9+
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/11734>
2021-07-07 14:44:11 +02:00
Iago Toral Quiroga b103855abc v3dv: account for dst offset of copy query results operations
This fixes several CTS tests with this pattern:
  dEQP-VK.query_pool.occlusion_query.copy_results*dstoffset

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11758>
2021-07-07 10:41:06 +00:00
Corentin Noël d080262524 ci: Bump virglrenderer
Use the latest commit from master branch

Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Rohan Garg <rohan.garg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11572>
2021-07-07 10:04:10 +00:00
Corentin Noël 441b480a5f ci: Re-enable virgl tesselation shader
Partially undoes c8c7450fc7 ("llvmpipe: move coroutines out of noopt case")
as the required features are now implemented in llvmpipe.

Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Rohan Garg <rohan.garg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11572>
2021-07-07 10:04:10 +00:00
Alyssa Rosenzweig 1d0008734c agx: Ensure we don't overallocate registers
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11751>
2021-07-07 03:31:43 +00:00
Alyssa Rosenzweig 7e65e47d19 agx: Pipe in nir_register
This is kind of lazy...

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11751>
2021-07-07 03:31:43 +00:00
Alyssa Rosenzweig 85e18deb18 agx: Assign registers locally
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11751>
2021-07-07 03:31:43 +00:00
Alyssa Rosenzweig 15b49a6795 agx: Count read registers as well
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11751>
2021-07-07 03:31:43 +00:00
Alyssa Rosenzweig f03cecf05f agx: Don't choke on registers in the optimizer
Just skip over them.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11751>
2021-07-07 03:31:43 +00:00
Mike Blumenkrantz 997e5cf440 zink: store the default variant hash for a program
the first created pipeline with a program is the default variants, and
this is likely to be the most common, so we can store the hash to avoid
needing to recalc it later

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11740>
2021-07-07 03:21:42 +00:00
Mike Blumenkrantz 02287fe42d zink: flag shader modules as default
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11740>
2021-07-07 03:21:42 +00:00
Mike Blumenkrantz e551f2c557 zink: keep a mask of stages present in a gfx program
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11740>
2021-07-07 03:21:42 +00:00
Mike Blumenkrantz 66fc13d3d5 zink: flag all shaders for create during gfx program init
now we can avoid needing extra conditionals in the update hotpath

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11740>
2021-07-07 03:21:41 +00:00
Mike Blumenkrantz 876ead6dad zink: remove zink_shader_module refcounting
this is no longer necessary

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11740>
2021-07-07 03:21:41 +00:00
Mike Blumenkrantz 69e07603a6 features: mark off VK_EXT_multi_draw for radv
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11750>
2021-07-07 03:17:05 +00:00
Mike Blumenkrantz a793067387 zink: consolidate and optimize index buffer handling during draw
this can be reorganized to have more readable handling

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11746>
2021-07-07 03:06:00 +00:00
Mike Blumenkrantz 47ba3b799f zink: move descriptor update closer to start of draw
this can trigger flushes, so ensure that it doesn't break the cmdbuf

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11746>
2021-07-07 03:06:00 +00:00
Mike Blumenkrantz 6f4dc4b6b8 zink: update streamout buffer strides inline
loops--

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11746>
2021-07-07 03:06:00 +00:00
Mike Blumenkrantz 129b26909d zink: use last_vertex_stage pointer to optimize streamout emission during draw
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11746>
2021-07-07 03:06:00 +00:00
Mike Blumenkrantz cc438ba58a zink: store the last vertex stage to the context during bind
make this more readily accessible

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11746>
2021-07-07 03:06:00 +00:00
Timothy Arceri 80a377ad81 util/radeonsi: add radeonsi workaround for Nuclear Throne
Without radeonsi_sync_compile the game crashes at startup. The
game engine uses a custom global new operator which doesn't
play well with multithreading.

Fixes: f1cc13727c ("radeonsi: enable workarounds for YoYo engine based games")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5023

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11701>
2021-07-07 02:45:23 +00:00
Mike Blumenkrantz 50d6c58abb relnotes: EXT_extended_dynamic_state2 for lavapipe
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11736>
2021-07-07 02:13:20 +00:00
Mike Blumenkrantz a25e5c6f42 features: EXT_extended_dynamic_state2 for lavapipe
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11736>
2021-07-07 02:13:20 +00:00
Mike Blumenkrantz 6741e4be31 lavapipe: implement EXT_extended_dynamic_state2
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11736>
2021-07-07 02:13:20 +00:00
Mike Blumenkrantz e0fbaac242 lavapipe: only apply pipeline state for depth bias if it's enabled
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11736>
2021-07-07 02:13:20 +00:00