platform/upstream/mesa.git
2 years agollvmpipe: asst. clean-up and add comments in lp_state_fs.h
Brian Paul [Tue, 7 Jun 2022 15:34:44 +0000 (09:34 -0600)]
llvmpipe: asst. clean-up and add comments in lp_state_fs.h

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: asst. clean-ups in lp_scene.h
Brian Paul [Fri, 20 May 2022 19:32:50 +0000 (13:32 -0600)]
llvmpipe: asst. clean-ups in lp_scene.h

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: asst. clean-ups in lp_linear.c
Brian Paul [Tue, 17 May 2022 04:02:00 +0000 (22:02 -0600)]
llvmpipe: asst. clean-ups in lp_linear.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: asst. clean-ups in lp_rast.c
Brian Paul [Fri, 20 May 2022 19:08:48 +0000 (13:08 -0600)]
llvmpipe: asst. clean-ups in lp_rast.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: fix comment typo in lp_linear_fastpath.c
Brian Paul [Fri, 20 May 2022 19:07:22 +0000 (13:07 -0600)]
llvmpipe: fix comment typo in lp_linear_fastpath.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: asst. clean-ups in lp_rast_linear.c
Brian Paul [Fri, 20 May 2022 18:47:29 +0000 (12:47 -0600)]
llvmpipe: asst. clean-ups in lp_rast_linear.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: asst. clean-up in lp_state_derived.c
Brian Paul [Fri, 20 May 2022 18:35:30 +0000 (12:35 -0600)]
llvmpipe: asst. clean-up in lp_state_derived.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agogallivm: add const qualifier in lp_bld_nir_soa.c
Brian Paul [Thu, 19 May 2022 03:02:28 +0000 (21:02 -0600)]
gallivm: add const qualifier in lp_bld_nir_soa.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agogallivm: clean-up in lp_bld_nir.h
Brian Paul [Thu, 19 May 2022 02:59:14 +0000 (20:59 -0600)]
gallivm: clean-up in lp_bld_nir.h

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agogallivm: cleanup lp_bld_arit.c
Brian Paul [Tue, 17 May 2022 15:55:13 +0000 (09:55 -0600)]
gallivm: cleanup lp_bld_arit.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agogallivm: asst. clean-ups in lp_bld_type.[ch]
Brian Paul [Tue, 17 May 2022 15:28:45 +0000 (09:28 -0600)]
gallivm: asst. clean-ups in lp_bld_type.[ch]

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: asst. clean-ups in lp_state_setup.c
Brian Paul [Tue, 17 May 2022 04:10:42 +0000 (22:10 -0600)]
llvmpipe: asst. clean-ups in lp_state_setup.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: asst. clean-ups in lp_setup.c
Brian Paul [Tue, 7 Jun 2022 21:31:30 +0000 (15:31 -0600)]
llvmpipe: asst. clean-ups in lp_setup.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agollvmpipe: asst. clean-ups in lp_linear_fastpath.c
Brian Paul [Tue, 7 Jun 2022 21:30:47 +0000 (15:30 -0600)]
llvmpipe: asst. clean-ups in lp_linear_fastpath.c

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agogallivm: asst. clean-ups in lp_bld_sample.h
Brian Paul [Tue, 7 Jun 2022 21:57:49 +0000 (15:57 -0600)]
gallivm: asst. clean-ups in lp_bld_sample.h

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agogallivm: whitespace fixes in lp_bld_tgsi.h
Brian Paul [Tue, 7 Jun 2022 21:57:30 +0000 (15:57 -0600)]
gallivm: whitespace fixes in lp_bld_tgsi.h

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agogallivm: assorted clean-ups in lp_bld_nir_aos.c
Brian Paul [Mon, 16 May 2022 21:56:43 +0000 (15:56 -0600)]
gallivm: assorted clean-ups in lp_bld_nir_aos.c

Whitespace fixes.  Wrap lines to 78 chars.  Add const qualifiers, etc.

Signed-off-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16937>

2 years agodocs/zink: correct requirement for tbos
Erik Faye-Lund [Tue, 14 Jun 2022 06:46:05 +0000 (08:46 +0200)]
docs/zink: correct requirement for tbos

This requirement is for ARB_texture_buffer_object_rgb32, which obviously
needs the UNIFORM_TEXEL_BUFFER bit, not SAMPLED_IMAGE.

Fixes: c3d7de47cd6 ("docs/zink: add GL 4.0 requirements")
Fixes: 6b38907b7f7 ("zink: fix feature requirement")
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17024>

