Yiwei Zhang
5df194e2ae
zink: sync queue access for vkQueueWaitIdle
...
Ensure VkQueue external sync between flush_queue and TC.
Cc: mesa-stable
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25733 >
2023-10-14 23:43:36 +00:00
Karol Herbst
d2e1bc33b0
zink: implement PIPE_COMPUTE_CAP_MAX_COMPUTE_UNITS
...
We have to return at least 1.
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25731 >
2023-10-14 22:14:34 +00:00
Rob Clark
d97427f41c
radeonsi: Add PIPE_CAP_HAS_CONST_BW support
...
Signed-off-by: Rob Clark <robdclark@chromium.org >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25464 >
2023-10-14 17:28:29 +00:00
Rob Clark
01f0cce003
iris: Add PIPE_CAP_HAS_CONST_BW support
...
Signed-off-by: Rob Clark <robdclark@chromium.org >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25464 >
2023-10-14 17:28:28 +00:00
Rob Clark
1fe201f7a3
panfrost: Add PIPE_CAP_HAS_CONST_BW support
...
Signed-off-by: Rob Clark <robdclark@chromium.org >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25464 >
2023-10-14 17:28:28 +00:00
Rob Clark
c1968e54d9
freedreno: Add PIPE_CAP_HAS_CONST_BW support
...
Allow for tiled layouts rather than having mesa/st force us back to
linear.
Signed-off-by: Rob Clark <robdclark@chromium.org >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25464 >
2023-10-14 17:28:28 +00:00
Rob Clark
5cccd6d689
mesa: Implement MESA_texture_const_bandwidth
...
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9891
Signed-off-by: Rob Clark <robdclark@chromium.org >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25464 >
2023-10-14 17:28:28 +00:00
Rob Clark
d0c81e12f3
mesa: Introduce MESA_texture_const_bandwidth
...
A simple extension that builds on EXT_memory_object to allow the
application to request that constant bandwidth (non-data-dependent)
tiling layouts be used for a specified texture.
Signed-off-by: Rob Clark <robdclark@chromium.org >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25464 >
2023-10-14 17:28:28 +00:00
Kai Wasserbäch
2320ad1da6
fix: clover: warning: ignoring return value of ‘int posix_memalign(…)’ [-Wunused-result]
...
During builds GCC 13.2 issues the following warning:
src/gallium/frontends/clover/api/memory.cpp:612:21: warning: ignoring return value of ‘int posix_memalign(void**, size_t, size_t)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
612 | posix_memalign(&ptr, alignment, size);
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~
Fix this by checking the returned value is actually 0 and if not we now
report a nullptr.
Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org >
Reviewed-by: Karol Herbst <kherbst@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25724 >
2023-10-14 17:12:37 +00:00
Karol Herbst
10e3de37bf
rusticl/memory: use get_mut instead of lock in drop
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25727 >
2023-10-14 15:32:14 +00:00
David Heidelberg
0b31cda678
ci: ci_marge_queue.py
...
Show currently assigned jobs to Marge and return 0 when it's free.
Useful for combination with ci_run_n_monitor.py .
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20347 >
2023-10-14 11:28:56 +00:00
Karol Herbst
3083b854e0
rusticl/kernel: get rid of Arcs in KernelDevStateVariant
...
We only used Arcs as we wanted to deal with either getting a reference or
having an owned temporary. But we can also just use a local variable for
temporary storage.
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Karol Herbst
d3d94818ed
rusticl/queue: make it Sync
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Karol Herbst
57bafe51d2
rusticl/queue: get rid of pointless Option around our worker thread handle
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Karol Herbst
aa1d746a8e
rusticl/cl: mark _cl_image_desc as Send and Sync
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Karol Herbst
e994935c1f
rusticl/mesa: mark PipeTransfer as Send
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Karol Herbst
5492046240
rusticl/mesa: mark PipeResource as Send and Sync
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Karol Herbst
dde84568ad
rusticl/mesa/nir: Mark NirShader and NirPrintfInfo as Send and Sync
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Karol Herbst
6189b3fe43
rusticl/mesa/nir: mark more methods as mut
...
Those actually change the nir and are not thread-safe anyway.
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Karol Herbst
02c433dd87
rusticl: bump rustc version to 1.66
...
This adds a few goodies I care about:
- bool::then_some (1.62)
- let-else statements (1.65)
FireFox ESR is at 1.66 so this bump is according to the Rust updated
policy.
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: @LingMan <18294-LingMan@users.noreply.gitlab.freedesktop.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24062 >
2023-10-14 09:34:56 +00:00
Faith Ekstrand
70806cc840
nvk: Always set pixel_min/max_Z to CLAMP
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25723 >
2023-10-14 05:23:45 +00:00
Chia-I Wu
29e2e9290b
anv: add support for vk_require_astc driconf
...
When vk_require_astc is true and there is no native ASTC LDR support,
enable ASTC LDR emulation.
vk_require_astc defaults to true on Android 14+.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
b30d5a4794
anv: advertise emulated formats
...
Advertise required features for emulated formats.
v2: no sparse residency support
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
8352b61ffa
anv: fix up blit src for emulated formats
...
When the blit src has an emulated format, redirect to the hidden plane.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
7b84c8d6ea
anv: fix up image views for emulated formats
...
When the view format is the same as the image format, and the format is
emulated, change the format to the decompressed format.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
a73e0e9a04
anv: decompress on upload for emulated formats
...
Add anv_astc_emu_decompress to decompress the raw texel data to the
hidden plane. Call anv_astc_emu_decompress from anv_CmdCopyImage2 and
anv_CmdCopyBufferToImage2.
v2: support transfer queue and add missing flushes (Lionel)
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
61e480cb54
anv: add a hidden plane for emulated formats
...
When an image is created with an emulated format, add a hidden plane to
the image. The hidden plane will be used for decompressed data.
v2: assert no sparse residency
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com > (v1)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
9ffe8b9235
anv: add anv_is_format_emulated
...
anv_is_format_emulated returns true when a format is emulated. It will
be used for ASTC LDR emulation, but it always return false at the
moment.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
94192418f8
anv: add anv_cmd_buffer_{save,restore}_state
...
They can be used to save/restore a subset of the current compute state.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
710c14f20b
anv: add anv_descriptor_set_write
...
Add anv_descriptor_set_write as a helper for both
anv_UpdateDescriptorSets and anv_CmdPushDescriptorSetKHR.
v2: rename push_set to the more generic set_override
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com > (v1)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
7a4903626b
anv: support alternative push descriptor sets
...
Do not assume anv_cmd_pipeline_state::push_descriptor is the currently
bound push descriptor set. With this and anv_push_descriptor_set_init,
it is possible to initialize a temporary push descriptor set on stack
for internal use.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
a86a4e5fcf
anv: add anv_push_descriptor_set_{init,finish}
...
Refactor anv_cmd_buffer_alloc_push_descriptor_set and add
anv_push_descriptor_set_{init,finish}. Note that
anv_push_descriptor_set_init still supports re-initialization.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
d5841dce60
anv: support image views with surface state stream
...
Add optional anv_state_stream to anv_image_view_init. This is useful
for internal image views whose lifetimes are tied to the lifetime of a
command buffer.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
815b568ed5
anv: add anv_image_view_{init,finish}
...
This is a minor refactor.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:40 +00:00
Chia-I Wu
b16e803571
anv: remove unused field from anv_image_view
...
image_plane is unused.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:39 +00:00
Chia-I Wu
567c32b55c
radv, drirc: rename radv_require_{etc2,astc}
...
Rename them to vk_require_{etc2,astc}.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25467 >
2023-10-14 02:36:39 +00:00
Lionel Landwerlin
cfdc57d120
anv: update batch chaining to Gfx9 commands
...
I don't know this fixes anything but I noticed the generated draws
jump into addresses slightly different from CPU generated jumps.
After checking the genxml, I noticed MI_BATCH_BUFFER_START "Batch
Buffer Start Address" fields have different sizes in Gfx8 & Gfx9+.
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Reviewed-by: Ivan Briano <ivan.briano@intel.com >
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25705 >
2023-10-14 01:47:42 +00:00
Karol Herbst
6c268cdf05
pipe-loader: allow to load multiple zink devices
...
Rusticl needs to be able to create a zink_screen on all renderer nodes.
This adds the infrastructure of doing so.
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
65848d445c
rusticl: enable zink
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
e0bf698d46
rusticl/mesa/screen,device: add driver_name
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Mike Blumenkrantz
25d348d040
zink: eliminate samplers from no-sampler CL texops
...
samplers aren't guaranteed to be provided by no-sampler ops in CL,
so flagging them as extant may read from a null sampler and explode
instead just pass the image through directly in the spirv
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
764851a24c
zink: fix load/store scratch offsets
...
The offset is originally in bytes, so we have to handle it just like
shared load/stores.
Fixes: ddc5c30489 ("zink: handle global and scratch vars")
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
e36c49b69a
zink: fix RA textures
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
a5ef1067be
zink: implement remaining pack ops via bitcast
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
a10828f886
zink: support samplers with unnormalized_coords
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Mike Blumenkrantz
a6e9e0f0d7
zink: add set_global_binding
...
This requires VK_KHR_buffer_device_address which is the only sane way of
implementing CL global memory.
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
bec1955446
zink: make spirv_builder_emit_*op compatible with spec constants
...
This way we can use those builder functions to emit spec constant
operations.
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
82eed326f4
zink: support more nir opcodes
...
There are sadly no SPIRV variants for hadd or iadd_sat we can use, so
lower those.
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
c5abb7c8d1
zink: variable shared mem support
...
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00
Karol Herbst
566112fdf8
zink: refactor spec constant handling
...
This makes it simpler to add more spec constants
Signed-off-by: Karol Herbst <kherbst@redhat.com >
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839 >
2023-10-14 01:01:16 +00:00