Mauro Rossi [Sun, 31 Jan 2021 22:16:10 +0000 (23:16 +0100)]
android: pan/mdg: create nir pass to lower image coord bitsize
Fixes the following building error:
FAILED: out/target/product/x86_64/obj/SHARED_LIBRARIES/gallium_dri_intermediates/LINKED/gallium_dri.so
...
ld.lld: error: undefined symbol: midgard_nir_lower_image_bitsize
>>> referenced by midgard_compile.c:321 (external/mesa/src/panfrost/midgard/midgard_compile.c:321)
Fixes:
db725e1d52a6 ("pan/mdg: create nir pass to lower image coord bitsize")
Signed-off-by: Mauro Rossi <issor.oruam@gmail.com>
Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8802>
Vinson Lee [Sat, 23 Jan 2021 02:49:12 +0000 (18:49 -0800)]
v3dv: Fix assert.
Fix defect reported by Coverity Scan.
Side effect in assertion (ASSERT_SIDE_EFFECT)
assignment_where_comparison_intended: Assignment job->ez_state =
VC5_EZ_DISABLED has a side effect. This code will work differently in a
non-debug build.
Fixes:
cec2ed7c80f ("v3dv: fix disabling Early Z for the whole frame")
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8666>
Vinson Lee [Fri, 22 Jan 2021 21:46:49 +0000 (13:46 -0800)]
lima: Fix typos.
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8658>
Marek Olšák [Mon, 4 Jan 2021 20:25:18 +0000 (15:25 -0500)]
mesa: don't count buffer references for the context that created them
See mtypes.h - it gives you the top level view of how it works, and other
code contains a lot of comments.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8606>
Marek Olšák [Sun, 20 Dec 2020 04:02:16 +0000 (23:02 -0500)]
mesa: pop all textures up to NumCurrentTexUsed, not just MaxTextureUnits
glPush/PopAttrib had 2 defects:
- Only MaxTextureUnits were pushed and popped (which is 8 at most).
- If some texture units had been unused, we would still push/pop them.
This fix changes how many units we push and pop to NumCurrentTexUsed,
which is the maximum texture unit + 1 that was used to by the user.
This commit:
- In glPushAttrib, save NumCurrentTexUsed texture units.
- In glPopAttrib, restore the same number of texture units, and if
NumCurrentTexUsed has increased since glPushAttrib, bind 0 in the newly
used units to get them to the state before glPushAttrib.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sun, 20 Dec 2020 00:55:59 +0000 (19:55 -0500)]
mesa: don't push/pop default texture attributes redundantly
Since default texture objects are bound in almost all texture units and all
texture targets, we can skip saving and restoring their attributes if we
just do that for default texture objects outside the loop saving all texture
units.
This reduces CPU time spent in glPushAttrib from 2.1% to 1.35% in one
subtest of viewperf13/catia.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sun, 20 Dec 2020 00:12:48 +0000 (19:12 -0500)]
mesa: don't save gl_shared_state in glPushAttrib
glPushAttrib only saves values and names. It doesn't save objects.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 08:21:25 +0000 (03:21 -0500)]
mesa: partially skip glPush/PopAttrib for MSAA textures and texture buffers
This is based on the GL 4.6 Compatibility profile spec. Some fields just
don't have to be restored. This decreases CPU overhead.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 07:46:03 +0000 (02:46 -0500)]
mesa: only pop states in glPopAttrib that have been changed since glPushAttrib
PopAttribState records all state changes. glPopAttrib uses it to skip
restoring state groups that haven't been changed.
This eliminates a lot of glPopAttrib overhead.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 07:41:32 +0000 (02:41 -0500)]
mesa: optimize out _NEW_ALL in glPopAttrib(GL_ENABLE_BIT)
I reviewed all affected states and this if the minimum attrib mask.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 07:40:15 +0000 (02:40 -0500)]
mesa: fix trivial bugs in glPopAttrib
There were quite a few. Hopefully the comments make it clear.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 06:37:40 +0000 (01:37 -0500)]
mesa: for every state change, remember states we changed for glPopAttrib
The idea is to restore only those states in glPopAttrib that have been
changed. This will reduce glPopAttrib overhead a lot.
This is based on the state tables in the OpenGL 4.6 Compatibility Profile
specification and many extension specifications.
This code might superfluously flag GL_TEXTURE_BIT for texture and
sampler functions that don't have effect on states popped by glPopAttrib,
but I don't wanna test my luck and make a mistake. Thus,
if _NEW_TEXTURE_OBJECT if flagged, GL_TEXTURE_BIT is usually flagged too.
This has no effect on glPopAttrib yet. glPopAttrib will use this in a later
commit. This only adds attrib masks into FLUSH_VERTICES based on specs.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 06:48:40 +0000 (01:48 -0500)]
mesa: flush glBegin/End before changing GL_DEPTH_STENCIL_TEXTURE_MODE
Fixes:
23e81b93bbe3 "mesa: Add core API support for GL_ARB_stencil_texturing (from 4.3)."
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 06:19:35 +0000 (01:19 -0500)]
mesa: fix glPopAttrib for many texture fields
Move the fields that should be restored by glPopAttrib into the Attrib
structure, which is the only portion of texture objects that is restored
by glPopAttrib. Also moves fields that should not be restored by glPopAttrib
out of the Attrib structure.
This is based on the GL 4.6 Compatibility spec.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sun, 20 Dec 2020 00:33:40 +0000 (19:33 -0500)]
mesa: don't push/pop gl_texture_object::Target
This field is immutable because each texture unit is an array of texture
target slots and only matching targets can be bound into each slot.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 08:14:01 +0000 (03:14 -0500)]
mesa: optimize glPopAttrib(GL_VIEWPORT_BIT)
We can just copy the variables because they are already clamped
to ctx->Const limits.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 08:04:45 +0000 (03:04 -0500)]
mesa: optimize most _mesa_ActiveTexture calls in glPopAttrib
_mesa_ActiveTexture changes CurrentUnit and the texture matrix stack
if the matrix mode is a texture matrix. In these cases, the texture matrix
stack is not touched.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Sat, 19 Dec 2020 06:41:04 +0000 (01:41 -0500)]
mesa: remove/replace FLUSH_VERTICES when it doesn't do anything
In _mesa_PopAttrib, we call FLUSH_VERTICES at the beginning, so we don't
need to do it again.
In the MultiMode functions, we call standard Draw functions
using the dispatch, which do the flushing by themselves.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>
Marek Olšák [Thu, 14 Jan 2021 12:43:19 +0000 (07:43 -0500)]
radeonsi: precompute NGG cull flags in si_create_rs_state
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Mon, 11 Jan 2021 20:14:40 +0000 (15:14 -0500)]
radeonsi: prefetch VB descriptors right after uploading
This skips the logic that sets and checks prefetch_L2_mask.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Mon, 11 Jan 2021 20:02:48 +0000 (15:02 -0500)]
radeonsi: set VB user SGPRs in si_upload_vertex_buffer_descriptors
so that we don't have to enter the state emit loop and invoke the more
complicated function si_emit_graphics_shader_pointers.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Sun, 10 Jan 2021 02:43:33 +0000 (21:43 -0500)]
radeonsi: reorganize si_draw_vbo for lower register pressure (part 2)
Move statements that use the least number of local variables as close
to the beginning as possible. Also move local variables closer to their use.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Sun, 10 Jan 2021 02:43:33 +0000 (21:43 -0500)]
radeonsi: reorganize si_draw_vbo for lower register pressure (part 1)
Move statements that use the least number of local variables as close
to the beginning as possible. Also move local variables closer to their use.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Sat, 9 Jan 2021 22:41:17 +0000 (17:41 -0500)]
radeonsi: optimize si_emit_prefetch_L2 when it's split
When using the prefetch with VS_ONLY=true followed by VS_ONLY=false,
we tested the VS_ONLY bits in the mask when executing VS_ONLY=false where
the bits were always 0. It's also useless to clear the prefetch mask when
VS_ONLY=true.
This commit skips those tests by splitting the function properly using
BEFORE_DRAW and AFTER_DRAW template parameters.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Sat, 9 Jan 2021 13:12:38 +0000 (08:12 -0500)]
radeonsi: don't check for redundant and NULL states in si_emit_all_states
All places set dirty_states correctly now.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Wed, 27 Jan 2021 23:06:57 +0000 (18:06 -0500)]
radeonsi: delete si_pm4_delete_state
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Sat, 9 Jan 2021 12:55:59 +0000 (07:55 -0500)]
radeonsi: move si_pm4_delete_state logic into si_pm4_free_state
also clear dirty_states.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Tue, 12 Jan 2021 06:30:53 +0000 (01:30 -0500)]
radeonsi: mark shader_pointers dirty once outside the upload descriptors loop
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Tue, 12 Jan 2021 06:29:28 +0000 (01:29 -0500)]
radeonsi: optimize no-op cases in si_upload_shader_descriptors
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Marek Olšák [Sun, 10 Jan 2021 05:29:01 +0000 (00:29 -0500)]
ac,radeonsi: track memory usage in KB to reduce types from uint64 to uint32
Decreasing the time spent in radeon_cs_memory_below_limit is the motivation.
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>
Dylan Baker [Sat, 30 Jan 2021 04:14:07 +0000 (20:14 -0800)]
docs: update calendar for 21.0.0-rc3
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8791>
Dylan Baker [Sat, 30 Jan 2021 04:13:58 +0000 (20:13 -0800)]
docs: update calendar for 21.0.0-rc2
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8791>
Dylan Baker [Sat, 30 Jan 2021 04:13:33 +0000 (20:13 -0800)]
docs: update calendar and link releases notes for 20.3.4
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8791>
Dylan Baker [Sat, 30 Jan 2021 04:11:41 +0000 (20:11 -0800)]
docs: Add sha256sum for 20.3.4
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8791>
Dylan Baker [Fri, 29 Jan 2021 18:12:48 +0000 (10:12 -0800)]
docs: add release notes for 20.3.4
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8791>
Caio Marcelo de Oliveira Filho [Mon, 11 Jan 2021 19:51:24 +0000 (11:51 -0800)]
spirv: Store SPIR-V version of the module
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8786>
Caio Marcelo de Oliveira Filho [Thu, 21 Jan 2021 10:35:43 +0000 (02:35 -0800)]
spirv: Don't remove dead variables in `create_library` mode
The issues fixed by the removal happen when a module has multiple
entry points and conflicting global variables. Neither conditions are
expected in a library.
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8786>
Caio Marcelo de Oliveira Filho [Tue, 12 Jan 2021 17:21:07 +0000 (09:21 -0800)]
spirv: Don't bother counting num_images/num_textures
Not only these are recalculated in nir_shader_gather_info, but
currently they are also counting all the images / textures in the
module instead of in the shader (entrypoint).
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8786>
Eric Anholt [Fri, 29 Jan 2021 17:59:34 +0000 (09:59 -0800)]
mesa/st: Allocate the gl_context with 16-byte alignment.
The _ModelProjectMatrix matrix embedded inside has members inside of it
marked as 16-byte aligned, and so the context also has to be 16-byte
aligned or access to those members would be invalid. I believe the
compiler used this to use better 16-byte-aligned load/stores to other
members of the context, breaking when the context's alignment was only 8
(as normal mallocs guarantee).
Fixes:
3175b63a0dfa ("mesa: don't allocate matrices with malloc")
Tested-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8783>
Dave Airlie [Thu, 28 Jan 2021 20:32:57 +0000 (06:32 +1000)]
lavapipe: add missing loader interface negoitation
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8769>
Michael Tang [Fri, 29 Jan 2021 20:48:43 +0000 (12:48 -0800)]
microsoft/compiler: Make resource_state_manager only build with_gallium_d3d12
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8785>
Benjamin Tissoires [Fri, 29 Jan 2021 13:30:23 +0000 (14:30 +0100)]
CI: windows: Force using LLVM 12
LLVM is moving to the 13 release, but LLVM-SPIRV is still so in the past.
Given that LLVM 12.0.0 is still not out (we are at 12.0.0-rc1 today),
use the `release/12.x` branch for LLVM.
We should also tag LLVM-SPIRV, but... it seems that they haven't caught up
yet, so keep using the master branch, but add a note for a future
committer.
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8740>
Benjamin Tissoires [Wed, 27 Jan 2021 14:17:28 +0000 (15:17 +0100)]
CI: windows: split the layers to meet new registry requirements
The new registry caching in place for registry.fd.o can not handle layers
bigger than 5 GB. The last layer we used to build on windows was 5.2 GB,
meaning that the upload would fail.
Split the layers by calling multiple `RUN`, hoping that the size will be
roughly split between those steps if we have a special layer for VS2019.
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8740>
Benjamin Tissoires [Wed, 27 Jan 2021 14:21:37 +0000 (15:21 +0100)]
CI: windows: augment the timeout of building the windows container
https://gitlab.freedesktop.org/mesa/mesa/-/jobs/6898838 failed at
uploading the containers but got kicked out right before being able to
give us a valid error.
Bump the timeout for windows container builds, to not have this
unfortunate situation.
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8740>
Mike Blumenkrantz [Mon, 26 Oct 2020 14:47:37 +0000 (10:47 -0400)]
glsl: support 64bit integer loop iterators
this was crashing due to the assumption that non-32bit integer values must be
floats
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7316>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:31:34 +0000 (13:31 -0500)]
pan/bi: Add packing format tests
These are based on reference outputs generated by the blob.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 29 Dec 2020 16:29:45 +0000 (11:29 -0500)]
pan/bi: Test pack_sync
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 29 Dec 2020 16:18:02 +0000 (11:18 -0500)]
pan/bi: Test pack_tuple_bits
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 29 Dec 2020 16:00:31 +0000 (11:00 -0500)]
pan/bi: Test pack_upper
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 29 Dec 2020 15:56:08 +0000 (10:56 -0500)]
pan/bi: Test pack_literal
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 29 Dec 2020 15:35:11 +0000 (10:35 -0500)]
pan/bi: Add packing unit test group
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:43:37 +0000 (13:43 -0500)]
pan/bi: Pack multiple tuples per clause
Use all of the new helpers to pick formats and use them.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:42:44 +0000 (13:42 -0500)]
pan/bi: Calculate pos for constant packing
We do not yet support multiple (format 12 quadword) constants per clause
but this is a step in the right direction.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:41:06 +0000 (13:41 -0500)]
pan/bi: Add pack_format helper
Packs a single quadword of a clause with a particular format and
parameters.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:40:50 +0000 (13:40 -0500)]
pan/bi: Add subword 4 or 7 pack
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:40:31 +0000 (13:40 -0500)]
pan/bi: Add subword 5/6 pack
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:39:59 +0000 (13:39 -0500)]
pan/bi: Add tuple/embedded constant pack
Used for the first 4 subwords.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:39:28 +0000 (13:39 -0500)]
pan/bi: Add bi_pack_sync
The type/sync byte, also known as the tag.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:38:23 +0000 (13:38 -0500)]
pan/bi: Add bi_pack_tuple_bits
More general than the top 3 bit special case. There's some serious
complication around 78-bit shifting but I digress.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:37:51 +0000 (13:37 -0500)]
pan/bi: Add bi_pack_upper
Top 3-bits, found e.g. in the tag.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:37:11 +0000 (13:37 -0500)]
pan/bi: Add bi_pack_literal
Identifies formats.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:36:15 +0000 (13:36 -0500)]
pan/bi: Move bi_packed_tuple to compiler.h
To be used for pack prototype.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 29 Dec 2020 12:51:29 +0000 (07:51 -0500)]
pan/bi: Add clause encodings as a table
We would rather not type out all of the packs by hand (that's error
prone), so declaratively specify the encodings as a table corresponding
to the bit patterns.
This is all formats, except for format 12 which just encodes constants.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 28 Dec 2020 22:56:31 +0000 (17:56 -0500)]
pan/bi: Pack multiple tuples in-memory
There's still some silly clause-level packing required, but this way the
register slots are at least assigned correctly.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 28 Dec 2020 22:56:18 +0000 (17:56 -0500)]
pan/bi: Amend misleading comment
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 22 Dec 2020 20:41:16 +0000 (15:41 -0500)]
pan/bi: Clarify tuple comment
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 22 Dec 2020 20:38:33 +0000 (15:38 -0500)]
pan/bi: Use enum bifrost_message_type
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 22 Dec 2020 20:36:20 +0000 (15:36 -0500)]
pan/bi: Use canonical terminology for tuple
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 22 Dec 2020 20:33:23 +0000 (15:33 -0500)]
pan/bi: Move bi_constants to bifrost.h
Although it's software-defined, this stems from architectural traits and
is useful in both the disasm and the compiler.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 21:23:34 +0000 (16:23 -0500)]
pan/bi: Test read predicates
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:57:16 +0000 (15:57 -0500)]
pan/bi: Test bi_must_message
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:55:06 +0000 (15:55 -0500)]
pan/bi: Test bi_must_last
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:45:51 +0000 (15:45 -0500)]
pan/bi: Unit test bi_can_{fma, add}
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 21:23:19 +0000 (16:23 -0500)]
pan/bi: Add various read predicates
Correpsonding to source masks in the XML.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 21:23:03 +0000 (16:23 -0500)]
pan/bi: Emit branch and table bits in opcode table
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 21:22:43 +0000 (16:22 -0500)]
pan/bi: Label table instructions
Table instructions are a subset of those scheduled to the ADD unit. They
typically involve lookup tables. Table (TBL) instructions have
additional restrictions on their sources which the scheduler must
respect.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:57:11 +0000 (15:57 -0500)]
pan/bi: Add bi_must_message predicate
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:54:48 +0000 (15:54 -0500)]
pan/bi: Add bi_must_last predicate
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:54:31 +0000 (15:54 -0500)]
pan/bi: Pipe last flag into opcode tables
Only ADD unit for now.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:53:57 +0000 (15:53 -0500)]
pan/bi: Annotate ISA.xml with 'last' parameter
If this instruction must be the last in the clause.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:45:23 +0000 (15:45 -0500)]
pan/bi: Add bi_can_{fma, add} predicates
Stubs due to some edge cases, for the scheduler.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:44:51 +0000 (15:44 -0500)]
pan/bi: Factor nir_function_impl out of the context
Unnecessary and complicates unit testing.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Mon, 21 Dec 2020 20:20:37 +0000 (15:20 -0500)]
pan/bi: Stub out scheduler unit test
Someone who understands meson and gtest could do something much nicer,
but for now let's just stuff some assertions into debug builds of the
standalone compiler and call it a day...
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 29 Dec 2020 21:56:23 +0000 (16:56 -0500)]
pan/bi: Add "word equivalence" relation for index
Takes offset *but not swizzle* into account, so the scheduler can
predict whether indices will end up mapped to the same scalar register.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 5 Jan 2021 18:26:56 +0000 (13:26 -0500)]
pan/bi: Move init_builder to common code
Needs to take a cursor to be applicable outside NIR->BIR of course.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 5 Jan 2021 18:26:25 +0000 (13:26 -0500)]
pan/bi: Print multiple destinations if needed
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 5 Jan 2021 18:25:42 +0000 (13:25 -0500)]
pan/bi: Add CUBEFACE pseudoinstruction
Abstracts over *CUBEFACE1/+CUBEFACE2, takes the sources of the former
and outputs two destinations.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Thu, 7 Jan 2021 23:02:40 +0000 (18:02 -0500)]
pan/bi: Don't fill garbage
If an index is an SSA form and we haven't even written to it yet, there
is absolutely no value in filling it, it'd just be uninitialized garbage
that won't get used. Saves some fills in STK.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 30 Dec 2020 15:09:47 +0000 (10:09 -0500)]
pan/bi: Implement spilling at the clause-level
We use essentially the same logic, but we need to treat entire clauses
as large instructions, and spill on clause boundaries instead of
instruction boundaries. So factor out the code a bit, using the new
iterators, removing bi_unwrap_singleton.
A few specific fixes are needed to adapt. One is simple: rewriting
destinations needs to preserve clamps and such. The other is a much more
subtle bug. Consider the clause
{
ADD 0, ...
---unrelated code---
MUL 1, 0, ...
}
Suppose we spill 0. The naive spill code would generate an SSA temporary to
spill to and another SSA temporary to fill from, generating:
{
LOAD.tl 10
}
{
ADD 11, ...
---unrelated code---
MUL 1, 10, ...
}
{
STORE.tl 11
}
But this is wrong; the MUL now reads stale (and for SSA, likely
undefined/uninitialized) data. The simplest fix, employed here, is to
spill/fill within a clause simultaneously, which means the temporary
can't be SSA, generating correct code:
{
LOAD.tl r0
}
{
ADD r0, ...
---unrelated code---
MUL 1, r0, ...
}
{
STORE.tl r0
}
This is suboptimal, since the LOAD is still likely reading garbage that
is unused. But it is still correct, and the next commit will avoid
generating the load in this case.
To make the bug even more subtle, if ADD/MUL are within 2-3 instructions
of each other, the scheduler will optimize the load to a
temporary/passthrough, so the bug isn't noticed. It only happens if they
are 3+ instructions apart yet still in the same clause (<=16
instructions).
Special thanks to macc24 for reporting this bug and to Jason Ekstrand
for allowing me to rubberduck.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 17:25:45 +0000 (12:25 -0500)]
pan/bi: Add interference per clause
With new helpers.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 5 Jan 2021 15:30:09 +0000 (10:30 -0500)]
pan/bi: Permit multiple destinations in RA
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 5 Jan 2021 15:29:01 +0000 (10:29 -0500)]
pan/bi: Don't open code bi_foreach_dest
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 5 Jan 2021 15:28:47 +0000 (10:28 -0500)]
pan/bi: Add destination iterator macro
Convenience.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 17:22:36 +0000 (12:22 -0500)]
pan/bi: Add bi_foreach_instr_in_clause iterators
These are convenient for post-sched passes, in particular register
allocation. They work by noting the underlying linked list of
instructions in the block must be preserved by scheduling. It isn't
necessary iterate the clause structure directly, it can simply be used
to bound a iteration within the block by recalling clauses are strictly
contained in a single block.
<alyssa> I don't think I'm enough of a C ninja to write fancy iterator macros yet.
<zmike> sometimes those can get pretty mind-bendy
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 21:17:37 +0000 (16:17 -0500)]
pan/bi: Add bi_foreach_instr_in_tuple helper
Written in a funny way but easy to convince yourself of correctness by
considering cases.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 6 Jan 2021 17:21:36 +0000 (12:21 -0500)]
pan/bi: Add bi_foreach_clause_in_block_rev
Trivial absense.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Tue, 29 Dec 2020 22:21:37 +0000 (17:21 -0500)]
pan/bi: Add bi_{before,after}_clause cursors
Will be needed to insert spill code after scheduling once we have
multiple instructions in a clause.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Wed, 30 Dec 2020 18:41:14 +0000 (13:41 -0500)]
pan/bi: Add "soft" mode to DCE
We would like to reuse the DCE logic to eliminate register writes
without eliminating instructions, as a post-sched pass. This type of
operation will eventually generalize to intrinsics that write a register
*and* have side effects (just atomics, I think).
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Thu, 21 Jan 2021 00:09:34 +0000 (19:09 -0500)]
pan/bi: Add dead branch elimination pass
Ported from Midgard due to the same quirk of our code generation.
Additional validation, though.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>
Alyssa Rosenzweig [Sat, 9 Jan 2021 03:58:09 +0000 (22:58 -0500)]
pan/bi: Pass through wait_{6, 7} flags
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>