2 years agoci: Building spirv-to-dxil on both mingw and debian/x64
Yonggang Luo [Sat, 30 Apr 2022 04:23:11 +0000 (12:23 +0800)]
ci: Building spirv-to-dxil on both mingw and debian/x64

debian/i386 needs cross compile of `DirectX-Headers`, so just enable spirv-to-dxil on debian/x64

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agomicrosoft/spirv_to_dxil: Fixes maybe-uninitialized compiling error in dxil_spirv_nir.c
Yonggang Luo [Sat, 7 May 2022 01:59:44 +0000 (09:59 +0800)]
microsoft/spirv_to_dxil: Fixes maybe-uninitialized compiling error in dxil_spirv_nir.c

Fixes following errors:
../src/microsoft/spirv_to_dxil/dxil_spirv_nir.c
In file included from ../src/compiler/nir/nir_builder.h:365,
                 from ../src/microsoft/compiler/dxil_nir.h:29,
                 from ../src/microsoft/spirv_to_dxil/dxil_spirv_nir.c:28:
../src/microsoft/spirv_to_dxil/dxil_spirv_nir.c: In function 'dxil_spirv_nir_passes':
src/compiler/nir/nir_builder_opcodes.h:1321:11: error: 'dyn_yz_flip_mask' may be used uninitialized in this function [-Werror=maybe-uninitialized]
 1321 |    return nir_build_alu2(build, nir_op_iand, src0, src1);
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/microsoft/spirv_to_dxil/dxil_spirv_nir.c:290:59: note: 'dyn_yz_flip_mask' was declared here
  290 |    nir_ssa_def *y_flip_mask = NULL, *z_flip_mask = NULL, *dyn_yz_flip_mask;
      |                                                           ^~~~~~~~~~~~~~~~

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agomicrosoft/clc: Add missing void to no-parameter function signature
Yonggang Luo [Sat, 7 May 2022 01:47:32 +0000 (09:47 +0800)]
microsoft/clc: Add missing void to no-parameter function signature

Fixes this warning:
../../src/microsoft/clc/clc_compiler.c:1218:10: error: no previous prototype for 'clc_compiler_get_version' [-Werror=missing-prototypes]
 1218 | uint64_t clc_compiler_get_version()
      |          ^~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agomicrosoft/clc: Delete unused local variables
Yonggang Luo [Mon, 13 Jun 2022 18:26:53 +0000 (02:26 +0800)]
microsoft/clc: Delete unused local variables

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agomicrosoft/spirv_to_dxil: Delete unused local variable
Yonggang Luo [Mon, 13 Jun 2022 18:24:00 +0000 (02:24 +0800)]
microsoft/spirv_to_dxil: Delete unused local variable

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agodxil: Fixes warning about comparing different enum value and enum literal
Yonggang Luo [Sat, 7 May 2022 01:31:20 +0000 (09:31 +0800)]
dxil: Fixes warning about comparing different enum value and enum literal

warnings:
../../src/microsoft/spirv_to_dxil/spirv_to_dxil.c: In function 'spirv_to_dxil':
../../src/microsoft/spirv_to_dxil/spirv_to_dxil.c:101:14: warning: comparison between 'dxil_spirv_shader_stage' and 'enum <anonymous>' [-Wenum-compare]
  101 |    if (stage == MESA_SHADER_NONE || stage == MESA_SHADER_KERNEL)
      |              ^~
../../src/microsoft/spirv_to_dxil/spirv_to_dxil.c:101:43: warning: comparison between 'dxil_spirv_shader_stage' and 'enum <anonymous>' [-Wenum-compare]
  101 |    if (stage == MESA_SHADER_NONE || stage == MESA_SHADER_KERNEL)
      |                                           ^~

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agodxil: Sync dxil_spirv_shader_stage with gl_shader_stage
Yonggang Luo [Sat, 30 Apr 2022 09:29:19 +0000 (17:29 +0800)]
dxil: Sync dxil_spirv_shader_stage with gl_shader_stage

Add STATIC_ASSERT to guard `dxil_spirv_shader_stage` and `gl_shader_stage`
to be same for each enum value.

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agodxil: Fixes compiling dxcapi.h with mingw.
Yonggang Luo [Fri, 29 Apr 2022 20:25:04 +0000 (04:25 +0800)]
dxil: Fixes compiling dxcapi.h with mingw.

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Acked-by: Jesse Natalie <jenatali@microsoft.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agomicrosoft/compiler: Fix error from double extern
Yonggang Luo [Tue, 14 Jun 2022 03:05:11 +0000 (11:05 +0800)]
microsoft/compiler: Fix error from double extern

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agomicrosoft/compiler: Include stddef.h before using size_t
Yonggang Luo [Fri, 29 Apr 2022 21:00:59 +0000 (05:00 +0800)]
microsoft/compiler: Include stddef.h before using size_t

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16671>

