platform/upstream/mesa.git
19 months agozink: Add support for `get_screen_fd`
Lucas Fryzek [Thu, 2 Mar 2023 19:47:02 +0000 (14:47 -0500)]
zink: Add support for `get_screen_fd`

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21654>

19 months agonouveau: Add support for `get_screen_fd`
Lucas Fryzek [Thu, 2 Mar 2023 19:46:29 +0000 (14:46 -0500)]
nouveau: Add support for `get_screen_fd`

Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21654>

19 months agotegra: Add support for `get_screen_fd`
Lucas Fryzek [Thu, 2 Mar 2023 19:45:46 +0000 (14:45 -0500)]
tegra: Add support for `get_screen_fd`

Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21654>

19 months agocrocus: Add support for `get_screen_fd`
Lucas Fryzek [Thu, 2 Mar 2023 19:45:11 +0000 (14:45 -0500)]
crocus: Add support for `get_screen_fd`

Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21654>

19 months agolavapipe: advertise EXT_shader_object
Mike Blumenkrantz [Fri, 31 Mar 2023 11:22:03 +0000 (07:22 -0400)]
lavapipe: advertise EXT_shader_object

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22233>

19 months agolavapipe: implement EXT_shader_object
Mike Blumenkrantz [Tue, 7 Mar 2023 17:44:53 +0000 (12:44 -0500)]
lavapipe: implement EXT_shader_object

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22233>

19 months agolavapipe: break out pipeline layout creation for reuse
Mike Blumenkrantz [Mon, 6 Mar 2023 20:21:54 +0000 (15:21 -0500)]
lavapipe: break out pipeline layout creation for reuse

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22233>

19 months agovenus/ci: Only run one crosvm instance
Corentin Noël [Fri, 3 Mar 2023 18:38:34 +0000 (19:38 +0100)]
venus/ci: Only run one crosvm instance

As venus now has separate render server processes it is better to use a single
crosvm instance to run all the tests.

Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21693>

19 months agoci: Uprev crosvm and virglrenderer
Corentin Noël [Fri, 17 Mar 2023 09:53:48 +0000 (10:53 +0100)]
ci: Uprev crosvm and virglrenderer

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21693>

19 months agovulkan: Update XML and headers to 1.3.246
Samuel Pitoiset [Fri, 31 Mar 2023 08:33:12 +0000 (10:33 +0200)]
vulkan: Update XML and headers to 1.3.246

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22231>

19 months agozink: update requirements now that pv mode can be emulated
antonino [Thu, 30 Mar 2023 15:55:38 +0000 (17:55 +0200)]
zink: update requirements now that pv mode can be emulated

Zink can now emulate provoking vertex mode when the extention is
missing, update requirements to reflect this.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22162>

19 months agozink: always advertize provoking vertex mode support
antonino [Thu, 23 Mar 2023 12:58:04 +0000 (13:58 +0100)]
zink: always advertize provoking vertex mode support

Require VK_EXT_provoking_vertex for optimal_keys and always advertize
PIPE_CAP_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION since it can now be
emulated

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22162>

19 months agozink: add provoking vertex mode lowering
antonino [Fri, 24 Mar 2023 15:03:02 +0000 (16:03 +0100)]
zink: add provoking vertex mode lowering

Can be used as fallback for when VK_EXT_provoking_vertex is missing

Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22162>

19 months agozink: add field to 'zink_gs_key' and enum
antonino [Wed, 29 Mar 2023 09:43:33 +0000 (11:43 +0200)]
zink: add field to 'zink_gs_key' and enum

Add enum for pv emulation primitives and `lower_pv_mode`
to `zink_gs_key`

The enum contains the possible values of the lower_pv_mode key

This key will be non 0 whenever provoking vertex mode needs to be
emulated and it's exact value encodes relevant information about the
primitive that needs to be emulated

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22162>

19 months agozink: simplify logic to call `zink_set_primitive_emulation_keys`
antonino [Thu, 23 Mar 2023 12:34:45 +0000 (13:34 +0100)]
zink: simplify logic to call `zink_set_primitive_emulation_keys`

The logic had grown to check every primitive indivdually, instead just
check wehether `rast_prim` has changed

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22162>

19 months agonir: only handle flat interpolation when needed in `nir_create_passthrough_gs`
antonino [Thu, 30 Mar 2023 15:45:15 +0000 (17:45 +0200)]
nir: only handle flat interpolation when needed in `nir_create_passthrough_gs`

