Commit Graph

142108 Commits

Author SHA1 Message Date
Alyssa Rosenzweig 0266cf86e9 asahi: Fix meson dependency on packing in compiler
Closes: #5030
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Fixes: 6a657b17b9 ("agx: Remap fragment shader varyings explicitly")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11730>
2021-07-06 13:44:50 +00:00
Mike Blumenkrantz a4713ddb56 radv: implement VK_EXT_multi_draw
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11532>
2021-07-06 13:16:56 +00:00
Mike Blumenkrantz ba30adce07 radv: add a gfx10 bug workaround for NOT_EOP
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11532>
2021-07-06 13:16:56 +00:00
Mike Blumenkrantz d9132fcb50 radv: split indexed draw cases based on whether drawid is used
fewer conditionals in the draw loop = less overhead

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11532>
2021-07-06 13:16:56 +00:00
Mike Blumenkrantz 5aaf45f5e1 radv: determine if hardware can emit NOT_EOP before emitting
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11532>
2021-07-06 13:16:56 +00:00
Mike Blumenkrantz d28329ed02 radv: emit drawid for multidraws
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11532>
2021-07-06 13:16:56 +00:00
Mike Blumenkrantz 00206b1664 radv: emit NOT_EOP for multi indexed draws
this is never emitted currently because drawCount is always 1

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11532>
2021-07-06 13:16:56 +00:00
Mike Blumenkrantz 72e75092a9 radv: use multidraw iteration for direct draws
there's still no arrays of draw info being passed, but this takes care of
all the work for it

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11532>
2021-07-06 13:16:56 +00:00
Rhys Perry 307a4bf4ab radv: use null vertex descriptor if num_records=0
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11642>
2021-07-06 13:00:35 +00:00
Rhys Perry a2ac660eb7 radv: adjust num_records when offset>stride
If an attribute's offset is larger than the stride, the compiler will
increase the vertex index and use offset%stride instead as the offset.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5007
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11642>
2021-07-06 13:00:35 +00:00
Rhys Perry e4fbb200fc radv: don't ever convert num_records to bytes if it's zero
If num_records==0, this conversion doesn't work. We should just keep it at
zero.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Gitlab: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5007
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11642>
2021-07-06 13:00:35 +00:00
Dave Airlie b7302ecf11 crocus: enable threaded context support
Reviewed-by: Zoltán Böszörményi <zboszor@pr.hu>
Tested-by: Matti Hämäläinen <ccr@tnsp.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11710>
2021-07-06 13:56:48 +10:00
Dave Airlie 86368a5fa2 crocus: add unsync transfer pool
Reviewed-by: Zoltán Böszörményi <zboszor@pr.hu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11710>
2021-07-06 13:56:48 +10:00
Dave Airlie 902eaa9382 crocus/tc: init/deinit threaded resource
Reviewed-by: Zoltán Böszörményi <zboszor@pr.hu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11710>
2021-07-06 13:56:48 +10:00
Dave Airlie a9df8f7b64 crocus: use threaded context base classes
should be a pretty non-functional change

Reviewed-by: Zoltán Böszörményi <zboszor@pr.hu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11710>
2021-07-06 13:56:48 +10:00
Dave Airlie db6042ea14 crocus: support rebinding streamout target buffers
Reviewed-by: Zoltán Böszörményi <zboszor@pr.hu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11710>
2021-07-06 13:56:44 +10:00
Bas Nieuwenhuizen e2e9dd44f4 ac/surface: Handle non-retiled displayable DCC correctly for modifiers.
There is some hardware with num_render_backends == 1, but the number
of render backends in GB_ADDR_CFG > 1. Turns out this can be turned
off by making them rb unaligned which is valid with only 1 render
backend.

Fixes: 0833dd7d12 ("amd/common: Add support for modifiers.")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10575>
2021-07-05 22:34:13 +00:00
Mike Blumenkrantz bb14ef81d5 features: mark off EXT_vertex_input_dynamic_state for lavapipe
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11724>
2021-07-05 18:25:33 -04:00
Mike Blumenkrantz 44ca948789 features: add VK_EXT_multi_draw
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11722>
2021-07-05 21:56:34 +00:00
Mike Blumenkrantz 2e8dd4b4a5 features: fix ARB_shader_group_vote -> GL_ARB_shader_group_vote
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11721>
2021-07-05 21:52:12 +00:00
Mike Blumenkrantz 2cd2eabaae features: mark off some zink features
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11720>
2021-07-05 21:47:36 +00:00
Mike Blumenkrantz 95e567f253 features: mark off line rasterization for lavapipe
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11719>
2021-07-05 17:29:04 -04:00
Mike Blumenkrantz 5685c99afb relnotes: add some line feature updates for lavapipe
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11715>
2021-07-05 21:20:26 +00:00
Alyssa Rosenzweig 18995f13cb asahi: Handle nonzero first_level
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 2923aa6fe1 asahi: Wire in u_blitter
Fixes dEQP-GLES3.functional.fbo.color.repeated_clear.blit.tex2d.rgba8

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig dcd2d8ca50 asahi: Track more Gallium state
Needed to feed u_blitter.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 7a95b1f0fc asahi: Set vertex texture/sampler counts
Fixes

dEQP-GLES2.functional.shaders.texture_functions.vertex.texture2d

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig bee077f5e2 asahi: Identify vertex texture/sampler counts
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 30b6011cf7 asahi: Identify texture/sampler count fields
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig d45257b2be asahi: Fail on LOD clamps/bias
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 50f012542f agx: Handle txl
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 8361e24604 agx: Legalize LOD sources to be 16-bit only
I'm not convinced this is /right/ but it's a step.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 4891e51bf3 agx: Fix lod_mode shift
Was zero before so didn't notice the bug.

Fixes: 9f55538834 ("agx: Pack texture ops")
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig edd30fa1bd agx: Pack LOD descriptors
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig e847bffbcc agx: Fix LOD_MIN enum
Fixes: 2470a080d2 ("agx: Stub NIR backend compiler")
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig c99dfe6a0c agx: Fix 32-bit bitwise shifts
Fixes dEQP-GLES2.functional.shaders.functions.qualifiers.const_int_fragment

Fixes: e50bae00f4 ("agx: Add 32-bit bitwise shifts")
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 8ea262f508 asahi: Add ASAHI_MESA_DEBUG=no16 option
A lot of dEQP failures go away with 32-bit forced...

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 5228be45b6 asahi: Generalize varying linking
Handles matrices now. Fixes

dEQP-GLES2.functional.shaders.matrix.add.dynamic_mediump_mat4_float_fragment

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 2e2270ff14 asahi: Remove spurious varying assignment
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig c946dcf25d asahi: Remove spurious assignment
Doesn't seem necessary.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 5049907ae1 asahi: Implement colour buffer reloads
Gets glmark2 -bdesktop working.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig b59dcf67b6 asahi: Set fragment key for non-U8NORM render targets
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 0e0448d8df asahi: Add internal (renderable) formats to the table
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 78610de496 asahi: Save zsbuf ptr
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 426d55ffad asahi: Add zsbuf to batch
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 2ad59fc9ec asahi: Handle Z16_UNORM textures
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 503742aa32 asahi: Always flush when setting framebuffer state
We don't have batch tracking yet.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 8c94742935 asahi: Guard for overflow when packing
I'm not convinced this is right.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig 41d05ea49e asahi: Fix random *2
Accidentally committed at some point.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00
Alyssa Rosenzweig b9789ae45a asahi: Wire in tgsi_to_nir
Gets GALLIUM_HUD working.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11718>
2021-07-05 20:56:04 +00:00