2 years agoRevert "winsys/amdgpu: use AMDGPU_IB_FLAG_PREAMBLE for the CS preamble on gfx10+"
Pierre-Eric Pelloux-Prayer [Tue, 14 Jun 2022 15:27:47 +0000 (17:27 +0200)]
Revert "winsys/amdgpu: use AMDGPU_IB_FLAG_PREAMBLE for the CS preamble on gfx10+"

This reverts commit 8edafaa25c5d649af6c016a61383d784a1ebb078.

This fixes hangs on Navi21.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17032>

2 years agoradeonsi: use helpers to access si_screen::aux_context
Pierre-Eric Pelloux-Prayer [Tue, 14 Jun 2022 14:37:20 +0000 (16:37 +0200)]
radeonsi: use helpers to access si_screen::aux_context

This avoids to mistakenly use the context without locking it first.

The aux_context_lock needs to become a recursive one now, since
si_texture_get_handle can call si_reallocate_texture_inplace which
uses resource_create which may use the aux_context too.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6666
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17032>

2 years agoradeonsi: add helper to use si_screen::aux_context
Pierre-Eric Pelloux-Prayer [Tue, 14 Jun 2022 14:35:49 +0000 (16:35 +0200)]
radeonsi: add helper to use si_screen::aux_context

This context needs to be locked before usage, and flushed after.
If it's forgotten, radeonsi may crash (eg #6666).

To avoid this kind of error, introduce 2 helpers.

cc: mesa-stable

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17032>

2 years agoanv, iris: Enable compute engine with INTEL_COMPUTE_CLASS=1
Jordan Justen [Wed, 17 Nov 2021 20:08:25 +0000 (12:08 -0800)]
anv, iris: Enable compute engine with INTEL_COMPUTE_CLASS=1

If this environment variable is set, then a detected compute engine
will be used as described in docs/envvars.rst.

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14395>

2 years agoanv, iris: Add support for I915_ENGINE_CLASS_COMPUTE
Jordan Justen [Tue, 14 Aug 2018 09:34:16 +0000 (02:34 -0700)]
anv, iris: Add support for I915_ENGINE_CLASS_COMPUTE

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14395>

2 years agoanv: Move STATE_BASE_ADDRESS programming into init_common_queue_state()
Jordan Justen [Tue, 3 May 2022 22:09:29 +0000 (15:09 -0700)]
anv: Move STATE_BASE_ADDRESS programming into init_common_queue_state()

This is now needed following Ken's 8831cb38aa9.

Ref: 8831cb38aa9 ("anv: Stop updating STATE_BASE_ADDRESS on XeHP")
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14395>

2 years agoanv: Add support for I915_ENGINE_CLASS_COMPUTE in init_device_state()
Jordan Justen [Tue, 14 Aug 2018 09:34:16 +0000 (02:34 -0700)]
anv: Add support for I915_ENGINE_CLASS_COMPUTE in init_device_state()

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14395>

2 years agointel/gem: Add support for I915_ENGINE_CLASS_COMPUTE
Jordan Justen [Tue, 14 Aug 2018 09:34:16 +0000 (02:34 -0700)]
intel/gem: Add support for I915_ENGINE_CLASS_COMPUTE

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14395>

2 years agodrm-uapi/i915_drm.h: Update from drm-next (2022-05-06)
Jordan Justen [Fri, 25 Jun 2021 08:39:22 +0000 (01:39 -0700)]
drm-uapi/i915_drm.h: Update from drm-next (2022-05-06)

git://anongit.freedesktop.org/drm/drm 98bcaafd7fb06647529227561ee72e37d3f00ff0

This defines I915_ENGINE_CLASS_COMPUTE to access the compute engine
when available.

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14395>

2 years agoci: fix passing down MESA_LOADER_DRIVER_OVERRIDE for zink-anv-tgl
Samuel Pitoiset [Fri, 10 Jun 2022 15:22:10 +0000 (17:22 +0200)]
ci: fix passing down MESA_LOADER_DRIVER_OVERRIDE for zink-anv-tgl

zink-anv-tgl wasn't using Zink at all because this variable was missing
and then not passed to the runners...

This introduces a list of failures for Zink/Anv and also few tests
are skipped because they take too long (> 60s).

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Martin Roukala <martin.roukala@mupuf.org>
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17031>