When turning primitives into line strips this function needs to move
attributes around, but this is not needed in other cases.

Fixes: 1a5bdca2dda ("zink: implement flat shading using inlined uniforms")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22162>

19 months agopanfrost: Check the return value of drmGetVersion
xurui [Thu, 30 Mar 2023 03:25:05 +0000 (11:25 +0800)]
panfrost: Check the return value of drmGetVersion

Signed-off-by: xurui <xurui@kylinos.cn>
Reviewed-by: David Heidelberg <david.heidelberg@collabora.com>
Reviewed-by: Italo Nicola <italonicola@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22203>

19 months agodocs: make code-block indents consistent
Erik Faye-Lund [Tue, 15 Nov 2022 10:56:28 +0000 (11:56 +0100)]
docs: make code-block indents consistent

Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22052>

19 months agodocs: format code-block as toml
Erik Faye-Lund [Tue, 15 Nov 2022 10:54:30 +0000 (11:54 +0100)]
docs: format code-block as toml

Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22052>

19 months agodocs: format code-block as ini
Erik Faye-Lund [Tue, 15 Nov 2022 10:52:49 +0000 (11:52 +0100)]
docs: format code-block as ini

Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22052>

19 months agoradv: Work around use-after-free compiler errors
Friedrich Vock [Fri, 17 Mar 2023 07:22:42 +0000 (08:22 +0100)]
radv: Work around use-after-free compiler errors

Fixes: 4dafb69d ("radv/rt: defer library_pipeline allocation")
Tested-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21981>

19 months agoradv: add dynamic support for rectangles enable/mode
Samuel Pitoiset [Wed, 25 Jan 2023 15:22:16 +0000 (16:22 +0100)]
radv: add dynamic support for rectangles enable/mode

This is in VK_EXT_discard_rectangles version 2.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21360>

19 months agovulkan: add dynamic support for rectangles enable/mode
Samuel Pitoiset [Wed, 25 Jan 2023 15:35:14 +0000 (16:35 +0100)]
vulkan: add dynamic support for rectangles enable/mode

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21360>

19 months agoradv: fix sample shading when a new fragment shader is bound
Samuel Pitoiset [Thu, 30 Mar 2023 15:26:34 +0000 (17:26 +0200)]
radv: fix sample shading when a new fragment shader is bound

Sample shading can be enabled from the pipeline and from the fragment
shader, in that case we need to re-emit some states.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22215>

19 months agointel/decoder: Bump the binding table guess value to 32
Sagar Ghuge [Thu, 30 Mar 2023 17:18:21 +0000 (10:18 -0700)]
intel/decoder: Bump the binding table guess value to 32

Let's bump the binding table value guess to 32 instead of 8 and also stop
decoding the binding table entries as soon as we hit the zero
initialized value in the map.

Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22221>

19 months agodocs: Remove docs about macOS hardware drivers
Alyssa Rosenzweig [Thu, 30 Mar 2023 15:37:43 +0000 (11:37 -0400)]
docs: Remove docs about macOS hardware drivers

