Alyssa Rosenzweig
cda1961835
treewide: Also handle struct nir_builder form
...
Via Coccinelle patch:
@def@
typedef bool;
typedef nir_builder;
typedef nir_instr;
typedef nir_def;
identifier fn, instr, intr, x, builder, data;
@@
static fn(struct nir_builder* builder,
-nir_instr *instr,
+nir_intrinsic_instr *intr,
...)
{
(
- if (instr->type != nir_instr_type_intrinsic)
- return false;
- nir_intrinsic_instr *intr = nir_instr_as_intrinsic(instr);
|
- nir_intrinsic_instr *intr = nir_instr_as_intrinsic(instr);
- if (instr->type != nir_instr_type_intrinsic)
- return false;
)
<...
(
-instr->x
+intr->instr.x
|
-instr
+&intr->instr
)
...>
}
@pass depends on def@
identifier def.fn;
expression shader, progress;
@@
(
-nir_shader_instructions_pass(shader, fn,
+nir_shader_intrinsics_pass(shader, fn,
...)
|
-NIR_PASS_V(shader, nir_shader_instructions_pass, fn,
+NIR_PASS_V(shader, nir_shader_intrinsics_pass, fn,
...)
|
-NIR_PASS(progress, shader, nir_shader_instructions_pass, fn,
+NIR_PASS(progress, shader, nir_shader_intrinsics_pass, fn,
...)
)
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Acked-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24852 >
2023-08-24 15:48:02 +00:00
Alyssa Rosenzweig
465b138f01
treewide: Use nir_shader_intrinsic_pass sometimes
...
This converts a lot of trivial passes. Nice boilerplate deletion. Via Coccinelle
patch (with a small manual fix-up for panfrost where coccinelle got confused by
genxml + ninja clang-format squashed in, and for Zink because my semantic patch
was slightly buggy).
@def@
typedef bool;
typedef nir_builder;
typedef nir_instr;
typedef nir_def;
identifier fn, instr, intr, x, builder, data;
@@
static fn(nir_builder* builder,
-nir_instr *instr,
+nir_intrinsic_instr *intr,
...)
{
(
- if (instr->type != nir_instr_type_intrinsic)
- return false;
- nir_intrinsic_instr *intr = nir_instr_as_intrinsic(instr);
|
- nir_intrinsic_instr *intr = nir_instr_as_intrinsic(instr);
- if (instr->type != nir_instr_type_intrinsic)
- return false;
)
<...
(
-instr->x
+intr->instr.x
|
-instr
+&intr->instr
)
...>
}
@pass depends on def@
identifier def.fn;
expression shader, progress;
@@
(
-nir_shader_instructions_pass(shader, fn,
+nir_shader_intrinsics_pass(shader, fn,
...)
|
-NIR_PASS_V(shader, nir_shader_instructions_pass, fn,
+NIR_PASS_V(shader, nir_shader_intrinsics_pass, fn,
...)
|
-NIR_PASS(progress, shader, nir_shader_instructions_pass, fn,
+NIR_PASS(progress, shader, nir_shader_intrinsics_pass, fn,
...)
)
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Acked-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24852 >
2023-08-24 15:48:02 +00:00
Mauro Rossi
ef6725a5f4
hasvk/android: remove numFds check
...
Change required for compatibility with minigbm gralloc4
due to gralloc handle having DRV_MAX_FDS = (DRV_MAX_PLANES + 1)
https://android.googlesource.com/platform/external/minigbm/+/refs/tags/android-13.0.0_r18/cros_gralloc/cros_gralloc_handle.h#14
Cc: "22.3" mesa-stable
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7807
Reviewed-by: Roman Stratiienko <r.stratiienko@gmail.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20231 >
2023-08-24 11:07:12 +00:00
Mauro Rossi
143d417fcc
anv/android: remove numFds check
...
Change required for compatibility with minigbm gralloc4
due to gralloc handle having DRV_MAX_FDS = (DRV_MAX_PLANES + 1)
https://android.googlesource.com/platform/external/minigbm/+/refs/tags/android-13.0.0_r18/cros_gralloc/cros_gralloc_handle.h#14
Cc: "22.2" "22.3" mesa-stable
Reviewed-by: Roman Stratiienko <r.stratiienko@gmail.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20231 >
2023-08-24 11:07:12 +00:00
Chris Spencer
6a4e9b55e4
anv: Don't reject Android image format if external props not supplied
...
anv_GetPhysicalDeviceImageFormatProperties2 returns 'not supported' if an
Android hardware buffer external memory handle type is specified, but no
external image format properties output struct is supplied. This struct is
optional, so we should populate it if present, but return successfully
either way.
This fixes an error when using ANV with hwui, which otherwise prevents the
system from booting.[1]
[1] https://cs.android.com/android/platform/superproject/main/+/main:frameworks/base/libs/hwui/renderthread/VulkanSurface.cpp;l=271;drc=ad3fb95aa2fe0be59d3e991ddc883592ab5542bc
Signed-off-by: Chris Spencer <spencercw@gmail.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24844 >
2023-08-24 10:26:09 +00:00
Yonggang Luo
0b84e38684
intel/brw: use 4 instead of MAX_VERTEX_STREAMS to avoid #include "mesa/main/config.h"
...
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com >
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24824 >
2023-08-24 02:54:08 +00:00
Kenneth Graunke
08fc4603dd
intel/fs: Dump IR for pre-RA scheduler modes in DEBUG_OPTIMIZER
...
This lets us more easily compare and contrast the various scheduling
options that the compiler considered.
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24707 >
2023-08-23 21:34:38 +00:00
Kenneth Graunke
07f2ad32e4
intel/fs: Pick the lowest register pressure schedule when spilling
...
We try various pre-RA scheduler modes and see if any of them allow
us to register allocate without spilling. If all of them spill,
however, we left it on the last mode: LIFO. This is unfortunately
sometimes significantly worse than other modes (such as "none").
This patch makes us instead select the pre-RA scheduling mode that
gives the lowest register pressure estimate, if none of them manage
to avoid spilling. The hope is that this scheduling will spill the
least out of all of them.
fossil-db stats (on Alchemist) speak for themselves:
Totals:
Instrs: 197297092 -> 195326552 (-1.00%); split: -1.02%, +0.03%
Cycles: 14291286956 -> 14303502596 (+0.09%); split: -0.55%, +0.64%
Spill count: 190886 -> 129204 (-32.31%); split: -33.01%, +0.70%
Fill count: 361408 -> 225038 (-37.73%); split: -39.17%, +1.43%
Scratch Memory Size: 12935168 -> 10868736 (-15.98%); split: -16.08%, +0.10%
Totals from 1791 (0.27% of 668386) affected shaders:
Instrs: 7628929 -> 5658389 (-25.83%); split: -26.50%, +0.67%
Cycles: 719326691 -> 731542331 (+1.70%); split: -10.95%, +12.65%
Spill count: 110627 -> 48945 (-55.76%); split: -56.96%, +1.20%
Fill count: 221560 -> 85190 (-61.55%); split: -63.89%, +2.34%
Scratch Memory Size: 4471808 -> 2405376 (-46.21%); split: -46.51%, +0.30%
Improves performance when using XeSS in Cyberpunk 2077 by 90% on A770.
Improves performance of Borderlands 3 by 1.54% on A770.
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24707 >
2023-08-23 21:34:38 +00:00
Kenneth Graunke
158ac265df
intel/fs: Make helpers for saving/restoring instruction order
...
This moves a bit of code out of a large function, but also lets us reuse
it a few extra places in the next commit.
I opted to stop using ralloc here since this is short-lived data that
doesn't need to stick around for the rest of the compile, and it's easy
enough to free.
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24707 >
2023-08-23 21:34:38 +00:00
Kenneth Graunke
2dd56921c9
intel/fs: Index scheduler mode string table by mode enum
...
pre_modes[] is an array with the modes ordered in our desired
preference. scheduler_mode_name[] was also in that order, and the two
had to be kept in sync. This is a little silly; we should just have
a mode enum -> string table and look it up via the enum.
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24707 >
2023-08-23 21:34:38 +00:00
Kenneth Graunke
7eba19245d
intel/compiler: Move SCHEDULE_NONE handling into schedule_instructions()
...
I'm going to introduce another call site for this function, and just
handling SCHEDULE_NONE in the scheduler itself makes more sense than
duplicating the logic.
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24707 >
2023-08-23 21:34:38 +00:00
Kenneth Graunke
743fd60bea
intel/fs: Account for payload GRFs when calculating register pressure
...
The register pressure analysis I wrote in 2013 only considered VGRFs,
and not other GRFs, such as payload registers and push constants. We
need to consider those too, because payload registers definitely occupy
space and add to pressure.
In 2015, Connor already made the scheduler account for this, so the only
real use for this is in shader statistic dumps and optimizer printouts.
But we should make it more accurate. (We will use it in more places
shortly, a few commits from now.)
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24707 >
2023-08-23 21:34:38 +00:00
Chris Spencer
bda4eb18dd
anv: Advertise Vulkan 1.3 on Android 13
...
Older versions of Android rejected newer versions of Vulkan,[1] but Android
13 devices are 'strongly recommended' to support Vulkan 1.3.[2]
[1] https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4781
[2] https://source.android.com/docs/compatibility/13/android-13-cdd#7142_vulkan
Signed-off-by: Chris Spencer <spencercw@gmail.com >
Reviewed-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24816 >
2023-08-23 14:31:26 +00:00
Sviatoslav Peleshko
9865e5dff4
anv: Do fast clear color initialization more delicately
...
Fixes: b4198e79 ("anv/cmd_buffer: Initalize the clear color struct for CNL+")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9464
Signed-off-by: Sviatoslav Peleshko <sviatoslav.peleshko@globallogic.com >
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24768 >
2023-08-23 12:55:08 +00:00
Sviatoslav Peleshko
caa5c23e48
intel/isl: Don't over-allocate CLEAR_COLOR size to use whole cache line
...
At the time this was added to fix some test failures. But it seems that
the failures were happening due to missing cache flushes, so
this extra space is no longer neccessary.
Fixes: 37b4eacc ("intel/isl: Resize clear color buffer to full cacheline")
Signed-off-by: Sviatoslav Peleshko <sviatoslav.peleshko@globallogic.com >
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24768 >
2023-08-23 12:55:08 +00:00
Chris Spencer
280281f8f7
anv/android: Add support for AHARDWAREBUFFER_FORMAT_YV12
...
The default MediaCodec software video decoder returns frames in this
format.
Signed-off-by: Chris Spencer <spencercw@gmail.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24388 >
2023-08-23 09:56:03 +00:00
Chris Spencer
35fddccf3f
anv/android: Fix importing hardware buffers with planar formats
...
Currently, we try to fetch the color aspect of the format and convert that
to an ISL format, which is then used to convert the pixel stride to bytes.
This does not work with planar formats because they don't have a color
aspect, and the planes can be of different sizes anyway, so may not have
the same byte stride. Change to calculate the stride individually for each
plane.
Signed-off-by: Chris Spencer <spencercw@gmail.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24388 >
2023-08-23 09:56:03 +00:00
Sagar Ghuge
839b03cc06
blorp: Drop unnecessary assertions in blorp_can_hiz_clear_depth
...
We already checks for the alignment and the multislice surface, we don't
need to add assertions around those two.
fixes: 37fcbb375c ("blorp: Disable unaligned partial HIZ fast clears for HIZ_CCS too")
closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9684
Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com >
Tested-by: Mark Janes <markjanes@swizzler.org >
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24837 >
2023-08-23 00:35:07 +00:00
Emma Anholt
5bd0750921
intel/fs: Simplify compute_start_end().
...
Now that we have moved the screening up, we can simplify the code. No
change in shader-db steam performance, n=10.
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24702 >
2023-08-22 23:34:30 +00:00
Emma Anholt
2b01246f49
intel/fs: Move the defin[]/defout[] screening up to livein[]/liveout[] setup.
...
This keeps us from having to run the loop to propagate up quite so much.
steam shader-db time -1.86356% +/- 0.941498% (n=10). There's a small
scheduling effect, since previously the scheduler wasn't considering
defin/defout:
cycles helped: shaders/closed/steam/amnesia-the-dark-descent/high/241.shader_test FS SIMD16: 11428 -> 11422 (-0.05%) (scheduled: scheduled)
cycles helped: shaders/humus-volumetricfogging2/1.shader_test FS SIMD32: 13832 -> 13800 (-0.23%) (scheduled: scheduled)
cycles helped: shaders/tesseract/479.shader_test FS SIMD32: 9330 -> 8644 (-7.35%) (scheduled: scheduled)
cycles HURT: shaders/robclark-shaders/android/angle/aztec_ruins/36.shader_test FS SIMD32: 7870 -> 7940 (0.89%) (scheduled: scheduled)
cycles HURT: shaders/robclark-shaders/gfxbench5/gl_5_high_off/57.shader_test FS SIMD32: 7870 -> 7940 (0.89%) (scheduled: scheduled)
cycles HURT: shaders/robclark-shaders/gfxbench5/gl_5_normal_off/54.shader_test FS SIMD32: 7870 -> 7940 (0.89%) (scheduled: scheduled)
cycles HURT: shaders/robclark-shaders/android/angle/aztec_ruins/30.shader_test FS SIMD32: 8726 -> 8808 (0.94%) (scheduled: scheduled)
cycles HURT: shaders/robclark-shaders/gfxbench5/gl_5_high_off/51.shader_test FS SIMD32: 8726 -> 8808 (0.94%) (scheduled: scheduled)
cycles HURT: shaders/robclark-shaders/gfxbench5/gl_5_normal_off/48.shader_test FS SIMD32: 8726 -> 8808 (0.94%) (scheduled: scheduled)
cycles HURT: shaders/robclark-shaders/gfxbench5/gl_4_off/129.shader_test TCS SIMD8: 3911 -> 3979 (1.74%) (scheduled: scheduled)
cycles HURT: shaders/robclark-shaders/gfxbench5/gl_4_off/109.shader_test TCS SIMD8: 3911 -> 3979 (1.74%) (scheduled: scheduled)
total cycles in shared programs: 313096438 -> 313096306 (<.01%)
cycles in affected programs: 92200 -> 92068 (-0.14%)
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24702 >
2023-08-22 23:34:30 +00:00
Emma Anholt
ed4e1becea
intel/fs: Move defin/defout setup to the start of the loop.
...
Refactor for the next commit.
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24702 >
2023-08-22 23:34:30 +00:00
Eric Engestrom
566c919df8
ci/deqp: backport fix for dEQP-EGL.functional.wide_color.*_888_colorspace_*
...
Signed-off-by: Eric Engestrom <eric@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24808 >
2023-08-22 18:12:08 +00:00
Emma Anholt
37fcbb375c
blorp: Disable unaligned partial HIZ fast clears for HIZ_CCS too.
...
Fixes MSAA scissored fast clears under zink and ANGLE.
Fixes: e488773b29 ("anv: Fast clear depth/stencil surface in vkCmdClearAttachments")
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com >
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24225 >
2023-08-22 16:34:52 +00:00
Tapani Pälli
c9abcddad4
anv: implement a dummy depth flush for Wa_14016712196
...
Emit depth flush after state that sends implicit depth flush. These
states are:
3DSTATE_HIER_DEPTH_BUFFER
3DSTATE_STENCIL_BUFFER
3DSTATE_DEPTH_BUFFER
3DSTATE_CPSIZE_CONTROL_BUFFER
Signed-off-by: Tapani Pälli <tapani.palli@intel.com >
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24689 >
2023-08-22 12:49:37 +00:00
Georg Lehmann
9cf6984200
nir: unify lower_find_msb with has_{find_msb_rev,uclz}
...
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev >
Acked-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24662 >
2023-08-22 12:08:37 +00:00
Georg Lehmann
2ac7e6614a
nir: unify lower_bitfield_extract with has_bfe
...
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev >
Acked-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24662 >
2023-08-22 12:08:37 +00:00
Georg Lehmann
34c3f81614
nir: unify lower_bitfield_insert with has_{bfm,bfi,bitfield_select}
...
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev >
Acked-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24662 >
2023-08-22 12:08:37 +00:00
José Roberto de Souza
a425ae17ac
anv: Update Wa_16014390852 for MTL
...
On MTL Wa_16014390852 is fixed on B0 stepping so we can't use a macro
check anymore for this workaround.
cc: mesa-stable
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24812 >
2023-08-22 06:33:56 +00:00
David Heidelberg
6079c3ca49
ci: disable Material Testers.x86_64_2020.04.08_13.38_frame799.rdc trace
...
This change will be revert as soon, as Collabora proxy gets fixed.
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24819 >
2023-08-21 22:31:21 +00:00
Rohan Garg
8849e1e3a6
anv: emitting 3DSTATE_PRIMITIVE_REPLICATION is required on Gen12+
...
This change helps fix the following tests on future platforms:
- func.multiview
- dEQP-VK.fragment_shading_rate.renderpass2.monolithic.multiviewsrlayered.dynamic.attachment.noshaderrate.keep.replace.1x1.samples1.vs
- anything else that uses multiview
Signed-off-by: Rohan Garg <rohan.garg@intel.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24746 >
2023-08-18 11:36:45 +00:00
Faith Ekstrand
b5d6b7c402
nir: Drop most uses if nir_instr_rewrite_src()
...
Generated by the following semantic patch:
@@
expression I, S, D;
@@
-nir_instr_rewrite_src(I, S, nir_src_for_ssa(D));
+nir_src_rewrite(S, D);
Acked-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24729 >
2023-08-18 01:00:15 +00:00
Faith Ekstrand
de063a1481
nir: Drop most uses of nir_instr_rewrite_src_ssa()
...
Generated with the following semantic patch:
@@
expression I, S, D;
@@
-nir_instr_rewrite_src_ssa(I, S, D);
+nir_src_rewrite(S, D);
Acked-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24729 >
2023-08-18 01:00:15 +00:00
Sagar Ghuge
20db03d32f
anv,hasvk: drop unnecessary DEBUG_NO_CCS/NO_HIZ checks
...
Now isl_surf_supports_ccs helper handles DEBUG_NO_CCS check and
isl_surf_get_hiz_surf handles DEBUG_NO_HIZ, so we don't
need to check it everywhere.
Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com >
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24731 >
2023-08-17 23:49:34 +00:00
Sagar Ghuge
b3affef252
intel/isl: Enable INTEL_DEBUG=noccs/nohiz in ISL helpers
...
Let's enable INTEL_DEBUG=noccs in isl_surf_supports_ccs helper and
INTEL_DEBUG=nohiz in isl_surf_get_hiz_surf helper.
Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com >
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24731 >
2023-08-17 23:49:34 +00:00
Kenneth Graunke
d7daf78f62
intel/compiler: Respect NIR_DEBUG_PRINT_INTERNAL for DEBUG_OPTIMIZER
...
If the NIR_DEBUG_PRINT_INTERNAL flag is not set, don't print debugging
information for internal shaders in INTEL_DEBUG=optimizer dumps.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24684 >
2023-08-17 18:19:53 +00:00
Tapani Pälli
71a2d651c1
anv: refactor batch_set_preemption to use batch_emit_pipe_control
...
This makes it easier to hook workarounds for this pipe control.
Signed-off-by: Tapani Pälli <tapani.palli@intel.com >
Reviewed-by: Rohan Garg <rohan.garg@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24690 >
2023-08-17 16:07:59 +00:00
David Heidelberg
3a4bdf26e6
ci: remove LAVA prefix from variables which can be used also elsewhere
...
At least these two can be easily used in bare-metal or Labgrid setups.
Currently I already have MR for implementing these for Labgrid.
Reviewed-by: Guilherme Gallo <guilherme.gallo@collabora.com >
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24665 >
2023-08-17 13:25:46 +00:00
Tapani Pälli
98eecece9b
anv: remove assert, size is asserted in the runtime
...
Otherwise gets hit on Android CTS tests.
Reported-by: Chris Spencer <spencercw@gmail.com >
Signed-off-by: Tapani Pälli <tapani.palli@intel.com >
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24722 >
2023-08-17 08:36:15 +00:00
Matt Turner
d142c845d0
Revert "intel/fs: only avoid SIMD32 if strictly inferior in throughput"
...
This reverts commit 6b494745be .
The logic is not entirely correct: the comparison is between two
static-analysis estimates of a dynamic system with variables that aren't
captured by the shader source, so using ">" will always have greater potential
to cause regressions whenever the performance difference between the two builds
is something not captured by the static model, no matter how much the model is
improved.
Reference: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9262
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24615 >
2023-08-16 14:56:15 +00:00
José Roberto de Souza
f7e39c6f85
intel/isl: Remove Wa_22011186057
...
This is a ADL-P workaround of a pre-production stepping, with RPL-P
already being sold we can remove this workaround.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24699 >
2023-08-15 18:47:36 +00:00
José Roberto de Souza
4c06c736c5
intel/isl: Remove unknown workaround
...
The way this workaround is implemented, it is being applied to all
gfx 12 platforms(TGL, ADL, RKL, RPL, DG1, DG2 and MTL) but it was
supposed to be fixed in TGL B0.
Unfortunately I did not found any workaround number that would match it.
But as all released platforms don't ship to customers with revision == 0
this workaround was never being applied and can be safely removed.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24699 >
2023-08-15 18:47:36 +00:00
Faith Ekstrand
43be4129d2
nir: s/live_ssa_def/live_def/
...
Generated mostly with sed:
sed -i -e 's/live_ssa_def/live_def/g' src/compiler/nir/nir.h src/compiler/nir/*.c
Plus three fixups in various Intel drivers.
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24703 >
2023-08-15 17:44:27 +00:00
Faith Ekstrand
b781dd6200
nir s/nir_get_ssa_scalar/nir_get_scalar/
...
Generated with sed:
sed -i -e 's/nir_get_ssa_scalar/nir_get_scalar/g' src/**/*.h src/**/*.c src/**/*.cpp
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24703 >
2023-08-15 17:44:27 +00:00
Faith Ekstrand
65b6ac8aa4
nir: Rename nir_instr_type_ssa_undef to nir_instr_type_undef
...
We already renamed the type, we just need to rename the enum and the
casting helper functions.
Generated with sed:
sed -i -e 's/nir_instr_type_ssa_undef/nir_instr_type_undef/g' src/**/*.h src/**/*.c src/**/*.cpp
sed -i -e 's/nir_instr_as_ssa_undef/nir_instr_as_undef/g' src/**/*.h src/**/*.c src/**/*.cpp
and two tiny whitespace fixups in lima.
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24703 >
2023-08-15 17:44:27 +00:00
Vinson Lee
d0f4333fca
intel/decoder: Fix memory leak on error path
...
Fix defect reported by Coverity Scan.
Resource leak (RESOURCE_LEAK)
leaked_storage: Variable text_data going out of scope leaks the storage it points to.
Fixes: b4c8d2dc45 ("intel/decoder: Add intel_spec_load_common()")
Signed-off-by: Vinson Lee <vlee@freedesktop.org >
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24659 >
2023-08-14 23:42:58 -07:00
Faith Ekstrand
eb23ce91b5
vulkan/format: Use correct swizzle for 1-plane YCbCr formats
...
VK_FORMAT_G8B8G8R8_422_UNORM and VK_FORMAT_B8G8R8G8_422_UNORM already
place the luminance channel in the green component which is where we NIR
lowering code for ycbcr expects it. Set an RGBA swizzle in the common
format table and make it the driver's responsibility to re-map the
formats as needed for their hardware.
The only Vulkan drivers affected by this change are the Intel drivers
and lavapipe. None of NVK, RADV, and v3dv support these formats yet and
Turnip has its own lowering that doesn't rely on the YCbCr format table
in util/vk_format.c.
Reviewed-by: Dave Airlie <airlied@redhat.com >
Reviewed-by: Roland Scheidegger <sroland@vmware.com >
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24619 >
2023-08-14 23:44:19 +00:00
Faith Ekstrand
b9870275b1
anv: Disable CCS_E for ISL_FORMAT_YCRCB_*
...
We're about to start using YCRCB_NORMAL and YCRCB_SWAPUV for 8-bit
interleaved YCbCr and, while ISL claims CCS_E support, it's not well
tested and we don't think it's working yet for all of ANV's use-cases.
Disable it for now in ANV and only for YUV formats.
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24619 >
2023-08-14 23:44:19 +00:00
Faith Ekstrand
0e33bb56a4
blorp: Use R8G8_UINT for YCRCB_* formats with CCS
...
BLORP uses the get_ccs_compatible_copy_format() based on whether or not
ISL claims the format supports CCS_E, not whether or not CCS_E is used
on the image. This is probably a good thing as it improves consistency.
However, it means that we need CCS-compatible formats for YCRCB_*
formats even if we never use them with CCS_E enabled. In practice,
these do actually seem to work according to the Vulkan CTS but coverage
is likely far less than perfect.
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24619 >
2023-08-14 23:44:19 +00:00
Jordan Justen
c1a0bdae1c
intel/genxml: Update xml with gen_sort_tags.py output
...
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Dylan Baker <dylan@pnwbakers>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24605 >
2023-08-14 23:09:36 +00:00
Jordan Justen
549540ca7c
intel/genxml: Add final newline to output when saving xml
...
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Dylan Baker <dylan@pnwbakers>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24605 >
2023-08-14 23:09:36 +00:00