2 years agoanv: don't expose EXT_border_color_swizzle on gfx7
Lionel Landwerlin [Tue, 14 Jun 2022 10:16:08 +0000 (13:16 +0300)]
anv: don't expose EXT_border_color_swizzle on gfx7

This requires EXT_custom_border_color which isn't supported on gfx7.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Fixes: fbcf65bfea52 ("anv: VK_EXT_border_color_swizzle")
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17025>

2 years agogallium: disable hardware select for crocus
Qiang Yu [Fri, 10 Jun 2022 02:43:03 +0000 (10:43 +0800)]
gallium: disable hardware select for crocus

piglit select tests fail, so add a gallium cap to disable
for crocus explicitly.

crocus may choose to enable hardware select only for GPU
SKU which tested to be OK again.

Fixes: 6489af145ca ("mesa: enable HardwareAcceleratedSelect")
Closes: #6644

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16955>

2 years agoswrast_kms: use swkmsDRI2Extension instead of driDRI2Extension
Alexander Kanavin [Thu, 9 Jun 2022 09:42:05 +0000 (11:42 +0200)]
swrast_kms: use swkmsDRI2Extension instead of driDRI2Extension

This set of changes:
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15649

caused a regression in Xorg when using swrast_kms:
   (EE) AIGLX error: Calling driver entry point failed

This commit changes the swrast_kms driver to use a dedicated screen init function
(which I believe was overlooked); I also took the opportunity to rename the
associated plumbling to have swrast-specific names.

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16942>

2 years agomicrosoft/spirv_to_dxil: Fix missing-prototypes errors.
Vinson Lee [Mon, 13 Jun 2022 19:48:22 +0000 (12:48 -0700)]
microsoft/spirv_to_dxil: Fix missing-prototypes errors.

../src/microsoft/spirv_to_dxil/dxil_spirv_nir.c: At top level:
../src/microsoft/spirv_to_dxil/dxil_spirv_nir.c:646:1: error: no previous prototype for ‘dxil_spirv_nir_link’ [-Werror=missing-prototypes]
  646 | dxil_spirv_nir_link(nir_shader *nir, nir_shader *prev_stage_nir)
      | ^~~~~~~~~~~~~~~~~~~