We dropped support for hardware macOS drivers in afe134a49c5 ("asahi: Drop macOS
backend"), so drop the corresponding documentation. Layered and software drivers
are still supported on macOS for better or worse, so the main "Notes on macOS"
page can stay I think.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22213>

19 months agomicrosoft/clc: Add shader model / validator to compiler API
Jesse Natalie [Tue, 7 Feb 2023 22:14:37 +0000 (14:14 -0800)]
microsoft/clc: Add shader model / validator to compiler API

Shader model 6.2 was the upper bounds of what *could* be generated
before, but not all devices support it. And other devices support
even more. So, let's pass in the shader model / validator that will
be used by the API caller.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21178>

19 months agopanfrost: Choose hierarchy masks by vertex count
Alyssa Rosenzweig [Thu, 16 Mar 2023 01:36:18 +0000 (21:36 -0400)]
panfrost: Choose hierarchy masks by vertex count

Currently, we always use a hierarchy mask with all levels enabled. While this is
efficient for geometry-heavy workloads like 3D games, it is wasteful for 2D
applications that draw very few vertices. For drawing just a few textured quads,
the overhead of small bin sizes outweighs any performance advantages, so it's a
bit slower. More problematically, small bin sizes require tremendous amounts of
memory for the polygon lists, leading to significant memory consumption (~10MB)
for the polygon list for even the simplest of 2D blits.

To reduce our memory footprint, we need to choose our hierarchy masks more
carefully. In general, we want to allow small bin sizes for geometry-heavy
workloads but not for geometry-light workloads. We estimate vertex count in the
driver as a proxy for this, and use a simple heuristic to select a bin size
based on the estimated vertex count. None of this is an exact science, and the
heuristic could probably be tuned. Nevertheless, the heuristic used (comparing
framebuffer size to vertex count) works well in practice, significantly reducing
the memory footprint of 2D applications like Firefox without hurting the
performance of 3D applications.

I originally wrote this patch while diagnosing high memory footprints on my
Midgard laptop, which is why only Midgard is in scope here. On Bifrost and
Valhall, we have a similar hiearchy mask selection problem. It seems likely that
the same heuristic would work there too, but it's a different code path that I
have not integrated or tested. I'll leave that for the adventurous reader, to
get the memory footprint win there too.

(It's also possible the win is smaller on newer Malis than on Midgard, since Arm
claims they optimized the tiler data structures on the newer parts. There's
probably still some merit to the idea.)

On Mali-T860, glmark2 -bdesktop frametime decreased by 1.35% +/- 0.91% at 95%
confidence, showing a slight win for 2D workloads No statistically significant
difference for glmark2 -bshading:shading=phong, since 3D workloads continue to
use the same hierarchy masks.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19482>

19 months agopanfrost: Estimate vertex count for hier mask
Alyssa Rosenzweig [Thu, 16 Mar 2023 01:35:29 +0000 (21:35 -0400)]
panfrost: Estimate vertex count for hier mask

In the next commit, we will refine our algorithm to select hierarchy masks based
on the vertex count. In preparation, augment the driver to track rough estimates
of the vertex count so we have a "geometry complexity" input for the heuristic.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19482>

19 months agopanfrost: Clean up tiler calculations
Alyssa Rosenzweig [Mon, 31 Oct 2022 03:33:48 +0000 (23:33 -0400)]
panfrost: Clean up tiler calculations

We're about to do some work on this file. Clean it up first.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19482>

19 months agofreedreno/computerator: Add support for a7xx
Danylo Piliaiev [Fri, 3 Mar 2023 18:32:36 +0000 (19:32 +0100)]
freedreno/computerator: Add support for a7xx

Not everything works correctly, e.g. stib seems flakey while stg
seems alright.

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agofreedreno/computerator: Templatize a6xx backend
Danylo Piliaiev [Fri, 3 Mar 2023 13:11:40 +0000 (14:11 +0100)]
freedreno/computerator: Templatize a6xx backend

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agofreedreno: Add dummy a730/a740 definition
Danylo Piliaiev [Tue, 21 Feb 2023 14:49:57 +0000 (15:49 +0100)]
freedreno: Add dummy a730/a740 definition

Needed for assembly/disassembly.

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agofreedreno: Move fd6_pack.h to common code accessible by computerator
Danylo Piliaiev [Thu, 16 Feb 2023 18:24:16 +0000 (19:24 +0100)]
freedreno: Move fd6_pack.h to common code accessible by computerator

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agofreedreno/computerator: Convert to C++
Danylo Piliaiev [Fri, 3 Mar 2023 12:39:19 +0000 (13:39 +0100)]
freedreno/computerator: Convert to C++

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agofreedreno: C++ fixes for computerator to compile
Danylo Piliaiev [Mon, 27 Mar 2023 16:48:47 +0000 (18:48 +0200)]
freedreno: C++ fixes for computerator to compile

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agofreedreno/computerator: C++ proofing
Danylo Piliaiev [Fri, 3 Mar 2023 12:32:09 +0000 (13:32 +0100)]
freedreno/computerator: C++ proofing

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agofreedreno/registers: More a7xx regs
Danylo Piliaiev [Thu, 16 Feb 2023 18:24:16 +0000 (19:24 +0100)]
freedreno/registers: More a7xx regs

Based on 011c54b0 from Jonathan Marek.

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agofreedreno/registers: Document new CP_EVENT_WRITE::SEQNO
Danylo Piliaiev [Fri, 3 Mar 2023 18:32:08 +0000 (19:32 +0100)]
freedreno/registers: Document new CP_EVENT_WRITE::SEQNO

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22148>

19 months agopanfrost: Add a v9 fast path for no images
Alyssa Rosenzweig [Sun, 15 Jan 2023 01:10:12 +0000 (20:10 -0500)]
panfrost: Add a v9 fast path for no images

The usual case.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21848>

19 months agopanfrost: Don't update access with a single batch
Alyssa Rosenzweig [Sat, 14 Jan 2023 23:24:32 +0000 (18:24 -0500)]
panfrost: Don't update access with a single batch

drawoverhead test 25 from 462->492

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21848>

19 months agopanfrost: Mark packs as ALWAYS_INLINE
Alyssa Rosenzweig [Sat, 14 Jan 2023 03:53:20 +0000 (22:53 -0500)]
panfrost: Mark packs as ALWAYS_INLINE

As Intel does. These functions are written with the expectation that they will
be inlined away, allowing gcc's copy-prop and constant folding to eliminate the
template struct and any unused fields.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21848>

19 months agopanfrost: Don't redundantly call emit_const_buf
Alyssa Rosenzweig [Sat, 14 Jan 2023 03:39:03 +0000 (22:39 -0500)]
panfrost: Don't redundantly call emit_const_buf

On Valhall, we were calling emit_const_buf in two places:

1. The main "handle dirty flags" code shared with Bifrost
2. A Valhall-specific shader environment emitter

The latter was not dirty tracked, and the former was not used. That meant we
were calling emit_const_buf way too much. It's not a cheap routine, either.

Instead, use the results from the dirty tracked function in the shader
environment emitter, to avoid the redundant call and get the expected dirty
tracking.

In a Dolphin trace I'm looking at, fps increases 27->33.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21848>

19 months agopanfrost: Print perf debug on seqnum overflow
Alyssa Rosenzweig [Sat, 29 Oct 2022 22:16:22 +0000 (18:16 -0400)]
panfrost: Print perf debug on seqnum overflow

Another unexpected source of flushes.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21830>

19 months agopanfrost: Print perf debug when flushing everything
Alyssa Rosenzweig [Sat, 29 Oct 2022 22:13:16 +0000 (18:13 -0400)]
panfrost: Print perf debug when flushing everything

..Even if the only batch is the one that's currently bound.

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21830>

19 months agozink: stop caching vertex states
Mike Blumenkrantz [Fri, 24 Mar 2023 21:17:06 +0000 (17:17 -0400)]
zink: stop caching vertex states

I tried to be too clever and ended up wasting cpu cycles. it's
much, much, much, much faster to just generate this one struct array
every time than it is to do set lookups with thousands of members

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agozink: use fast popcnt for vstate draws
Mike Blumenkrantz [Fri, 24 Mar 2023 21:01:11 +0000 (17:01 -0400)]
zink: use fast popcnt for vstate draws

also delete some unused stubs for no dynamic vertex input since I'm never
gonna implement that path

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agozink: don't swizzle velems state for vstate draws
Mike Blumenkrantz [Fri, 24 Mar 2023 20:59:54 +0000 (16:59 -0400)]
zink: don't swizzle velems state for vstate draws

this isn't ever used, so don't touch it

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agozink: explicitly pass null velems when creating pipelines with dynamic vinput
Mike Blumenkrantz [Fri, 24 Mar 2023 20:58:11 +0000 (16:58 -0400)]
zink: explicitly pass null velems when creating pipelines with dynamic vinput

this may or may not be a usable pointer, and it's not being read, so
don't pass it at all

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agozink: add another vstate draw template for popcnt presence
Mike Blumenkrantz [Fri, 24 Mar 2023 20:41:47 +0000 (16:41 -0400)]
zink: add another vstate draw template for popcnt presence

matching radeonsi

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agozink: bind vertex state directly from draw hook
Mike Blumenkrantz [Fri, 24 Mar 2023 20:36:04 +0000 (16:36 -0400)]
zink: bind vertex state directly from draw hook

this is more streamlined and readable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agozink: use search_or_add for masking vstate
Mike Blumenkrantz [Fri, 24 Mar 2023 20:13:34 +0000 (16:13 -0400)]
zink: use search_or_add for masking vstate

this should be a significant perf boost instead of multiple lookups

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agozink: flag vertex buffers for rebind after vstate draws
Mike Blumenkrantz [Fri, 24 Mar 2023 20:11:44 +0000 (16:11 -0400)]
zink: flag vertex buffers for rebind after vstate draws

vstate draws bind their own vertex buffers unrelated to the bound
gallium buffers, so any draw occurring after a vstate draw must
rebind vertex buffers to ensure the correct ones are bound

cc: mesa-stable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agozink: omit VkPipelineVertexInputStateCreateInfo with dynamic vinput
Mike Blumenkrantz [Sat, 25 Mar 2023 12:06:30 +0000 (08:06 -0400)]
zink: omit VkPipelineVertexInputStateCreateInfo with dynamic vinput

this should never be used/needed

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22116>

19 months agoradv: Stop counting user SGPRS separately
Konstantin Seurer [Sun, 26 Mar 2023 20:06:31 +0000 (22:06 +0200)]
radv: Stop counting user SGPRS separately

Renames radv_declare_shader_args to declare_shader_args and runs it
twice to first gather the user SGPR count without push constants and
descriptor sets.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22119>

19 months agoradv: Set user SGPR locations when declaring args
Konstantin Seurer [Sat, 25 Mar 2023 18:26:45 +0000 (19:26 +0100)]
radv: Set user SGPR locations when declaring args

Merge shader arg declaration with setting up the user data locations.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22119>

19 months agobin: Fix typos
Harri Nieminen [Wed, 29 Mar 2023 14:19:04 +0000 (17:19 +0300)]
bin: Fix typos

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22189>

19 months agozink: block resolves where src extents > dst extents
Mike Blumenkrantz [Wed, 29 Mar 2023 20:42:02 +0000 (16:42 -0400)]
zink: block resolves where src extents > dst extents

vulkan resolves only provide "extents" instead of src and dst regions like
GL, which means vk resolves can't be used to downscale images, as such
operations will instead just crop the image

fixes #8655

cc: mesa-stable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22195>

19 months agoradv: add push constant state to the cmdbuf state
Samuel Pitoiset [Tue, 28 Mar 2023 12:11:01 +0000 (14:11 +0200)]
radv: add push constant state to the cmdbuf state

Push constants are handled per bind point internally. Using a separate
structure in the cmdbuf state would allow us to update it easily
without relying on bound pipelines.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22209>

19 months agoradv: copy need_indirect_descriptor_sets to radv_cmd_state
Samuel Pitoiset [Wed, 22 Mar 2023 16:50:21 +0000 (17:50 +0100)]
radv: copy need_indirect_descriptor_sets to radv_cmd_state

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22209>

19 months agoradv: add a helper to convert a VkPipelineBindPoint
Samuel Pitoiset [Thu, 30 Mar 2023 13:14:52 +0000 (15:14 +0200)]
radv: add a helper to convert a VkPipelineBindPoint

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22209>

19 months agofreedreno: Optimize repeated finishes
Rob Clark [Fri, 24 Mar 2023 21:07:39 +0000 (14:07 -0700)]
freedreno: Optimize repeated finishes

Sometimes apps (glances at stk) spin on a syncobj with very short
timeouts.  But ensuring the fence is flushed all the way through to
the kernel (including handling TC unflushed fences) only needs to
be done once.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22098>

19 months agofreedreno/drm: Disable threaded-submit for msm
Rob Clark [Sat, 25 Mar 2023 13:41:13 +0000 (06:41 -0700)]
freedreno/drm: Disable threaded-submit for msm

We've had drm/sched support on the kernel side for more than a year and
a half.  This makes submit ioctl async by handling fence waits from the
sched's kthread, which is what threaded submit was originally working
around.  For now, threaded submit is only used for virtgpu, which does
not (yet?) have drm/sched support.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22098>

19 months agofreedreno/drm: Make threaded-submit optional
Rob Clark [Fri, 24 Mar 2023 20:35:33 +0000 (13:35 -0700)]
freedreno/drm: Make threaded-submit optional

We've had gpu-sched support in the kernel for a while now, so our fence
waits are not synchronous in the ioctl path.  The only reason this path
still exists is that virtgpu does not have gpu-sched.  So lets disable
it on msm.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22098>

19 months agomesa: Add a few more function traces
Rob Clark [Fri, 24 Mar 2023 17:45:37 +0000 (10:45 -0700)]
mesa: Add a few more function traces

Sprinkle around a few more traces that were useful in locating fence
waits.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22098>

19 months agofreedreno/drm: Stop cleanup at first active BO
Rob Clark [Thu, 23 Mar 2023 20:38:43 +0000 (13:38 -0700)]
freedreno/drm: Stop cleanup at first active BO

Buffers are added to the deferred freelist at the tail.  And frequently
the last reference is dropped immediately after the submit.  So almost
always, once we see a still-busy BO, the remaining in the list will also
still be busy.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22098>

19 months agofreedreno/drm: Fast path for idle check
Rob Clark [Thu, 23 Mar 2023 20:37:35 +0000 (13:37 -0700)]
freedreno/drm: Fast path for idle check

If already idle, no need to cleanup_fences() (and take related lock).

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22098>

19 months agozink: fix quads emulation gs with array variables
Mike Blumenkrantz [Thu, 30 Mar 2023 12:50:48 +0000 (08:50 -0400)]
zink: fix quads emulation gs with array variables

this was broken for e.g., gl_ClipDistance, which uses explicit array
types and therefore cannot be directly read/written

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22208>

19 months agodri2/android: Bypass throttling
Rob Clark [Wed, 29 Mar 2023 21:57:23 +0000 (14:57 -0700)]
dri2/android: Bypass throttling

The android window system (SurfaceFlinger, et al) already does it's own
throttling.  Trying to do this also in mesa's egl is counterproductive.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22197>

19 months agoradv/rq: Rematerialize inv_dir before proceed
Konstantin Seurer [Mon, 2 Jan 2023 14:58:22 +0000 (15:58 +0100)]
radv/rq: Rematerialize inv_dir before proceed

Helps with register pressure.

Quake II RTX:
Totals from 7 (14.29% of 49) affected shaders:

VGPRs: 688 -> 672 (-2.33%)
CodeSize: 167496 -> 167560 (+0.04%); split: -0.01%, +0.05%
MaxWaves: 70 -> 72 (+2.86%)
Instrs: 31716 -> 31760 (+0.14%); split: -0.02%, +0.16%
Latency: 385343 -> 386040 (+0.18%); split: -0.01%, +0.19%
InvThroughput: 78878 -> 78045 (-1.06%); split: -1.22%, +0.17%
VClause: 596 -> 600 (+0.67%)
Copies: 4774 -> 4747 (-0.57%); split: -0.98%, +0.42%
PreVGPRs: 617 -> 592 (-4.05%)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20469>

19 months agozink: set src access when rebinding buffers, unset unordered_*
Mike Blumenkrantz [Wed, 29 Mar 2023 19:54:33 +0000 (15:54 -0400)]
zink: set src access when rebinding buffers, unset unordered_*

this ensures that the buffer is marked active and prevents promotion
in cases where reordering would break rendering

unordered_read prohibits write reordering for buffers, so setting
this flag must be done when the buffer is actually used, ideally as
late as possible

setting it at the time of (re)bind catches all the buffer rebind cases
which might otherwise erroneously permit reordering

fixes #8381

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22205>

19 months agotu/drm: Support cached non-coherent memory
Danylo Piliaiev [Wed, 11 Jan 2023 12:53:34 +0000 (13:53 +0100)]
tu/drm: Support cached non-coherent memory

Requires some hand rolled assembly:
- DC CVAC / DC CIVAC for aarch64
- DCCMVAC / DCCIMVAC for arm32, unfortunately it seems that it is
  illegal to call them from userspace.
- clflush for x86-64

We handle x86-64 case because Turnip may run in x86-64 guest
e.g. in FEX-Emu or Box64.

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20550>

19 months agoturnip: add cached and cached-coherent memory types
Danylo Piliaiev [Fri, 6 Jan 2023 17:59:36 +0000 (18:59 +0100)]
turnip: add cached and cached-coherent memory types

vkd3d requires cached memory type.

MSM backend doesn't have a special ioctl for memory
flushing/invalidation, we'd have to use cvac and civac
arm assembly instructions (would be done in following commit).

KGSL has an the ioctl for this, which is used in this commit.

Note, CTS tests doesn't seem good at testing flushing and
invalidating, the ones I found passed on KGSL with both
functions being no-op.

Based on the old patch from Jonathan Marek.

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

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20550>

19 months agozink: enable spir-v 1.6 for vulkan 1.3
Erik Faye-Lund [Fri, 26 Aug 2022 13:00:23 +0000 (15:00 +0200)]
zink: enable spir-v 1.6 for vulkan 1.3

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18274>

19 months agozink: use spir-v 1.6 local-size when needed
Erik Faye-Lund [Fri, 26 Aug 2022 12:57:38 +0000 (14:57 +0200)]
zink: use spir-v 1.6 local-size when needed

The WorkgroupSize built-in is deprecated in SPIR-V 1.6, so let's switch
to using LocalSizeId instead, like the spec recommends.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18274>

19 months agozink: use demote from spir-v 1.6 when possible
Erik Faye-Lund [Fri, 26 Aug 2022 12:39:03 +0000 (14:39 +0200)]
zink: use demote from spir-v 1.6 when possible

With SPIR-V 1.6, we don't need to enable the extension for demote any
more.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18274>

19 months agozink: emit terminate for spir-v 1.6
Erik Faye-Lund [Fri, 26 Aug 2022 12:28:29 +0000 (14:28 +0200)]
zink: emit terminate for spir-v 1.6

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18274>

19 months agozink: add spirv builder function for terminate
Mike Blumenkrantz [Wed, 17 Aug 2022 22:05:21 +0000 (18:05 -0400)]
zink: add spirv builder function for terminate

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18274>

19 months agollvmpipe: fix handling of unused color attachments
Mike Blumenkrantz [Thu, 23 Mar 2023 16:48:53 +0000 (12:48 -0400)]
llvmpipe: fix handling of unused color attachments

if an attachment doesn't have blending or color output from the shader,
nothing should touch the attachment

this is consistent with vulkan spec and needed for upcoming cts coverage

cc: mesa-stable

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22135>

19 months agollvmpipe: fix linear fs analysis with nonzero fs outputs
Mike Blumenkrantz [Thu, 23 Mar 2023 16:10:37 +0000 (12:10 -0400)]
llvmpipe: fix linear fs analysis with nonzero fs outputs

linear fs only works with output 0

cc: mesa-stable

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22135>

19 months agoradv: copy ia_multi_vgt_param to the cmdbuf state
Samuel Pitoiset [Wed, 29 Mar 2023 16:50:27 +0000 (18:50 +0200)]
radv: copy ia_multi_vgt_param to the cmdbuf state

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22194>

19 months agoradv: copy uses_{drawid,baseinstance} to the cmdbuf state
Samuel Pitoiset [Wed, 22 Mar 2023 16:14:35 +0000 (17:14 +0100)]
radv: copy uses_{drawid,baseinstance} to the cmdbuf state

As well as the vertex user sgpr info. This also needs to be copied
for merged shaders (ie. VS+TCS).

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22194>

19 months agoradv: copy rast_prim to the cmdbuf state
Samuel Pitoiset [Wed, 22 Mar 2023 16:26:06 +0000 (17:26 +0100)]
radv: copy rast_prim to the cmdbuf state

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22194>

19 months agoradv: add a helper that returns the current rasterized primitive
Samuel Pitoiset [Thu, 30 Mar 2023 09:43:47 +0000 (11:43 +0200)]
radv: add a helper that returns the current rasterized primitive

For tess/geom/mesh the rasterized primitive is part of the shader
info and primitive topology should be ignored.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22194>

19 months agoradv: copy custom blend mode to the cmdbuf state
Samuel Pitoiset [Wed, 22 Mar 2023 15:11:46 +0000 (16:11 +0100)]
radv: copy custom blend mode to the cmdbuf state

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22194>

19 months agoradv: rework emitting inner coverage when a fragment shader is bound
Samuel Pitoiset [Mon, 27 Mar 2023 13:42:31 +0000 (15:42 +0200)]
radv: rework emitting inner coverage when a fragment shader is bound

To stop relying on the pipeline. The state is now flagged when a new
fragment shader with a different inner coverage setting is bound.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22194>

19 months agoradv: remove radv_graphics_pipeline::vb_desc_alloc_size
Samuel Pitoiset [Wed, 29 Mar 2023 14:27:02 +0000 (16:27 +0200)]
radv: remove radv_graphics_pipeline::vb_desc_alloc_size

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22192>

19 months agoradv: remove radv_graphics_pipeline::vb_desc_usage_mask
Samuel Pitoiset [Wed, 29 Mar 2023 14:21:52 +0000 (16:21 +0200)]
radv: remove radv_graphics_pipeline::vb_desc_usage_mask

Use the VS shader info instead.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22192>

19 months agoradv: adjust vb_desc_usage_mask for dynamic VS inputs in the info pass
Samuel Pitoiset [Wed, 29 Mar 2023 14:33:51 +0000 (16:33 +0200)]
radv: adjust vb_desc_usage_mask for dynamic VS inputs in the info pass

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22192>

19 months agoaco: remove unused aco_shader_info::vb_desc_usage_mask
Samuel Pitoiset [Wed, 29 Mar 2023 14:16:01 +0000 (16:16 +0200)]
aco: remove unused aco_shader_info::vb_desc_usage_mask

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22192>

19 months agoradv: remove radv_graphics_pipeline::can_use_simple_input
Samuel Pitoiset [Wed, 29 Mar 2023 14:12:09 +0000 (16:12 +0200)]
radv: remove radv_graphics_pipeline::can_use_simple_input

Use the VS shader info instead.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22192>

19 months agoradv: remove radv_graphics_pipeline::next_vertex_stage
Samuel Pitoiset [Wed, 29 Mar 2023 14:05:32 +0000 (16:05 +0200)]
radv: remove radv_graphics_pipeline::next_vertex_stage

Use the active stages bitfield instead.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22192>

19 months agoradv: remove radv_graphics_pipeline::last_vertex_attrib_bit
Samuel Pitoiset [Wed, 29 Mar 2023 13:53:06 +0000 (15:53 +0200)]
radv: remove radv_graphics_pipeline::last_vertex_attrib_bit

Use the VS shader info instead.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22192>

19 months agoradv: remove radv_graphics_pipeline::use_per_attribute_vb_descs
Samuel Pitoiset [Wed, 29 Mar 2023 13:49:47 +0000 (15:49 +0200)]
radv: remove radv_graphics_pipeline::use_per_attribute_vb_descs

Use the VS shader info instead.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22192>

19 months agointel: fix memory leak related to brw_nir_create_passthrough_tcs()
Patrick Lerda [Mon, 27 Mar 2023 09:45:12 +0000 (11:45 +0200)]
intel: fix memory leak related to brw_nir_create_passthrough_tcs()

Indeed, the parameter "mem_ctx" was not processed.

For instance, this issue is triggered with the crocus driver and
"piglit/bin/shader_runner tests/spec/arb_tessellation_shader/execution/compatibility/tes-clip-vertex-different-from-position.shader_test -auto -fbo":
SUMMARY: AddressSanitizer: 235216 byte(s) leaked in 48 allocation(s).

Fixes: 96ba0344db8f ("intel: Use common helpers for TCS passthrough shaders")
Signed-off-by: Patrick Lerda <patrick9876@free.fr>
Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22173>

19 months agoradeonsi: don't use alignment_log2 of imported buffers
Pierre-Eric Pelloux-Prayer [Tue, 28 Mar 2023 16:31:05 +0000 (18:31 +0200)]
radeonsi: don't use alignment_log2 of imported buffers

This value isn't passed to the importer by the kernel
so we can't check it.

Fixes: f7a4051b836 ("radeonsi: Check pitch and offset for validity.")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8431
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22170>

19 months agodocs: use version-number as toctree-title for relnotes
Erik Faye-Lund [Thu, 16 Mar 2023 13:11:13 +0000 (14:11 +0100)]
docs: use version-number as toctree-title for relnotes

Using the full titles makes most of these take up two lines in the
toctree. The version number is really the only thing we should care
about, though.

Reviewed-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21956>

19 months agodocs: move old relnotes to _extra directory
Erik Faye-Lund [Fri, 17 Mar 2023 12:58:44 +0000 (13:58 +0100)]
docs: move old relnotes to _extra directory

These aren't built, so they won't get copied out into the public folder
unless we put is inside the _extra folder.

This has been broken all since the conversion to Sphinx, whoops!

Reviewed-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21956>

19 months agovenus: Enable VK_EXT_memory_budget
Lina Versace [Thu, 23 Mar 2023 20:57:08 +0000 (13:57 -0700)]
venus: Enable VK_EXT_memory_budget

Tested dEQP-VK.info.device_memory_budget on Intel with vtest.  When the
test is ran at approximately the same time on the native driver and on
vtest, the qpa result files each report approximately the same memory
budget.

Signed-off-by: Lina Versace <linyaa@google.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Ryan Neph <ryanneph@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22099>

19 months agovenus: Refactor vn_physical_device_init_memory_properties
Lina Versace [Thu, 23 Mar 2023 20:57:08 +0000 (13:57 -0700)]
venus: Refactor vn_physical_device_init_memory_properties

Improve readability.

Signed-off-by: Lina Versace <linyaa@google.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Reviewed-by: Ryan Neph <ryanneph@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22099>