Brian Paul
c9c5fc1e9a
gallivm: rename 'var' param in emit_store_reg(), emit_store_var().
...
Rename 'dst' param' to 'vals'. This parameter contains the values
which we're storing.
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:56 +00:00
Brian Paul
68616b1629
gallivm: fix incorrect memset() in SOA emit_load_const()
...
The memset() call to zero-out the unused elements of outval[] used
the wrong bytecount. Just replace it with a simpler for loop.
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:56 +00:00
Brian Paul
9984ec67f2
gallivm: simplify shuffling in emit_store_reg()
...
The writemask can be implemented with just one llvm vector shuffle.
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:56 +00:00
Brian Paul
ef7da4b292
gallivm: asst. clean-ups in lp_bld_swizzle.c
...
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:56 +00:00
Brian Paul
4a30155c72
llvmpipe: replace 'unsigned' with enum types
...
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:56 +00:00
Brian Paul
9bb062bade
llvmpipe: remove unneeded casts
...
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:56 +00:00
Brian Paul
1f96c24465
llvmpipe: asst. clean-ups in lp_state_setup.c
...
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:56 +00:00
Brian Paul
fc2f57ed76
llvmpipe: minor optimization in lp_linear_init_interp()
...
Skip multiplying by 1/w when it's 1.0.
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:55 +00:00
Brian Paul
ae9ec54f68
llvmpipe: asst. clean-ups in lp_linear_interp.c
...
Comments, move var decls, fix code formatting.
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:55 +00:00
Brian Paul
49966374c8
gallivm: asst. clean-ups in lp_bld_const.c
...
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:55 +00:00
Brian Paul
0e9cf32059
llvmpipe: asst. clean-ups in lp_setup_rect.c
...
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:55 +00:00
Brian Paul
55ca12fdd0
llvmpipe: minor white-space clean-up in lp_setup.h
...
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:55 +00:00
Brian Paul
aba7554f39
llvmpipe: asst. clean-up in lp_bld_depth.c
...
Signed-off-by: Brian Paul <brianp@vmware.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17561 >
2022-07-27 22:24:55 +00:00
David Heidelberg
3b595bf50f
mailmap: fix order of emails for Axel Davy
...
Reviewed-by: Axel Davy <davyaxel0@gmail.com >
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17698 >
2022-07-27 21:36:23 +00:00
David Heidelberg
57841823a1
nine: char can be unsigned on non-x86 platforms
...
Keep sign by using int8_t to get the same result on non-x86 machines.
Reviewed-by: Axel Davy <davyaxel0@gmail.com >
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17698 >
2022-07-27 21:36:23 +00:00
Icecream95
e041a0d1e6
nine: Only enable thread_submit by default on x86
...
Possibly the bug breaking this is in box86, but given that there
aren't a whole lot of other reasons to be using Nine with a non-x86
Mesa, disable the feature unless we are running on x86.
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17698 >
2022-07-27 21:36:23 +00:00
Icecream95
57dea11e7c
nine: Make vdecl_index_map always signed
...
vdecl_index_map needs to be able to store negative values, but char is
not signed on all platforms, so change it to int8_t.
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17698 >
2022-07-27 21:36:23 +00:00
Dave Airlie
5aafe29aee
zink/llvmpipe/ci: skip broken CTS ballot test.
...
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17588 >
2022-07-27 20:58:56 +00:00
Dave Airlie
9bbc3c4e85
zink: fixup subgroup vote/ballot enables.
...
These are part of vulkan 1.1, but the ext are if you don't have 1.1.
This will enable some tests that break in CI
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17588 >
2022-07-27 20:58:56 +00:00
Dave Airlie
8be15cc382
lavapipe: expose some subgroup extensions
...
These are part of vulkan 1.2, but expose them to be nice.
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17588 >
2022-07-27 20:58:56 +00:00
Dave Airlie
41e87c5c9a
llvmpipe: export ARB_shader_ballot
...
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17588 >
2022-07-27 20:58:56 +00:00
Dave Airlie
a2cd47acdb
gallivm: fix casting around read invocation.
...
Fixes zink KHR-GL46.shader_ballot_tests.ShaderBallotAvailability
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17588 >
2022-07-27 20:58:55 +00:00
Dave Airlie
ce65e0428a
gallivm: use progress from subgroup lowering.
...
This makes sure the pack lowering gets called again.
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17588 >
2022-07-27 20:58:55 +00:00
Connor Abbott
9b844d7c42
tu: Add debug option to use emulated renderpass support
...
This should be useful for stress-testing dynamic rendering.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
b90d628a7d
tu: Use common vk_image_view base struct
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
89263fde20
tu: Use common vk_image struct
...
This eliminates some boilerplate, and will be necessary to use the
common render pass implementation for debugging purposes.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
cb0f414b2a
tu: Add support for suspending and resuming renderpasses
...
This is unfortunately very complicated because we have to stitch
together the state of the suspended passes after the fact, with primary
command buffers at submit time.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
0a4c86fc44
util/trace: Fix u_trace_*_iterator with no tracepoints
...
If u_trace is empty then there are no chunks, and we didn't account for
that case.
This fixes tracing some dynamic rendering tests.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
3aa20a4409
tu: Split out some state into a separate struct
...
These bits of state will have to be treated specially when
suspending/resuming a render pass, because they will need to be tracked
across command buffers.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
9689433eee
tu: Update more state with secondaries
...
Some of these are actually bugfixes, some like the drawcall information
are just for autotune so they are just performance fixes. However this
came from an audit into what state is used in CmdEndRenderPass().
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
79c7c6e492
tu: Remove has_subpass_predication
...
The workaround this was used for was removed.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
ed125e6cca
tu: Initial support for dynamic rendering
...
Support for suspend/resume will be added later. This just sets up
the internal render pass, and adds support to pipeline creation and
secondary inheritance.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
22be08a21e
tu: Remove usage of RenderPassBeginInfo
...
More preparation for using this with dynamic rendering.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
cf391db4c6
tu: Move tu_render_pass definition up
...
So that we can embed one in tu_cmd_buffer.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
2b8b5259c7
tu: Disable GMEM for multiview inside tu_render_pass_gmem_config
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
c42e7aa46c
tu: Move TU_DONT_CARE_AS_LOAD into attachment_set_ops()
...
So that we can share it with dynamic rendering.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
907b892bb2
tu: Rewrite tess factor emission
...
Emit it at EndRenderPass time, if the renderpass has tessellation. This
avoids all the special handling for secondaries, will work with
suspended/resumed render passes, and will handle secondaries that
contain render passes which will be allowed with dynamic rendering.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
c5be444500
tu: Treat CP_WAIT_FOR_ME as a cache invalidate
...
The workaround for draws that need a CP_WAIT_FOR_ME didn't work if the
barrier before the draw is in a separate command buffer from the draw.
The barrier would add a pending CP_WAIT_FOR_ME, but it would get dropped
on the floor at the end of the command buffer and the draw wouldn't have
a pending CP_WAIT_FOR_ME so it wouldn't emit one. We don't know in the
barrier if the destination is a draw with the workaround, so we have two
options:
- Emit any pending CP_WAIT_FOR_ME at the end of the command buffer (and
before secondaries) in case there is a workaround draw later. This
will emit an extra CP_WAIT_FOR_ME at the end of the command buffer in
case there is an indirect command barrier.
- Always assume at the beginning of the command buffer that there is a
pending CP_WAIT_FOR_ME. This will emit an extra CP_WAIT_FOR_ME before
the first workaround-requiring draw in the command buffer, in case
there was a barrier earlier.
The only draws requiring a workaround are currently
vkCmdDraw*IndirectCount(), which we assume are rarer than indirect
command barriers, so we implement the second option. This entails
treating it as a cache invalidate.
This fixes some upcoming dynamic rendering CTS tests that do
vkCmdDrawIndirectCount() in a secondary but put the barrier for it in
the primary.
Fixes: 37939e9c54
("turnip: Fix the lack of WFM before indirect draws")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Connor Abbott
d2ad4c739c
tu/lrz: Do not use framebuffer when inheriting LRZ
...
The only thing it's used for is to get the image view, and we can't rely
on it existing anyway. With dynamic rendering, we only have the format
of the attachments and sample count, so moving forward we can't rely on
anything other than that.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17378 >
2022-07-27 19:40:44 +00:00
Georg Lehmann
df4b5914cd
nir/fold_16bit_tex_image: Default to only_fold_all.
...
No driver doesn't use this option.
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17757 >
2022-07-27 18:57:12 +00:00
Georg Lehmann
dd3e9be413
radeonsi: Stop using nir_legalize_16bit_sampler_srcs.
...
This pass is problematic because it truncates sources when there are type
mismatches. With the right nir_fold_16bit_tex_image options we can ensure
that there is never a mismatch.
Other changes: bias is affected by A16 https://reviews.llvm.org/D111754
And enable G16 as we recently confirmed that it's fully independent from A16.
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17757 >
2022-07-27 18:57:12 +00:00
Danylo Piliaiev
365466a10c
zink/turnip: Add comments to already triaged failures for tu baseline
...
Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17762 >
2022-07-27 17:58:38 +00:00
Chia-I Wu
8001c78d49
ir3: set UL flag before ir3_lower_subgroups
...
ir3_legalize_relative, extracted from ir3_legalize, assumes a0 is loaded
first in each block if there is any user in the block.
ir3_lower_subgroups breaks the assumption. We need to do
ir3_legalize_relative first.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6902
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17720 >
2022-07-27 17:08:03 +00:00
Brian Paul
7023cab093
llvmpipe: fix texcoord analysis regression
...
The texcoord component can be specifed by the src registers swizzle
or the variable's location_frac field.
Signed-off-by: Brian Paul <brianp@vmware.com >
Fixes: 90d011de8e
("llvmpipe: fix texcoord analysis in llvmpipe_nir_fn_is_linear_compat()")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6889
Reviewed-by: Emma Anholt <emma@anholt.net >
Tested-by: Michel Dänzer <mdaenzer@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17743 >
2022-07-27 15:51:27 +00:00
Georg Lehmann
22d860fe4a
aco/ir: Add swapped opcode for v_cmp_u/v_cmp_o.
...
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com >
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17763 >
2022-07-27 14:52:29 +00:00
Georg Lehmann
8f7ceff774
aco/ir: Add v_cmp_class to get_cmp_info.
...
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com >
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17763 >
2022-07-27 14:52:29 +00:00
Georg Lehmann
578d0a1934
aco/ir: Add vcmpx opcode to get_cmp_info.
...
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com >
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17763 >
2022-07-27 14:52:29 +00:00
Georg Lehmann
369b8c031a
aco/ir: Fix swapped nle.
...
Cc: mesa-stable
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com >
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17763 >
2022-07-27 14:52:29 +00:00
Georg Lehmann
9c727b958e
aco/ir: Add integer get_cmp_info.
...
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com >
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17763 >
2022-07-27 14:52:29 +00:00
Georg Lehmann
590b93ae65
aco/ir: Generalize (un)ordered_swapped.
...
Signed-off-by: Georg Lehmann <dadschoorse@gmail.com >
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17763 >
2022-07-27 14:52:29 +00:00