../src/microsoft/spirv_to_dxil/dxil_spirv_nir.c:666:1: error: no previous prototype for ‘dxil_spirv_nir_passes’ [-Werror=missing-prototypes]
  666 | dxil_spirv_nir_passes(nir_shader *nir,
      | ^~~~~~~~~~~~~~~~~~~~~

Fixes: c86ea7daa36 ("microsoft/spirv_to_dxil: Extract NIR passes out of spirv_to_dxil()")
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17011>

2 years agoci/windows: Skip dEQP-VK.api.command_buffers.record_many_draws*
Boris Brezillon [Tue, 14 Jun 2022 08:58:51 +0000 (01:58 -0700)]
ci/windows: Skip dEQP-VK.api.command_buffers.record_many_draws*

Those tend to timeout, so let's skip them for now.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16971>

2 years agoci/windows: Add dEQP-VK.dynamic_state.* to the test list
Boris Brezillon [Tue, 14 Jun 2022 20:08:39 +0000 (13:08 -0700)]
ci/windows: Add dEQP-VK.dynamic_state.* to the test list

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16971>

2 years agoci/windows: Allow skipping deqp tests if we have to
Boris Brezillon [Tue, 14 Jun 2022 08:00:56 +0000 (01:00 -0700)]
ci/windows: Allow skipping deqp tests if we have to

Useful to skip tests that are known to crash.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16971>

2 years agodzn: Support dynamic line width
Boris Brezillon [Tue, 14 Jun 2022 07:11:11 +0000 (00:11 -0700)]
dzn: Support dynamic line width

.wideLines = false, which forbids the user to set the line width
to something different than 1. We're thus safe to claim support
for dynamic line width and do nothing in CmdSetLineWidth() other
than checking the value passed is 1.0f.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16971>

2 years agodzn: Support dynamic depth testing parameters properly
Boris Brezillon [Fri, 10 Jun 2022 13:57:56 +0000 (15:57 +0200)]
dzn: Support dynamic depth testing parameters properly

Now that we have support for pipeline variants, we can take the dynamic
depth testing parameters into account and create a new pipeline state
using those dynamic parameters.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16971>

2 years agodzn: Fix triangle-fan emulation
Boris Brezillon [Mon, 13 Jun 2022 14:22:38 +0000 (16:22 +0200)]
dzn: Fix triangle-fan emulation

We were completely ignoring the primitive-restart case in the
index-rewrite logic used to emulate triangle fans. Unfortunately, this
case is way more complicated than a regular index rewrite:

- we need to skip all primitive-restart entries when turning the triangle
  fan into a triangle list, which implies serializing the index buffer
  rewrite procedure (at least I didn't find any clever way to parallelize
  things)
- the number of triangles can no longer be extrapolated from the number
  of indices in the original index buffer, thus forcing us to lower
  direct indexed draws into indirect draws and patching the indexCount
  value when the new index buffer is forged

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16971>

2 years agodzn: Fix primitiveRestart support
Boris Brezillon [Fri, 10 Jun 2022 13:04:29 +0000 (15:04 +0200)]
dzn: Fix primitiveRestart support

We can't hardcode the strip cut value to 0xffffffff, otherwise we break
support for 16-bit index buffers. Let's use the pipeline variant
infrastructure to deal with that case.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16971>

2 years agodzn: Prepare support for pipeline variants
Boris Brezillon [Fri, 10 Jun 2022 10:41:45 +0000 (12:41 +0200)]
dzn: Prepare support for pipeline variants

Some D3D12 states can't be updated dynamically and require the creation
of a new pipeline state. In order to support setting those dynamically
we will have to support creating pipeline variants at draw time.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16971>

2 years agopanfrost: Stop using sparse_array for batch BOs
Icecream95 [Fri, 10 Jun 2022 11:41:48 +0000 (23:41 +1200)]
panfrost: Stop using sparse_array for batch BOs

Iterating over a util_sparse_array is very expensive; replace this
with a standard dynarray.

Using the sparse 'nodearray' datastructure instead was tested, but
found to be slower in some cases.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16988>

2 years agotu: Implement VK_EXT_color_write_enable
Connor Abbott [Wed, 8 Jun 2022 15:11:09 +0000 (17:11 +0200)]
tu: Implement VK_EXT_color_write_enable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16936>

2 years agotu: Implement extendedDynamicState2LogicOp
Connor Abbott [Mon, 6 Jun 2022 23:48:44 +0000 (01:48 +0200)]
tu: Implement extendedDynamicState2LogicOp

Because this impacts most of the registers in the BLEND draw state, we
make the entire draw state dynamic so that it all gets re-emitted when
the logicOp changes. This also lays the groundwork for
VK_EXT_color_write_enable.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16936>

2 years agotu: Fix partial-write LRZ determination
Connor Abbott [Tue, 7 Jun 2022 20:29:57 +0000 (22:29 +0200)]
tu: Fix partial-write LRZ determination

There were a few problems with this:

- It wasn't considering logic op at all, which is another source of
  reading from the destination.
- It was conditioned on the blend_enable_mask, so it was missing the
  case where there's no blending but some of the outputs were masked
  out.
- It wasn't considering attachments with less than 4 components (for
  example, normals in a typical deferred rendering setup) and would
  always consider them partially written unless the user added extra
  unnecessary components.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16936>

2 years agodzn: Vulkan 1.1 wants maxPerSetDescriptors >= 1024
Boris Brezillon [Fri, 22 Apr 2022 12:30:35 +0000 (05:30 -0700)]
dzn: Vulkan 1.1 wants maxPerSetDescriptors >= 1024

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Implement GetDescriptorSetLayoutSupport()
Boris Brezillon [Tue, 19 Apr 2022 09:43:22 +0000 (11:43 +0200)]
dzn: Implement GetDescriptorSetLayoutSupport()

The 2048 descriptors limit comes from the maximum number of samplers
per heap, but the limit for other descriptors is actually much bigger.
Let's implement GetDescriptorSetLayoutSupport() to reflect that.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Add a dzn_desc_type_has_sampler() helper
Boris Brezillon [Wed, 8 Jun 2022 13:57:18 +0000 (06:57 -0700)]
dzn: Add a dzn_desc_type_has_sampler() helper

Add a dzn_desc_type_has_sampler() helper instead of duplicating
the SAMPLER || COMBINED_IMAGE_SAMPLER test everywhere.

Suggested-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Lower alignment requirements when allocating buffers or single-sample images
Boris Brezillon [Tue, 19 Apr 2022 09:12:53 +0000 (11:12 +0200)]
dzn: Lower alignment requirements when allocating buffers or single-sample images

VkMemoryDedicatedAllocateInfo, when present, provides us with extra
information about the memory usage, which allow us to lower the alignment
requirements.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Check that no export is requested in the memory allocation path
Boris Brezillon [Tue, 19 Apr 2022 09:10:52 +0000 (11:10 +0200)]
dzn: Check that no export is requested in the memory allocation path

