Konrad Kleine [Thu, 13 Jan 2022 15:46:09 +0000 (15:46 +0000)]
Update docs/drivers/llvmpipe.rst
to include a link to the LLVM Snapshots for Fedora.
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14537>
Juan A. Suarez Romero [Thu, 18 Aug 2022 08:03:39 +0000 (10:03 +0200)]
vc4: store tex sampler in proper register
When unpacking the texture sample result ensure it is moved to the
proper expected dest register.
This fixes incorrect texturing in Chromium using PixiJS framework.
CC: mesa-stable
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18122>
Erico Nunes [Mon, 22 Aug 2022 08:03:41 +0000 (10:03 +0200)]
ci: enable lima farm
Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18178>
Konstantin Seurer [Sat, 20 Aug 2022 18:39:23 +0000 (20:39 +0200)]
lavapipe: Set ss_dirty in emit_state
Set ss_dirty to false when updating the samplers.
Signed-off-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18161>
Eric Engestrom [Sun, 21 Aug 2022 11:58:05 +0000 (12:58 +0100)]
meson: drop duplicate `lib` in lib name
The default lib prefix is `lib`, so adding `lib` to the lib name just
results in `liblibbroadcom_v3d.a` for instance.
Those are internal, build-temporary static libraries that end up being
linked into the real user-visible libraries, so it doesn't really
matter, but we might as well just clean up their names anyway.
Reviewed-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Juan A. Suarez <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18171>
Simon Ser [Thu, 28 Jul 2022 12:54:56 +0000 (14:54 +0200)]
vulkan/wsi/x11: detect Xwayland via the XWAYLAND extension
This is more robust than checking for XRandR output names.
Signed-off-by: Simon Ser <contact@emersion.fr>
References: https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/954
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17790>
Vinson Lee [Mon, 20 Sep 2021 05:49:37 +0000 (22:49 -0700)]
bin/perf-annotate-jit.py: Update to Python 3.
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12926>
Mike Blumenkrantz [Wed, 17 Aug 2022 17:41:45 +0000 (13:41 -0400)]
st_pbo/compute: pre-clamp loaded geometry based on coord components
if only some of these components will be used, clamp the rest to enable
better shader optimizing
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18118>
Mike Blumenkrantz [Wed, 17 Aug 2022 17:34:51 +0000 (13:34 -0400)]
st_pbo/compute: pre-clamp shader geometry to 16bit
no point doing this in the shader
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18118>
Mike Blumenkrantz [Wed, 17 Aug 2022 15:50:22 +0000 (11:50 -0400)]
st_pbo/compute: fix 1D coord dimension by pre-trimming vectors
cc: mesa-stable
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18118>
Mike Blumenkrantz [Wed, 17 Aug 2022 21:27:00 +0000 (17:27 -0400)]
st_pbo/compute: fix 1D_ARRAY offsets
these come in as yoffset, but the constant data must use 0 since the sampler
view is created with the offset
cc: mesa-stable
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18118>
Mike Blumenkrantz [Fri, 12 Aug 2022 16:37:22 +0000 (12:37 -0400)]
st_pbo/compute: handle download failures with fallback
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18118>
Alyssa Rosenzweig [Mon, 1 Aug 2022 22:57:55 +0000 (18:57 -0400)]
panfrost: Assert that blend shaders are nontrivial
Even if the driver doesn't *use* trivial blend shaders, building and compiling
blend shaders is expensive. We shouldn't be building blend shaders that should
never be used.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Mon, 1 Aug 2022 22:57:53 +0000 (18:57 -0400)]
panfrost: Include mask in replace blend shader name
Helpful to disambiguate blend shaders with different colour masks used for the
same format/replace operation.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Mon, 1 Aug 2022 22:57:52 +0000 (18:57 -0400)]
panfrost: Simplify blitter blend shader creation
We don't need blending in the blitter. That means blend shaders are only needed
on Midgard. Simplify accordingly.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Fri, 19 Aug 2022 19:14:03 +0000 (15:14 -0400)]
panfrost: Invert no_colour to enabled
This way, blend info that's left zeroed out defaults to disabled. Fixes an
assertion failure in KHR-GLES31.core.draw_buffers_indexed.color_masks due to
the blend CSO max_rt being set unreliably. This is also probably clearer.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Mon, 1 Aug 2022 22:57:49 +0000 (18:57 -0400)]
panfrost: Don't compile empty blend shaders
This is silly. They'll be masked out later, but it's still pointless, and adds
noise when grepping BIFROST_MESA_DEBUG=shaders,internal for "pan_blend" when
debugging why an app is using blend shaders.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Mon, 1 Aug 2022 22:57:46 +0000 (18:57 -0400)]
panfrost: Avoid blend shader when not blending
On Midgard, we need a "blend" shader even if blending is disabled, if the format
isn't blendable. This is inefficient. Bifrost solves this by decoupling the
format conversion from the blending, allowing opaque (unblended) output to any
format without a blend shader or fragment key.
Unfortunately, our blend code is from the Midgard era -- I wrote an early
version of nir_lower_blend when I was still in high school! -- so we've been
using blend shaders for opaque output even on Bifrost. Whoops!
In SuperTuxKart, reduces blend shader calls by 30%, translating to a 15%
reduction in i-cache misses.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Fri, 5 Aug 2022 21:34:04 +0000 (17:34 -0400)]
panfrost: Promote blend shader outputs 8->16-bit
..on Bifrost and later, where the conversion hardware makes this reasonable.
This saves us from inserting a pile of conversions in the compiler to lower away
the 8-bit input/output. This also generates substantially better code.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Fri, 5 Aug 2022 21:29:36 +0000 (17:29 -0400)]
panfrost: Don't saturate in Bifrost blend shaders
It's unnecessary since the hardware already does the conversion for us.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Fri, 5 Aug 2022 21:09:41 +0000 (17:09 -0400)]
panfrost: Set blit output variable types correctly
The type of the output variable will propagate through the store_output
intrinsic's src_type field to the BLEND instruction's register format field. On
Valhall, the register format for a BLEND comes from the instruction -- the
register format specified in the conversion descriptor (used on Bifrost) is
ignored. That means it has to match.
Previously, we always used a blend shader for integer rendering. Since blend
shaders ignore the register format of the BLEND instruction, that masked this
issue. That also means we don't need to backport this.
Will prevent a regression from the following commit.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Fri, 19 Aug 2022 21:49:33 +0000 (17:49 -0400)]
panfrost: Handle untyped_color_outputs on Bifrost
For untyped_color_outputs, we need to ignore the type of the colour output in
the shader and instead use the type from the format. We have all the information
to do this at blend descriptor pack time, but not at shader compile time. This
means we need a (somewhat expensive) fixup in this edge case to ingest
NIR-to-TGSI. This will prevent a regression from the rest of the series.
Although the register_format field is also present on Valhall blend descriptors,
it is ignored so we don't need the fixup there.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Fri, 19 Aug 2022 18:56:18 +0000 (14:56 -0400)]
pan/bi: Handle info.fs.untyped_color_outputs on Valhall
Colour outputs in TGSI are untyped so we have to ignore the register format on
the store_output. Luckily, Valhall gives us the auto32 escape hatch to deal with
it, and Bifrost doesn't care anyway. This will avoid regressions from native int
output without corrupting the compiler for GLSL and SPIR-V shaders that are
well-typed.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Fri, 19 Aug 2022 22:30:01 +0000 (18:30 -0400)]
pan/bi: Don't allow ATEST to take a temporary
Clause scheduler edition of
db2bdc1dc37 ("pan/bi: Require ATEST coverage mask
input in R60"). ATEST wants to read r60, which can't work if its input isn't
even in a register.
When per-sample shading isn't in use, prevents regressions in:
KHR-GLES31.core.sample_variables.mask.*
These tests previously passed because per-sample shading was forced. It's
not clear whether the bug addressed in this patch is possible to hit "in the
wild", i.e. without the optimizations in this series that allow us to use
per-pixel shading in more cases.
No shader-db changes.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Fri, 19 Aug 2022 23:22:14 +0000 (19:22 -0400)]
pan/bi: Don't reorder image loads across stores
Fixes flaking in
dEQP-GLES31.functional.image_load_store.cube.qualifiers.volatile_r32i due to
image reads being moved past a BARRIER.
To make this more robust/optimal, we probably need scheduling information
(coherent/volatile/etc) added to instructions like ACO does. That's left for a
future extension, for now I just want the test to stop flaking.
Fixes:
569e5dc7450 ("pan/bi: Schedule for pressure pre-RA")
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17841>
Alyssa Rosenzweig [Thu, 18 Aug 2022 00:28:01 +0000 (20:28 -0400)]
asahi: Fix warning building for macOS 12.0
Unnecessary rename that breaks forward compatibility... but Apple says
this is just NULL. Do the simpler thing. Note that the argument is a
mach_port_t, which is a natural_t == uint32_t in userspace... even
though it's a pointer in the kernel. Although Apple's docs claim that
kIOMasterPortDefault is NULL, it's really just 0.
../src/asahi/lib/agx_device.c:290:35: warning: 'kIOMasterPortDefault' is deprecated: first deprecated in macOS 12.0 [-Wdeprecated-declarations]
IOServiceGetMatchingService(kIOMasterPortDefault, matching);
^~~~~~~~~~~~~~~~~~~~
kIOMainPortDefault
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18121>
Danylo Piliaiev [Fri, 19 Aug 2022 18:21:43 +0000 (21:21 +0300)]
tu: Assert that if draw state is enabled it has valid iova
GPU faults at draw state loading completely could completely bring
down the board. (Happened on HDK888)
Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18149>
Pavel Ondračka [Mon, 11 Jul 2022 11:11:53 +0000 (13:11 +0200)]
r300: merge MOVs with MULs or ADDs in merge channels
Shader-db stats with RV530:
total instructions in shared programs: 166499 -> 164362 (-1.28%)
instructions in affected programs: 80056 -> 77919 (-2.67%)
total temps in shared programs: 21658 -> 21565 (-0.43%)
temps in affected programs: 1780 -> 1687 (-5.22%)
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17560>
Pavel Ondračka [Tue, 12 Jul 2022 14:04:22 +0000 (16:04 +0200)]
r300: merge MOVs into ADD using the 0 swizzle
Shader-db stats with RV530:
total instructions in shared programs: 169509 -> 166013 (-2.06%)
instructions in affected programs: 99126 -> 95630 (-3.53%)
total presub in shared programs: 10975 -> 10758 (-1.98%)
presub in affected programs: 744 -> 527 (-29.17%)
total temps in shared programs: 21722 -> 21649 (-0.34%)
temps in affected programs: 1350 -> 1277 (-5.41%)
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17560>
Pavel Ondračka [Tue, 12 Jul 2022 14:03:35 +0000 (16:03 +0200)]
r300: don't merge w channel in fragment shaders
Skip the merge if one of the instructions writes just w channel
and we are compiling a fragment shader. We can pair-schedule it together
later anyway and it will also give the scheduler a bit more flexibility.
Shader-db stats with RV530:
total instructions in shared programs: 169522 -> 169509 (<.01%)
instructions in affected programs: 14170 -> 14157 (-0.09%)
total temps in shared programs: 21712 -> 21722 (0.05%)
temps in affected programs: 324 -> 334 (3.09%)
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17560>
Pavel Ondračka [Tue, 12 Jul 2022 13:15:20 +0000 (15:15 +0200)]
r300: generalize the merge_movs pass
To allow a simple extension with more merging combinations in the
later commits.
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17560>
Pavel Ondračka [Fri, 17 Jun 2022 19:09:32 +0000 (21:09 +0200)]
r300: run dataflow optimizations in separate loops
Constant folding first, than copy propagate simple movs, after that
we run the merge movs pass and finally peephole. The important part
is to do the copy propagate for the whole program before running merge
movs.
We no longer check the return from merge_movs so convert it to void.
Shader-db changes with RV530:
total instructions in shared programs: 155361 -> 154787 (-0.37%)
instructions in affected programs: 67920 -> 67346 (-0.85%)
total temps in shared programs: 20836 -> 20773 (-0.30%)
temps in affected programs: 711 -> 648 (-8.86%)
total presub in shared programs: 8226 -> 8202 (-0.29%)
presub in affected programs: 223 -> 199 (-10.76%)
total temps in shared programs: 20836 -> 20773 (-0.30%)
temps in affected programs: 711 -> 648 (-8.86%)
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17560>
Pavel Ondračka [Wed, 22 Jun 2022 16:30:06 +0000 (18:30 +0200)]
r300: check for identical saturate mode when merging MOVs
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17560>
Pavel Ondračka [Tue, 12 Jul 2022 08:17:13 +0000 (10:17 +0200)]
r300: fix negate mask computation when merging movs
The main problem here is we can have a negate bit set for an unused
channel, so we can't just OR together the negates when channel merging.
Right now the bug is hidden because how we run the pass order, but
that will change in a later commit. Add some helpers for merging of the
negates, they will be also used more in a later commits. As a bonus
construct the new source separatelly and only rewrite the original
instructions after checking that the final swizzle is valid.
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17560>
Pavel Ondračka [Thu, 14 Jul 2022 16:35:56 +0000 (18:35 +0200)]
r300: allow constant swizzles with inline constant
This will prevent a regression in the number of inlined constants in
a later commit. Constructs like 4.000000 (0x48).w110 works just fine.
There is a small behavioral change. We would previously allow positive
and negative same-value contants to be produced, e.g.,
4.000000 (0x48).w-w__ and this would be later split into some extra
movs in the dataflow swizzle pass. We now explicitly check that the
final swizzle is valid while inlining. So there is a minor decrease
in inlined constants and in the total instructions.
total lits in shared programs: 4328 -> 4194 (-3.10%)
lits in affected programs: 554 -> 420 (-24.19%)
total instructions in shared programs: 155488 -> 155361 (-0.08%)
instructions in affected programs: 5707 -> 5580 (-2.23%)
Additonally, a fix for pair translation is needed since the constant
inlining can now produce swizzles like this: 4.000000 (0x48).w-0-0-_
so we have to teach pair translation to also ignore the sign for zero
swizzle.
Signed-off-by: Pavel Ondračka <pavel.ondracka@gmail.com>
Reviewed-by: Filip Gawin <filip@gawin.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17560>
Jesse Natalie [Thu, 18 Aug 2022 15:01:23 +0000 (08:01 -0700)]
microsoft/clc: Handle a null clc logger
Fixes:
55b3980e ("microsoft/compiler: Add dxil_logger type and parameter to nir_to_dxil")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7076
Reviewed-by: Michael Tang <tangm@microsoft.com>
Tested-by: Prodea Alexandru-Liviu <liviuprodea@yahoo.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18127>
Riteo [Tue, 16 Aug 2022 09:41:59 +0000 (11:41 +0200)]
vulkan/device_select_wayland: fix a memory leak with DRM device handling
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18076>
Konstantin Seurer [Fri, 19 Aug 2022 13:50:10 +0000 (15:50 +0200)]
radv/ci: Remove host build related fails
!17028 removed acceleration structure host build support.
Signed-off-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18142>
Timur Kristóf [Wed, 13 Apr 2022 17:29:30 +0000 (19:29 +0200)]
aco: Improve SCC nocompare optimization when SCC is clobbered.
When SCC is clobbered between s_cmp and its operand's writer,
the current optimization that eliminates s_cmp won't kick in.
However, when s_cmp is the only user of its operand temporary,
it is possible to "pull down" the instruction that wrote the operand.
Fossil DB stats on Navi 21:
Totals from 63302 (46.92% of 134906) affected shaders:
CodeSize:
176689272 ->
176418332 (-0.15%)
Instrs:
33552237 ->
33484502 (-0.20%)
Latency:
205847485 ->
205816205 (-0.02%); split: -0.02%, +0.00%
InvThroughput:
34321285 ->
34319908 (-0.00%); split: -0.00%, +0.00%
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16266>
Timur Kristóf [Wed, 23 Mar 2022 17:45:36 +0000 (18:45 +0100)]
aco: Support s_cselect_b64 in SCC no-compare optimization.
This was simply left out by accident when I wrote this.
Fossil DB stats on Navi 21:
Totals from 70165 (52.01% of 134906) affected shaders:
CodeSize:
246375656 ->
245814396 (-0.23%)
Instrs:
46519773 ->
46379458 (-0.30%)
Latency:
385159303 ->
385089261 (-0.02%); split: -0.02%, +0.00%
InvThroughput:
66490172 ->
66487867 (-0.00%); split: -0.00%, +0.00%
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16266>
Timur Kristóf [Sat, 6 Aug 2022 09:58:50 +0000 (11:58 +0200)]
aco/optimizer_postRA: Don't try to optimize dead instructions.
Also delete them when they are already dead in process_instruction().
No Fossil DB changes.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16266>
David Heidelberg [Thu, 11 Aug 2022 13:59:05 +0000 (15:59 +0200)]
ci: implement stress testing jobs in ci_run_n_monitor.py
Can be triggered by `--stress`.
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18014>
David Heidelberg [Fri, 12 Aug 2022 13:03:06 +0000 (15:03 +0200)]
ci: GraphQL was already implemented in ci_run_n_monitor.py
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18014>
David Heidelberg [Fri, 19 Aug 2022 22:55:16 +0000 (00:55 +0200)]
ci: traces: update freedreno and broadcom to brotli compressed traces
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18156>
Mike Blumenkrantz [Thu, 11 Aug 2022 13:10:08 +0000 (09:10 -0400)]
zink: add gfx pipeline lookup shortcut
if the final hash was the same as the last-used hash for this program,
it should be safe to reuse the last pipeline object in the presence of
dynamic vertex input since the number of permutations is low
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 11 Aug 2022 19:48:11 +0000 (15:48 -0400)]
zink: track which stages in gfx programs are using inlined uniforms
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 18:12:37 +0000 (14:12 -0400)]
zink: split resource tracking into two sets for buffer/texture
this will make the hash lookups slightly faster to cut down overhead
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 18:10:32 +0000 (14:10 -0400)]
zink: make batch internal api static again
hooray
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 17:40:55 +0000 (13:40 -0400)]
zink: merge all the batch state sets onto the struct
less memory fragmentation
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 16:02:48 +0000 (12:02 -0400)]
zink: use PIPE_CAP_RGB_OVERRIDE_DST_ALPHA_BLEND
this eliminates the bespoke handling I wrote to do the same thing a while ago
cc: mesa-stable
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 11:55:20 +0000 (07:55 -0400)]
zink: add is_buffer param to zink_batch_resource_usage_set
this allows constants to be specified, reducing register pressure during
descriptor binds
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 11:44:10 +0000 (07:44 -0400)]
zink: move zink_batch_resource_usage_set to be static inline
this has to go in zink_resource.h to avoid infinite include dependency
conflicts
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 11:43:22 +0000 (07:43 -0400)]
zink: remove c++ guard from zink_resource.h
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 12:09:30 +0000 (08:09 -0400)]
zink: add more c++ guards to headers
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 11:42:43 +0000 (07:42 -0400)]
zink: make zink_bo.h compile in c++
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 11:18:40 +0000 (07:18 -0400)]
zink: constify shader module variable
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Tue, 9 Aug 2022 11:18:17 +0000 (07:18 -0400)]
zink: pass shader stage as param for gfx module update
less register pressure
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Mon, 8 Aug 2022 20:39:13 +0000 (16:39 -0400)]
zink: use dynarray instead of list for internal shader cache
this is less likely to obliterate cpu caches
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Mon, 8 Aug 2022 15:43:15 +0000 (11:43 -0400)]
zink: change u_foreach_bit to regular for loop in zink_gfx_program_update
too hot to be using this
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Mon, 8 Aug 2022 14:42:34 +0000 (10:42 -0400)]
zink: make program cache values more intelligible
instead of magic constants
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 17:24:19 +0000 (13:24 -0400)]
zink: cache dynamic render vs renderpass pipelines separately
removes comparisons from hash lookup
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Mon, 8 Aug 2022 18:28:06 +0000 (14:28 -0400)]
zink: use stage comparison template to ignore vertices_per_patch
no need to compare if this won't be used
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 17:20:24 +0000 (13:20 -0400)]
zink: add templates for pipeline stage comparison
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 20:12:19 +0000 (16:12 -0400)]
zink: use a list for free batch states
this ensures "fairer" reuse and avoids having any states sitting idle
for too long with resources attached
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 14:13:18 +0000 (10:13 -0400)]
zink: split out first-time shader module creation
this simplifies the code a bit and makes it more flexible
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 14:01:46 +0000 (10:01 -0400)]
zink: split out gfx shader module creation from cache searching
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 13:56:34 +0000 (09:56 -0400)]
zink: split out nonseamless/inline shader module info calculation
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 13:49:28 +0000 (09:49 -0400)]
zink: plumb screen info through shader key comparison
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 13:20:35 +0000 (09:20 -0400)]
zink: plumb some screen info through gfx shader creation
this should allow optimizing out some parts of the code
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 12:52:07 +0000 (08:52 -0400)]
zink: simplify shader key comparison by splitting out non-generated tcs
non-generated tcs has unique mechanics in that it doesn't have a base shader key,
so split that out to avoid unnecessary complexity
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 02:43:38 +0000 (22:43 -0400)]
zink: rework bit iteration in update_gfx_shader_modules to use for loop
this is roughly 1% faster in drawoverhead case 7
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Fri, 5 Aug 2022 02:18:38 +0000 (22:18 -0400)]
zink: fix shader key struct packing
these structs were improperly sizing to be way bigger than expected
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 20:03:41 +0000 (16:03 -0400)]
zink: remove some gfx pipeline state members
these are no longer used
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 20:00:37 +0000 (16:00 -0400)]
zink: use template to eliminate more instructions in pipeline state comparison
these values don't need to be checked at all if dynamic vertex is enabled,
which wouldn't previously have been possible without adding even more
data to check to the pipeline state
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 19:54:19 +0000 (15:54 -0400)]
zink: move pipeline state comparison to c++ template
the other part of the pipeline update hotpath
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 19:07:12 +0000 (15:07 -0400)]
zink: move gfx pipeline recalc to c++
this is one of the hottest paths in the driver, and having to load
a function variant with all the extra dynamic state paths is not optimal
when they can never be used
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 19:52:19 +0000 (15:52 -0400)]
zink: move pipeline cache structs to zink_program.h
these shouldn't be widely used, so they're not in zink_types.h
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 19:52:07 +0000 (15:52 -0400)]
zink: add c++ guards to zink_pipeline.h
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 18:38:13 +0000 (14:38 -0400)]
zink: remove cpu conditional render hack
this was quite useful for debugging/testing, but now everything works,
so it's dead code
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 18:33:27 +0000 (14:33 -0400)]
zink: move gfx program update/creation into zink_program.c
this doesn't need to be c++
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 18:21:37 +0000 (14:21 -0400)]
zink: deduplicate some program destroy code
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Mike Blumenkrantz [Thu, 4 Aug 2022 18:17:50 +0000 (14:17 -0400)]
zink: deduplicate some program creation code
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
Matt Turner [Mon, 15 Aug 2022 16:36:42 +0000 (16:36 +0000)]
freedreno/ir3: Use nir_opt_idiv_const
Notably reduces the number of instructions in manhattan31/377 by 101:
instructions helped: shaders/closed/android/gfxbench/manhattan31/377.shader_test CL: 1700 -> 1599 (-5.94%)
total instructions in shared programs: 1713536 -> 1713313 (-0.01%)
instructions in affected programs: 7635 -> 7412 (-2.92%)
helped: 12
HURT: 9
total nops in shared programs: 377253 -> 377188 (-0.02%)
nops in affected programs: 3170 -> 3105 (-2.05%)
helped: 13
HURT: 8
total non-nops in shared programs: 1336283 -> 1336125 (-0.01%)
non-nops in affected programs: 3134 -> 2976 (-5.04%)
helped: 12
HURT: 4
total mov in shared programs: 66642 -> 66641 (<.01%)
mov in affected programs: 145 -> 144 (-0.69%)
helped: 1
HURT: 4
total cov in shared programs: 20215 -> 20223 (0.04%)
cov in affected programs: 64 -> 72 (12.50%)
helped: 0
HURT: 8
total dwords in shared programs: 3650282 -> 3649876 (-0.01%)
dwords in affected programs: 11222 -> 10816 (-3.62%)
helped: 12
HURT: 0
total constlen in shared programs: 246636 -> 246656 (<.01%)
constlen in affected programs: 72 -> 92 (27.78%)
helped: 0
HURT: 5
total cat0 in shared programs: 411874 -> 411809 (-0.02%)
cat0 in affected programs: 3414 -> 3349 (-1.90%)
helped: 13
HURT: 8
total cat1 in shared programs: 87109 -> 87116 (<.01%)
cat1 in affected programs: 398 -> 405 (1.76%)
helped: 1
HURT: 12
total cat2 in shared programs: 797105 -> 797030 (<.01%)
cat2 in affected programs: 1619 -> 1544 (-4.63%)
helped: 12
HURT: 0
total cat3 in shared programs: 348412 -> 348322 (-0.03%)
cat3 in affected programs: 404 -> 314 (-22.28%)
helped: 12
HURT: 0
total sstall in shared programs: 133300 -> 133302 (<.01%)
sstall in affected programs: 73 -> 75 (2.74%)
helped: 0
HURT: 1
total (ss) in shared programs: 36137 -> 36139 (<.01%)
(ss) in affected programs: 54 -> 56 (3.70%)
helped: 0
HURT: 2
total systall in shared programs: 323494 -> 323624 (0.04%)
systall in affected programs: 1591 -> 1721 (8.17%)
helped: 4
HURT: 2
total (sy) in shared programs: 14306 -> 14308 (0.01%)
(sy) in affected programs: 46 -> 48 (4.35%)
helped: 0
HURT: 2
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18085>
Matt Turner [Mon, 15 Aug 2022 16:25:44 +0000 (16:25 +0000)]
freedreno/ir3: Don't use the broken idiv lowering
This hurts, but we really can't tolerate incorrect results.
Notably hurts manhattan31/377 (but half of the damage is handled by the
next commit).
instructions HURT: shaders/closed/android/gfxbench/manhattan31/377.shader_test CL: 1509 -> 1700 (12.66%)
total instructions in shared programs: 1674990 -> 1713536 (2.30%)
instructions in affected programs: 205016 -> 243562 (18.80%)
helped: 10
HURT: 357
total nops in shared programs: 370499 -> 377253 (1.82%)
nops in affected programs: 54465 -> 61219 (12.40%)
helped: 74
HURT: 289
total non-nops in shared programs: 1304491 -> 1336283 (2.44%)
non-nops in affected programs: 147087 -> 178879 (21.61%)
helped: 5
HURT: 348
total mov in shared programs: 64188 -> 66642 (3.82%)
mov in affected programs: 5667 -> 8121 (43.30%)
helped: 5
HURT: 346
total cov in shared programs: 23603 -> 20215 (-14.35%)
cov in affected programs: 9274 -> 5886 (-36.53%)
helped: 347
HURT: 0
total dwords in shared programs: 3385438 -> 3650282 (7.82%)
dwords in affected programs: 630672 -> 895516 (41.99%)
helped: 0
HURT: 690
total full in shared programs: 93112 -> 93127 (0.02%)
full in affected programs: 390 -> 405 (3.85%)
helped: 10
HURT: 22
total constlen in shared programs: 245400 -> 246636 (0.50%)
constlen in affected programs: 19504 -> 20740 (6.34%)
helped: 0
HURT: 309
total cat0 in shared programs: 405120 -> 411874 (1.67%)
cat0 in affected programs: 57075 -> 63829 (11.83%)
helped: 74
HURT: 289
total cat1 in shared programs: 87987 -> 87109 (-1.00%)
cat1 in affected programs: 13032 -> 12154 (-6.74%)
helped: 282
HURT: 17
total cat2 in shared programs: 775647 -> 797105 (2.77%)
cat2 in affected programs: 106737 -> 128195 (20.10%)
helped: 0
HURT: 347
total cat3 in shared programs: 337200 -> 348412 (3.33%)
cat3 in affected programs: 17551 -> 28763 (63.88%)
helped: 0
HURT: 347
total sstall in shared programs: 133312 -> 133300 (<.01%)
sstall in affected programs: 85 -> 73 (-14.12%)
helped: 1
HURT: 0
total (ss) in shared programs: 36146 -> 36137 (-0.02%)
(ss) in affected programs: 345 -> 336 (-2.61%)
helped: 20
HURT: 11
total systall in shared programs: 323432 -> 323494 (0.02%)
systall in affected programs: 2762 -> 2824 (2.24%)
helped: 11
HURT: 15
total (sy) in shared programs: 14301 -> 14306 (0.03%)
(sy) in affected programs: 54 -> 59 (9.26%)
helped: 0
HURT: 4
Total CPU time (seconds): 0 -> 0
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18085>
Alyssa Rosenzweig [Mon, 1 Aug 2022 23:11:09 +0000 (19:11 -0400)]
pan/bi: Use nir_opt_idiv_const
Mitigates some of the hurt from idiv lowering.
total instructions in shared programs: 2734512 -> 2734269 (<.01%)
instructions in affected programs: 10419 -> 10176 (-2.33%)
helped: 11
HURT: 4
helped stats (abs) min: 9.0 max: 49.0 x̄: 22.45 x̃: 19
helped stats (rel) min: 1.84% max: 7.50% x̄: 3.65% x̃: 3.30%
HURT stats (abs) min: 1.0 max: 1.0 x̄: 1.00 x̃: 1
HURT stats (rel) min: 0.14% max: 0.14% x̄: 0.14% x̃: 0.14%
95% mean confidence interval for instructions value: -25.34 -7.06
95% mean confidence interval for instructions %-change: -3.91% -1.37%
Instructions are helped.
total cycles in shared programs: 140629.05 -> 140628.61 (<.01%)
cycles in affected programs: 25.12 -> 24.69 (-1.74%)
helped: 3
HURT: 0
helped stats (abs) min: 0.0625 max: 0.3125 x̄: 0.15 x̃: 0
helped stats (rel) min: 0.82% max: 3.17% x̄: 1.60% x̃: 0.82%
total cvt in shared programs: 14826.25 -> 14819.52 (-0.05%)
cvt in affected programs: 189.64 -> 182.91 (-3.55%)
helped: 42
HURT: 0
helped stats (abs) min: 0.046875 max: 1.015625 x̄: 0.16 x̃: 0
helped stats (rel) min: 0.74% max: 11.76% x̄: 3.73% x̃: 2.82%
95% mean confidence interval for cvt value: -0.23 -0.09
95% mean confidence interval for cvt %-change: -4.65% -2.82%
Cvt are helped.
total sfu in shared programs: 8601.81 -> 8613.56 (0.14%)
sfu in affected programs: 85.62 -> 97.38 (13.72%)
helped: 0
HURT: 41
HURT stats (abs) min: 0.0625 max: 1.25 x̄: 0.29 x̃: 0
HURT stats (rel) min: 3.45% max: 33.33% x̄: 15.48% x̃: 16.67%
95% mean confidence interval for sfu value: 0.21 0.36
95% mean confidence interval for sfu %-change: 13.28% 17.69%
Sfu are HURT.
total quadwords in shared programs: 1479736 -> 1479616 (<.01%)
quadwords in affected programs: 3392 -> 3272 (-3.54%)
helped: 8
HURT: 0
helped stats (abs) min: 8.0 max: 24.0 x̄: 15.00 x̃: 16
helped stats (rel) min: 1.54% max: 4.62% x̄: 3.57% x̃: 3.71%
95% mean confidence interval for quadwords value: -20.58 -9.42
95% mean confidence interval for quadwords %-change: -4.39% -2.75%
Quadwords are helped.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17266>
Alyssa Rosenzweig [Fri, 24 Jun 2022 15:04:15 +0000 (11:04 -0400)]
pan/bi: Don't use the broken idiv lowering
Rip off the band-aid. We can't tolerate straight-up wrong results, after all.
Addresses the Bifrost/Valhall portion of #6555.
Fixes test_integer_ops uint_math / subcase.
total instructions in shared programs: 2674840 -> 2734512 (2.23%)
instructions in affected programs: 189964 -> 249636 (31.41%)
helped: 0
HURT: 383
HURT stats (abs) min: 8.0 max: 184.0 x̄: 155.80 x̃: 173
HURT stats (rel) min: 1.85% max: 126.09% x̄: 32.38% x̃: 34.46%
95% mean confidence interval for instructions value: 150.98 160.63
95% mean confidence interval for instructions %-change: 31.27% 33.48%
Instructions are HURT.
total cycles in shared programs: 140627.36 -> 140629.05 (<.01%)
cycles in affected programs: 24.81 -> 26.50 (6.80%)
helped: 0
HURT: 4
HURT stats (abs) min: 0.1875 max: 0.9375 x̄: 0.42 x̃: 0
HURT stats (rel) min: 2.52% max: 37.50% x̄: 13.26% x̃: 6.52%
95% mean confidence interval for cycles value: -0.14 0.99
95% mean confidence interval for cycles %-change: -13.14% 39.67%
Inconclusive result (value mean confidence interval includes 0).
total fma in shared programs: 22578.03 -> 22549.94 (-0.12%)
fma in affected programs: 1056.33 -> 1028.23 (-2.66%)
helped: 383
HURT: 0
helped stats (abs) min: 0.015625 max: 0.375 x̄: 0.07 x̃: 0
helped stats (rel) min: 0.55% max: 50.00% x̄: 3.07% x̃: 2.34%
95% mean confidence interval for fma value: -0.08 -0.07
95% mean confidence interval for fma %-change: -3.39% -2.75%
Fma are helped.
total cvt in shared programs: 14128.91 -> 14826.25 (4.94%)
cvt in affected programs: 1636.23 -> 2333.58 (42.62%)
helped: 0
HURT: 383
HURT stats (abs) min: 0.0625 max: 2.109375 x̄: 1.82 x̃: 2
HURT stats (rel) min: 2.52% max: 162.50% x̄: 43.50% x̃: 46.40%
95% mean confidence interval for cvt value: 1.76 1.88
95% mean confidence interval for cvt %-change: 42.07% 44.93%
Cvt are HURT.
total sfu in shared programs: 7549.31 -> 8601.81 (13.94%)
sfu in affected programs: 758.62 -> 1811.12 (138.74%)
helped: 0
HURT: 383
HURT stats (abs) min: 0.375 max: 5.0 x̄: 2.75 x̃: 3
HURT stats (rel) min: 23.08% max: 266.67% x̄: 136.66% x̃: 150.00%
95% mean confidence interval for sfu value: 2.67 2.83
95% mean confidence interval for sfu %-change: 133.02% 140.29%
Sfu are HURT.
total quadwords in shared programs: 1449928 -> 1479736 (2.06%)
quadwords in affected programs: 96544 -> 126352 (30.88%)
helped: 0
HURT: 382
HURT stats (abs) min: 8.0 max: 96.0 x̄: 78.03 x̃: 88
HURT stats (rel) min: 1.82% max: 100.00% x̄: 31.71% x̃: 34.38%
95% mean confidence interval for quadwords value: 75.63 80.43
95% mean confidence interval for quadwords %-change: 30.67% 32.75%
Quadwords are HURT.
total threads in shared programs: 53556 -> 53479 (-0.14%)
threads in affected programs: 154 -> 77 (-50.00%)
helped: 0
HURT: 77
HURT stats (abs) min: 1.0 max: 1.0 x̄: 1.00 x̃: 1
HURT stats (rel) min: 50.00% max: 50.00% x̄: 50.00% x̃: 50.00%
95% mean confidence interval for threads value: -1.00 -1.00
95% mean confidence interval for threads %-change: -50.00% -50.00%
Threads are HURT.
Bifrost is hit harder, unfortunately:
total instructions in shared programs: 2414877 -> 2468058 (2.20%)
instructions in affected programs: 184585 -> 237766 (28.81%)
helped: 0
HURT: 383
HURT stats (abs) min: 12.0 max: 160.0 x̄: 138.85 x̃: 155
HURT stats (rel) min: 1.52% max: 111.94% x̄: 29.43% x̃: 31.44%
95% mean confidence interval for instructions value: 134.47 143.24
95% mean confidence interval for instructions %-change: 28.42% 30.45%
Instructions are HURT.
total tuples in shared programs: 1927478 -> 1964218 (1.91%)
tuples in affected programs: 133176 -> 169916 (27.59%)
helped: 0
HURT: 383
HURT stats (abs) min: 5.0 max: 113.0 x̄: 95.93 x̃: 107
HURT stats (rel) min: 1.02% max: 87.04% x̄: 28.44% x̃: 30.57%
95% mean confidence interval for tuples value: 92.80 99.05
95% mean confidence interval for tuples %-change: 27.47% 29.41%
Tuples are HURT.
total clauses in shared programs: 354853 -> 359513 (1.31%)
clauses in affected programs: 22918 -> 27578 (20.33%)
helped: 0
HURT: 381
HURT stats (abs) min: 1.0 max: 15.0 x̄: 12.23 x̃: 14
HURT stats (rel) min: 1.14% max: 60.00% x̄: 20.81% x̃: 22.58%
95% mean confidence interval for clauses value: 11.84 12.62
95% mean confidence interval for clauses %-change: 20.13% 21.49%
Clauses are HURT.
total cycles in shared programs: 166542.56 -> 167639.31 (0.66%)
cycles in affected programs: 5012.37 -> 6109.13 (21.88%)
helped: 0
HURT: 329
HURT stats (abs) min: 0.
20833199999999863 max: 4.
666665999999999 x̄: 3.33 x̃: 3
HURT stats (rel) min: 1.05% max: 51.06% x̄: 22.28% x̃: 22.78%
95% mean confidence interval for cycles value: 3.22 3.45
95% mean confidence interval for cycles %-change: 21.45% 23.10%
Cycles are HURT.
total arith in shared programs: 73643 -> 75173.17 (2.08%)
arith in affected programs: 5344.04 -> 6874.21 (28.63%)
helped: 0
HURT: 383
HURT stats (abs) min: 0.
20833199999999863 max: 4.666667 x̄: 4.00 x̃: 4
HURT stats (rel) min: 1.05% max: 97.92% x̄: 29.47% x̃: 31.64%
95% mean confidence interval for arith value: 3.87 4.13
95% mean confidence interval for arith %-change: 28.45% 30.49%
Arith are HURT.
total quadwords in shared programs: 1673974 -> 1701720 (1.66%)
quadwords in affected programs: 111686 -> 139432 (24.84%)
helped: 0
HURT: 383
HURT stats (abs) min: 5.0 max: 84.0 x̄: 72.44 x̃: 81
HURT stats (rel) min: 1.11% max: 78.72% x̄: 25.59% x̃: 27.56%
95% mean confidence interval for quadwords value: 70.16 74.73
95% mean confidence interval for quadwords %-change: 24.74% 26.43%
Quadwords are HURT.
total threads in shared programs: 53655 -> 53590 (-0.12%)
threads in affected programs: 130 -> 65 (-50.00%)
helped: 0
HURT: 65
HURT stats (abs) min: 1.0 max: 1.0 x̄: 1.00 x̃: 1
HURT stats (rel) min: 50.00% max: 50.00% x̄: 50.00% x̃: 50.00%
95% mean confidence interval for threads value: -1.00 -1.00
95% mean confidence interval for threads %-change: -50.00% -50.00%
Threads are HURT.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17266>
Alyssa Rosenzweig [Tue, 2 Aug 2022 14:16:11 +0000 (10:16 -0400)]
pan/bi: Optimize pattern from nir_lower_idiv
This takes advantage of the .i1 modifier on the comparison to get b2i32 "for
free" in typical circumstances, saving an instruction. Will help with an instr
count regression from lower_idiv.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17266>
Alyssa Rosenzweig [Fri, 19 Aug 2022 19:41:29 +0000 (15:41 -0400)]
pan/bi: Optimize bitwise arithmetic of booleans
This is easier to schedule on Bifrost. In theory it's also better on Valhall,
but in practice the CVT unit is too overloaded on Valhall for this to help
at the moment. We can revisit these rules for Valhall in the future where the
Valhall optimizer is more mature and/or Valhall grows a scheduler to balance the
execution units.
total instructions in shared programs: 2415350 -> 2414877 (-0.02%)
instructions in affected programs: 120948 -> 120475 (-0.39%)
helped: 192
HURT: 49
helped stats (abs) min: 1.0 max: 5.0 x̄: 2.89 x̃: 4
helped stats (rel) min: 0.25% max: 4.35% x̄: 0.66% x̃: 0.52%
HURT stats (abs) min: 1.0 max: 3.0 x̄: 1.67 x̃: 1
HURT stats (rel) min: 0.11% max: 7.14% x̄: 1.73% x̃: 0.77%
95% mean confidence interval for instructions value: -2.24 -1.68
95% mean confidence interval for instructions %-change: -0.37% 0.02%
Inconclusive result (%-change mean confidence interval includes 0).
total tuples in shared programs: 1928474 -> 1927478 (-0.05%)
tuples in affected programs: 146482 -> 145486 (-0.68%)
helped: 514
HURT: 73
helped stats (abs) min: 1.0 max: 8.0 x̄: 2.11 x̃: 1
helped stats (rel) min: 0.18% max: 9.52% x̄: 1.35% x̃: 0.76%
HURT stats (abs) min: 1.0 max: 2.0 x̄: 1.23 x̃: 1
HURT stats (rel) min: 0.15% max: 7.14% x̄: 1.07% x̃: 0.76%
95% mean confidence interval for tuples value: -1.85 -1.55
95% mean confidence interval for tuples %-change: -1.19% -0.91%
Tuples are helped.
total clauses in shared programs: 354985 -> 354853 (-0.04%)
clauses in affected programs: 8562 -> 8430 (-1.54%)
helped: 124
HURT: 22
helped stats (abs) min: 1.0 max: 8.0 x̄: 1.24 x̃: 1
helped stats (rel) min: 0.83% max: 7.14% x̄: 2.47% x̃: 1.72%
HURT stats (abs) min: 1.0 max: 1.0 x̄: 1.00 x̃: 1
HURT stats (rel) min: 1.25% max: 20.00% x̄: 5.08% x̃: 4.35%
95% mean confidence interval for clauses value: -1.11 -0.70
95% mean confidence interval for clauses %-change: -1.92% -0.75%
Clauses are helped.
total cycles in shared programs: 166575.48 -> 166542.56 (-0.02%)
cycles in affected programs: 4556.58 -> 4523.67 (-0.72%)
helped: 395
HURT: 65
helped stats (abs) min: 0.
041665999999999315 max: 0.
33333199999999863 x̄: 0.09 x̃: 0
helped stats (rel) min: 0.19% max: 11.11% x̄: 1.42% x̃: 0.81%
HURT stats (abs) min: 0.
041665999999999315 max: 0.
08333400000000069 x̄: 0.05 x̃: 0
HURT stats (rel) min: 0.15% max: 8.33% x̄: 1.21% x̃: 0.83%
95% mean confidence interval for cycles value: -0.08 -0.06
95% mean confidence interval for cycles %-change: -1.22% -0.87%
Cycles are helped.
total arith in shared programs: 73687.88 -> 73643 (-0.06%)
arith in affected programs: 6339 -> 6294.13 (-0.71%)
helped: 570
HURT: 72
helped stats (abs) min: 0.
041665999999999315 max: 0.
3333340000000007 x̄: 0.08 x̃: 0
helped stats (rel) min: 0.19% max: 12.50% x̄: 1.41% x̃: 0.77%
HURT stats (abs) min: 0.
041665999999999315 max: 0.
08333400000000069 x̄: 0.05 x̃: 0
HURT stats (rel) min: 0.15% max: 8.33% x̄: 1.13% x̃: 0.75%
95% mean confidence interval for arith value: -0.08 -0.06
95% mean confidence interval for arith %-change: -1.27% -0.98%
Arith are helped.
total quadwords in shared programs: 1674486 -> 1673974 (-0.03%)
quadwords in affected programs: 117696 -> 117184 (-0.44%)
helped: 424
HURT: 127
helped stats (abs) min: 1.0 max: 6.0 x̄: 1.64 x̃: 1
helped stats (rel) min: 0.19% max: 4.88% x̄: 1.00% x̃: 0.82%
HURT stats (abs) min: 1.0 max: 5.0 x̄: 1.46 x̃: 1
HURT stats (rel) min: 0.15% max: 6.25% x̄: 1.31% x̃: 0.88%
95% mean confidence interval for quadwords value: -1.07 -0.79
95% mean confidence interval for quadwords %-change: -0.58% -0.36%
Quadwords are helped.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17266>
Marek Olšák [Tue, 16 Aug 2022 15:47:47 +0000 (11:47 -0400)]
winsys/amdgpu: change num_rejected_cs to a bool flag
and don't increment the total sum after the first rejection
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17968>
Marek Olšák [Tue, 9 Aug 2022 21:27:18 +0000 (17:27 -0400)]
winsys/amdgpu: flatten huge if and reorder code in amdgpu_cs_submit_ib
This correctly tracks when we get a failure and jump to cleanup.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17968>
Marek Olšák [Tue, 9 Aug 2022 21:04:47 +0000 (17:04 -0400)]
winsys/amdgpu: terminate process on CS rejection when unrobust context is lost
We agreed on this with the kernel team as the most graceful way to deal
with this scenario.
Remove the allow_context_lost use because it's always true there
if num_rejected_cs is true.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17968>
Marek Olšák [Tue, 9 Aug 2022 20:55:41 +0000 (16:55 -0400)]
radeonsi: allow lost context with aux_contexts
We'll terminate the process if a context is lost, so we don't have any
other choice.
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17968>
Marek Olšák [Tue, 9 Aug 2022 17:06:37 +0000 (13:06 -0400)]
radeonsi: rename stop_exec_on_failure -> allow_context_lost
Reviewed-by: Mihai Preda <mhpreda@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17968>
Mike Blumenkrantz [Fri, 19 Aug 2022 17:37:57 +0000 (13:37 -0400)]
Revert "zink: add all format modifiers when adding for dmabuf export"
This reverts commit
247b8f2924b7832d8520e890cff6891217f5a860.
this attempted to work around what is likely a bug in nvidia's modifier
support, namely their refusal to expose LINEAR as a valid modifier for
some bizarre reason
cc: mesa-stable
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18148>
Mike Blumenkrantz [Fri, 19 Aug 2022 17:37:38 +0000 (13:37 -0400)]
Revert "zink: try to reuse swapchain modifier for dmabuf export"
This reverts commit
49efa73ba11c4cacaed0052b984e1fb884cf7600.
this happens to work with mesa (sometimes), but it's going to be
illegal most of the time since swapchain images are treated as though
they are created with OPTIMAL tiling
cc: mesa-stable
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18148>
Sami Kyöstilä [Mon, 15 Aug 2022 10:08:17 +0000 (20:08 +1000)]
intel/ds: Update to Perfetto API v28.0
Perfetto v28.0 changes the naming scheme of generated enum constants.
Update our code to match and roll the version of Perfetto forward
accordingly.
No functional changes.
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18056>
Chia-I Wu [Tue, 16 Aug 2022 19:10:34 +0000 (12:10 -0700)]
turnip: lower the queue priority to 1
To match the default priority of the gallium driver.
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18093>
Chia-I Wu [Tue, 16 Aug 2022 18:08:11 +0000 (11:08 -0700)]
freedreno/pps: improve interaction with turnip
turnip uses priority 0. pps should too (actually, it makes sense to do
so regardless of what turnip does).
turnip is not expected to starve pps, but it does with drm-next for
5.20.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18093>
Alyssa Rosenzweig [Fri, 19 Aug 2022 15:42:46 +0000 (11:42 -0400)]
pan/bi: Test int8/16 -> float32 opts
These are easy, since round modes don't matter.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17857>
Alyssa Rosenzweig [Fri, 19 Aug 2022 15:51:20 +0000 (11:51 -0400)]
pan/bi: Fuse [US][8|16]_TO_F32 ops
This combines nicely with the previous isel change. Now GLSL like
float(int_x >> 24)
will generate a single machine instruction
S8_TO_F32 int_x.b3
Noticed when debugging
KHR-GLES31.core.shader_bitfield_operation.unpackSnorm4x8.0
...but naturally no real workloads care. Helped shaders are from Android games
that appear to have run through a translator, naturally.
total instructions in shared programs: 2674831 -> 2674783 (<.01%)
instructions in affected programs: 11493 -> 11445 (-0.42%)
helped: 31
HURT: 0
helped stats (abs) min: 1.0 max: 3.0 x̄: 1.55 x̃: 1
helped stats (rel) min: 0.16% max: 2.90% x̄: 0.51% x̃: 0.41%
95% mean confidence interval for instructions value: -1.87 -1.22
95% mean confidence interval for instructions %-change: -0.69% -0.33%
Instructions are helped.
total cvt in shared programs: 14128.84 -> 14128.09 (<.01%)
cvt in affected programs: 78.17 -> 77.42 (-0.96%)
helped: 31
HURT: 0
helped stats (abs) min: 0.015625 max: 0.046875 x̄: 0.02 x̃: 0
helped stats (rel) min: 0.36% max: 4.26% x̄: 1.28% x̃: 1.20%
95% mean confidence interval for cvt value: -0.03 -0.02
95% mean confidence interval for cvt %-change: -1.62% -0.94%
Cvt are helped.
total quadwords in shared programs: 1449920 -> 1449840 (<.01%)
quadwords in affected programs: 2184 -> 2104 (-3.66%)
helped: 10
HURT: 0
helped stats (abs) min: 8.0 max: 8.0 x̄: 8.00 x̃: 8
helped stats (rel) min: 2.44% max: 5.88% x̄: 4.11% x̃: 4.76%
95% mean confidence interval for quadwords value: -8.00 -8.00
95% mean confidence interval for quadwords %-change: -5.11% -3.12%
Quadwords are helped.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17857>