We don't support exporting memory objects yet, so let's make sure the
user doesn't request that.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Add dummy {Create,Destroy}SamplerYcbcrConversion() implementations
Boris Brezillon [Tue, 19 Apr 2022 09:04:11 +0000 (11:04 +0200)]
dzn: Add dummy {Create,Destroy}SamplerYcbcrConversion() implementations

We don't support Ycbcr sampler conversion. Add dummy implementations to
make us Vulkan 1.1 compliant.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Add a dummy GetImageSparseMemoryRequirements2()
Boris Brezillon [Tue, 19 Apr 2022 09:02:48 +0000 (11:02 +0200)]
dzn: Add a dummy GetImageSparseMemoryRequirements2()

We don't support sparse memory yet, but this function needs to be
present.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Add a dummy GetDeviceGroupPeerMemoryFeatures()
Boris Brezillon [Tue, 19 Apr 2022 09:01:41 +0000 (11:01 +0200)]
dzn: Add a dummy GetDeviceGroupPeerMemoryFeatures()

We don't support device groups, but Vulkan 1.1 requires a
GetDeviceGroupPeerMemoryFeatures() implementation, so let's just
advertise no peer-memory features.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Return empty external properties
Boris Brezillon [Tue, 19 Apr 2022 08:58:54 +0000 (10:58 +0200)]
dzn: Return empty external properties

We don't support importing/exporting images yet, so let's zero out the
whole external properties struct, if present.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agodzn: Decorrelate external image info and external image properties
Boris Brezillon [Tue, 19 Apr 2022 08:57:15 +0000 (10:57 +0200)]
dzn: Decorrelate external image info and external image properties

One can be present without the other.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agomicrosoft/compiler: Support load_sample_id_no_per_sample
Boris Brezillon [Fri, 22 Apr 2022 12:57:37 +0000 (14:57 +0200)]
microsoft/compiler: Support load_sample_id_no_per_sample

It's like load_sample_id except it shouldn't force per-sample shading
when not already enabled. In that case, we simply return 0.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agomicrosoft/compiler: s/assert()/unreachable()/ in emit_intrinsic()
Boris Brezillon [Fri, 22 Apr 2022 12:56:17 +0000 (14:56 +0200)]
microsoft/compiler: s/assert()/unreachable()/ in emit_intrinsic()

Use an unreachable() statement instead of the incorrect assertion in the
unsupported intrinsic path.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agomicrosoft/compiler: Set typed_uav_load_additional_formats when appropriate
Boris Brezillon [Fri, 22 Apr 2022 12:54:55 +0000 (14:54 +0200)]
microsoft/compiler: Set typed_uav_load_additional_formats when appropriate

This flag should be set to true when the RWTexture is attached a vector,
and we always declare a vec4 right now, so it should always be true.
Might be worth reworking the dxil_module_get_res_type() to use a scalar
when the image only has one component.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agomicrosoft/compiler: Images are no longer reprensented by uniform vars
Boris Brezillon [Fri, 22 Apr 2022 12:45:49 +0000 (14:45 +0200)]
microsoft/compiler: Images are no longer reprensented by uniform vars

emit_barrier_impl() was still checking the nir_var_uniform flag to
detect images, which is no longer correct.

Fixes: cfdc7ee066e ("spirv: Use nir_var_mem_image")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agospirv: Add a dst/src type to image deref loads/stores coming from OpAtomic{Load,Store}
Boris Brezillon [Fri, 10 Jun 2022 07:21:55 +0000 (00:21 -0700)]
spirv: Add a dst/src type to image deref loads/stores coming from OpAtomic{Load,Store}

nir_to_dxil() uses those types to pick the right operation overload,
and atomic loads/stores are no different from their non-atomic
counterpart apart from the atomicity property, so it makes sense to
pass a type to the deref_{load,store} intrinsic in that case too.

Suggested-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agovulkan/util: Fill VkPhysicalDeviceIDProperties::deviceNodeMask
Boris Brezillon [Fri, 22 Apr 2022 12:23:16 +0000 (05:23 -0700)]
vulkan/util: Fill VkPhysicalDeviceIDProperties::deviceNodeMask

This field copy was missing in
vk_get_physical_device_core_1_1_property_ext().

Fixes: 19ff5019b75 ("vulkan: Add helpers for filling exts for core features and properties.")
Reviewed-by: Jason Ekstrand <jason.ekstrand@collabora.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

2 years agoci/vs2019: Convert mesa_build.ps1 to using PowerShell 7 && operator
Yonggang Luo [Tue, 14 Jun 2022 08:59:38 +0000 (16:59 +0800)]
ci/vs2019: Convert mesa_build.ps1 to using PowerShell 7 && operator

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Remove comment for windows_test_vs2019 that not true
Yonggang Luo [Fri, 10 Jun 2022 11:03:59 +0000 (19:03 +0800)]
ci/vs2019: Remove comment for windows_test_vs2019 that not true

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Split install of vs2019 and choco into separate Docker image
Yonggang Luo [Fri, 10 Jun 2022 09:32:13 +0000 (17:32 +0800)]
ci/vs2019: Split install of vs2019 and choco into separate Docker image

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Split choco install output
Yonggang Luo [Wed, 8 Jun 2022 06:38:17 +0000 (14:38 +0800)]
ci/vs2019: Split choco install output

Compiling code should be done in docker containers using --isolation=process for efficiency,
but installing dependencies will fail when run that way. Split the "install" dependencies from
the "build" dependencies, so the former can be run in a container using --isolation=hyperv,
and the latter can use --isolation=process.

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Install all build artifacts into C:\mesa-deps
Yonggang Luo [Wed, 1 Jun 2022 15:48:45 +0000 (23:48 +0800)]
ci/vs2019: Install all build artifacts into C:\mesa-deps

By building everything under `deps` directory, remove the `deps` after
them installed.

We can use spirv-as from Vulkan-SDK, so that test won't depends on mesa-deps

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: ignore _build and _install directory by write * into .gitignore
Yonggang Luo [Fri, 10 Jun 2022 09:14:25 +0000 (17:14 +0800)]
ci/vs2019: ignore _build and _install directory by write * into .gitignore

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Reduce the vs2019 build tools components to be installed
Yonggang Luo [Wed, 8 Jun 2022 06:20:15 +0000 (14:20 +0800)]
ci/vs2019: Reduce the vs2019 build tools components to be installed

NOTE:
  Microsoft.VisualStudio.Component.Windows10SDK.19041 are part of
  Microsoft.VisualStudio.Workload.NativeDesktop, so it's actually using Windows10SDK.19041 before,
  not Windows10SDK.18362

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Show the total vs2019 install time
Yonggang Luo [Wed, 8 Jun 2022 03:35:59 +0000 (11:35 +0800)]
ci/vs2019: Show the total vs2019 install time

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Split call to C:\vs_buildtools.exe into multiple lines
Yonggang Luo [Wed, 8 Jun 2022 03:35:59 +0000 (11:35 +0800)]
ci/vs2019: Split call to C:\vs_buildtools.exe into multiple lines

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Add a dedicated script for entering VS dev shell
Yonggang Luo [Wed, 1 Jun 2022 14:47:37 +0000 (22:47 +0800)]
ci/vs2019: Add a dedicated script for entering VS dev shell

Then we can remove cmd.exe invocations, and spread those configure commands
over multiple lines since they're not strings anymore.

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Use shared VULKAN_SDK_VERSION for install and build vulkan related packages
Yonggang Luo [Wed, 1 Jun 2022 15:47:37 +0000 (23:47 +0800)]
ci/vs2019: Use shared VULKAN_SDK_VERSION for install and build vulkan related packages

Get `Vulkan-SDK` `Vulkan-Runtime` `SPIRV-Tools` and `SPIRV-Headers` to be consistence version

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Disable progess bar for pip3 install
Yonggang Luo [Wed, 1 Jun 2022 18:27:57 +0000 (02:27 +0800)]
ci/vs2019: Disable progess bar for pip3 install

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Disable progress when install python
Yonggang Luo [Wed, 1 Jun 2022 17:51:17 +0000 (01:51 +0800)]
ci/vs2019: Disable progress when install python

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Ignore error when removing directory recursively
Yonggang Luo [Wed, 1 Jun 2022 15:45:40 +0000 (23:45 +0800)]
ci/vs2019: Ignore error when removing directory recursively

While we're at it, do the same thing when creating the llvm-project directory

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Ignore cert install output, it's too long
Yonggang Luo [Wed, 1 Jun 2022 15:04:21 +0000 (23:04 +0800)]
ci/vs2019: Ignore cert install output, it's too long

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Do not install subprojects
Yonggang Luo [Wed, 1 Jun 2022 15:42:47 +0000 (23:42 +0800)]
ci/vs2019: Do not install subprojects

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Rename to vsInstallPath
Yonggang Luo [Wed, 1 Jun 2022 14:44:07 +0000 (22:44 +0800)]
ci/vs2019: Rename to vsInstallPath

installPath is too generic

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Give each option its own line in mesa_build.ps1
Yonggang Luo [Wed, 1 Jun 2022 14:43:23 +0000 (22:43 +0800)]
ci/vs2019: Give each option its own line in mesa_build.ps1

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: Update editorconfig for ps1 files
Yonggang Luo [Wed, 8 Jun 2022 18:05:16 +0000 (02:05 +0800)]
ci/vs2019: Update editorconfig for ps1 files

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: switch to powershell 7
Yonggang Luo [Thu, 9 Jun 2022 16:14:11 +0000 (00:14 +0800)]
ci/vs2019: switch to powershell 7

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agoci/vs2019: There is no meaning to set $env:ErrorActionPreference
Yonggang Luo [Thu, 9 Jun 2022 16:13:14 +0000 (00:13 +0800)]
ci/vs2019: There is no meaning to set $env:ErrorActionPreference

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16934>

2 years agozink: check for pending clears to determine write status of zs attachments
Mike Blumenkrantz [Tue, 14 Jun 2022 17:14:56 +0000 (13:14 -0400)]
zink: check for pending clears to determine write status of zs attachments

as @Venemo discovered, zs layouts were being incorrectly set to readonly
in the case where the attachment was only used for an explicit clear,
so ensure that gets taken into account

cc: mesa-stable

fixes (radv):
dEQP-GLES31.functional.stencil_texturing.render.depth24_stencil8_clear
dEQP-GLES31.functional.stencil_texturing.render.depth32f_stencil8_clear

Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17033>

2 years agov3dv/ci: increase fraction to 10 on v3dv ci jobs.
Jose Maria Casanova Crespo [Tue, 14 Jun 2022 10:23:55 +0000 (12:23 +0200)]
v3dv/ci: increase fraction to 10 on v3dv ci jobs.

We reduce the v3dv ci jobs time execution from ~20min to
8-11 min.

Reviewed-by: Juan A. Suarez <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17026>

2 years agozink: clamp dynamic renderArea to framebuffer size
Mike Blumenkrantz [Thu, 9 Jun 2022 13:18:08 +0000 (09:18 -0400)]
zink: clamp dynamic renderArea to framebuffer size

it's illegal to have a renderArea larger than the attachments, so perform
clamping to avoid that scenario

Fixes: c81cd989c85 ("zink: use dynamic rendering (most of the time)")

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16947>

2 years agozink: fix cubemap lowering bit size
Mike Blumenkrantz [Sat, 11 Jun 2022 14:59:59 +0000 (10:59 -0400)]
zink: fix cubemap lowering bit size

this isn't always 32

Fixes: 2d745904ca7 ("zink: add a gently mangled version of the d3d12 cubemap -> array compiler pass")

fixes:
dEQP-GL45-ES31.functional.program_uniform.by_pointer.render.struct_in_array.sampler2D_samplerCube_*

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17008>

2 years agozink: fix cubemap lowering for array samplers
Mike Blumenkrantz [Sat, 11 Jun 2022 14:59:59 +0000 (10:59 -0400)]
zink: fix cubemap lowering for array samplers

each sampler is 1 driver location, so use the base variable

Fixes: 2d745904ca7 ("zink: add a gently mangled version of the d3d12 cubemap -> array compiler pass")

fixes:
dEQP-GL45-ES31.functional.shaders.opaque_type_indexing.sampler.const_expression.*.samplercubearray

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17008>

2 years agozink: skip some emulated cube code if the extension is present
Mike Blumenkrantz [Fri, 10 Jun 2022 15:42:39 +0000 (11:42 -0400)]
zink: skip some emulated cube code if the extension is present

cuts down on some cpu overhead

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16944>

2 years agozink: rename nonseamless struct members to emulate_nonseamless
Mike Blumenkrantz [Fri, 10 Jun 2022 15:38:30 +0000 (11:38 -0400)]
zink: rename nonseamless struct members to emulate_nonseamless

make it clearer that this is separate from the gallium state

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16944>

2 years agozink: use VK_EXT_non_seamless_cube_map when available
Mike Blumenkrantz [Thu, 9 Jun 2022 12:29:43 +0000 (08:29 -0400)]
zink: use VK_EXT_non_seamless_cube_map when available

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16944>

2 years agozink: hook up VK_EXT_non_seamless_cube_map
Mike Blumenkrantz [Thu, 9 Jun 2022 12:29:36 +0000 (08:29 -0400)]
zink: hook up VK_EXT_non_seamless_cube_map

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16944>