platform/upstream/mesa.git
3 years agovulkan: Add common Get*ProcAddr implementations
Jason Ekstrand [Sat, 23 Jan 2021 19:48:04 +0000 (13:48 -0600)]
vulkan: Add common Get*ProcAddr implementations

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Add entrypoint tables and related helpers
Jason Ekstrand [Sun, 24 Jan 2021 17:07:24 +0000 (11:07 -0600)]
vulkan: Add entrypoint tables and related helpers

Entrypoint tables are distinct from dispatch tables because they are not
de-duplicated.  These are needed to make codegen easier.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Add generators for instance trampoline functions
Jason Ekstrand [Sat, 23 Jan 2021 19:28:21 +0000 (13:28 -0600)]
vulkan: Add generators for instance trampoline functions

ANV needs these because we have a different dispatch table for each
hardware generation and Vulkan requires that the device entrypoints
returned from vkGetInstanceProcAddr work regardless of which device
they're used with.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Add common instance and physical device structs
Jason Ekstrand [Sat, 23 Jan 2021 19:06:02 +0000 (13:06 -0600)]
vulkan: Add common instance and physical device structs

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Add dispatch table lookup helpers
Jason Ekstrand [Sat, 23 Jan 2021 18:46:02 +0000 (12:46 -0600)]
vulkan: Add dispatch table lookup helpers

These both look up a name by string and check to see if it's actually
supported given instance and possibly device extension tables.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan-overlay-layer: Use the new dispatch tables
Jason Ekstrand [Sat, 23 Jan 2021 17:47:35 +0000 (11:47 -0600)]
vulkan-overlay-layer: Use the new dispatch tables

This lets us drop the dispatch tables in enum_to_str and replace them
with the new, better versions.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Add dispatch table loading helpers
Jason Ekstrand [Sat, 23 Jan 2021 17:36:18 +0000 (11:36 -0600)]
vulkan: Add dispatch table loading helpers

Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Add common dispatch table generation
Jason Ekstrand [Sat, 23 Jan 2021 11:00:08 +0000 (05:00 -0600)]
vulkan: Add common dispatch table generation

This is based off the dispatch table generation in ANV with the notable
exception that these tables de-duplicate aliased entrypoints by wrapping
all aliased entrypoints in a union which contains all the aliases.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agoanv: Use the common extension table struct
Jason Ekstrand [Sat, 23 Jan 2021 20:45:32 +0000 (14:45 -0600)]
anv: Use the common extension table struct

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Add common extension tables
Jason Ekstrand [Sat, 23 Jan 2021 11:12:43 +0000 (05:12 -0600)]
vulkan: Add common extension tables

Unlike the per-driver tables, these contain every extension ever and
assume the maximum extension version.  This later assumption is ok
because Vulkan extension versions have only been used for something
interesting once in the history of the API.  If it happens again, we can
afford a special case.

This requires us to rework the extension table generation scripts
somewhat because we want to use the same script for both common and
per-driver codegen right now.  To do this we add a "prefix" variable to
go alongside "driver".

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Add a return code to vk_device_init
Jason Ekstrand [Sun, 24 Jan 2021 15:26:24 +0000 (09:26 -0600)]
vulkan: Add a return code to vk_device_init

Reviewed-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan: Move vk_device to its own file
Jason Ekstrand [Sun, 24 Jan 2021 15:06:09 +0000 (09:06 -0600)]
vulkan: Move vk_device to its own file

Things are going to start getting more complicated so let's avoid the
single mega-file approach.

Reviewed-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agolavapipe: Properly clean up vk_device
Jason Ekstrand [Sat, 23 Jan 2021 10:31:08 +0000 (04:31 -0600)]
lavapipe: Properly clean up vk_device

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agov3dv: Properly clean up vk_device
Jason Ekstrand [Sat, 23 Jan 2021 10:29:04 +0000 (04:29 -0600)]
v3dv: Properly clean up vk_device

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agoturnip: Properly clean up vk_device
Jason Ekstrand [Sat, 23 Jan 2021 10:24:09 +0000 (04:24 -0600)]
turnip: Properly clean up vk_device

Reviewed-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agoradv: Properly clean up vk_device
Jason Ekstrand [Sat, 23 Jan 2021 10:23:51 +0000 (04:23 -0600)]
radv: Properly clean up vk_device

Reviewed-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agoanv: Clean up the vk_device on the CreateDevice error path
Jason Ekstrand [Sat, 23 Jan 2021 10:33:02 +0000 (04:33 -0600)]
anv: Clean up the vk_device on the CreateDevice error path

Reviewed-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agovulkan/meson: Add missing dependencise on vk_extensions_gen.py
Jason Ekstrand [Thu, 28 Jan 2021 19:51:57 +0000 (13:51 -0600)]
vulkan/meson: Add missing dependencise on vk_extensions_gen.py

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8676>

3 years agoci/freedreno: Add Valve games and other traces now that we have GLX.
Eric Anholt [Thu, 21 Jan 2021 20:42:11 +0000 (12:42 -0800)]
ci/freedreno: Add Valve games and other traces now that we have GLX.

Two games are skipped until we fix up their runtimes (or maybe make
scheduled overnight pipelines for longer traces?)

Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8727>

3 years agoci/freedreno: Do our piglit runs against Xorg.
Eric Anholt [Fri, 22 Jan 2021 00:19:43 +0000 (16:19 -0800)]
ci/freedreno: Do our piglit runs against Xorg.

We were using surfaceless, which misses out on some useful coverage we'd
like to have in the GLX/EGL piglit tests, but more importantly prevented
many traces from running.

Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8727>

3 years agoci/lava+baremetal: Add an xserver to the root fs.
Eric Anholt [Thu, 21 Jan 2021 23:59:47 +0000 (15:59 -0800)]
ci/lava+baremetal: Add an xserver to the root fs.

We want to be able to test GLX and EGL on real hardware, and we can't do
that with just the surfaceless backend.  Bringing up the xserver is pretty
easy.

Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8727>

3 years agodocs/ci: Document setting up the http cache for traces.
Eric Anholt [Thu, 21 Jan 2021 21:55:02 +0000 (13:55 -0800)]
docs/ci: Document setting up the http cache for traces.

Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8727>

3 years agoci/docs: Update CI farm requirements suggestions.
Eric Anholt [Thu, 21 Jan 2021 21:40:47 +0000 (13:40 -0800)]
ci/docs: Update CI farm requirements suggestions.

We have a handy printout for slow tests now, and DEQP_FRACTION is now
compatible with parallel.

Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8727>

3 years agoci/freedreno: Use the http cache for artifacts downloads, too.
Eric Anholt [Thu, 21 Jan 2021 23:41:18 +0000 (15:41 -0800)]
ci/freedreno: Use the http cache for artifacts downloads, too.

The gitlab artifacts handling has been slow in the past as we hit
gitlab.fdo from multiple runners, and it costs fd.o egress bandwidth.  Use
the local http cache against the packet.net minio to cut that downloads
cost.

Closes: #3249
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8727>

3 years agoci/freedreno: Use the new nginx cache for trace downloads.
Eric Anholt [Thu, 21 Jan 2021 20:36:01 +0000 (12:36 -0800)]
ci/freedreno: Use the new nginx cache for trace downloads.

As we introduce bigger traces to the replay, pulling all of that down all
the way from packet is going to get unreasonable.

Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8727>

3 years agoci/freedreno: Drop pointless GIT_STRATEGY setting for a630.
Eric Anholt [Thu, 28 Jan 2021 19:56:30 +0000 (11:56 -0800)]
ci/freedreno: Drop pointless GIT_STRATEGY setting for a630.

It's already in place due to extending from .test.

Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8727>

3 years agoradv: Do not hash vk_object_base in descriptor set layout.
Bas Nieuwenhuizen [Mon, 1 Feb 2021 12:19:26 +0000 (13:19 +0100)]
radv: Do not hash vk_object_base in descriptor set layout.

It contains potentially pointer-y stuff.

Fixes: 178adfa6a8e ("radv: use the base object struct types")
Acked-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8809>

3 years agoradv: prefer CP DMA for GTT buffer copies/clears on dGPUs due to slow PCIe
Samuel Pitoiset [Thu, 28 Jan 2021 15:26:47 +0000 (16:26 +0100)]
radv: prefer CP DMA for GTT buffer copies/clears on dGPUs due to slow PCIe

The CP DMA bandwidth is always better than PCIe, so I think wasting
compute resources is not a good idea. This is only enabled on GFX10+
because untested on older gens and also because RadeonSI does that.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8763>

3 years agoradv/winsys: move the initial BO domain to radeon_winsys_bo
Samuel Pitoiset [Thu, 28 Jan 2021 15:19:26 +0000 (16:19 +0100)]
radv/winsys: move the initial BO domain to radeon_winsys_bo

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8763>

3 years agoci: Use GNU time as meson test wrapper
Michel Dänzer [Fri, 29 Jan 2021 10:03:19 +0000 (11:03 +0100)]
ci: Use GNU time as meson test wrapper

This will hopefully give us more information about why some tests are
intermittently timing out.

Only in build jobs using the x86_build docker image for now, since
those are where we're currently seeing most such timeouts. But may
expand this later if it provides the expected benefits.

v2:
* Add comment about why we test for and use /usr/bin/time explicitly.

Acked-by: Eric Engestrom <eric@engestrom.ch> # v1
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8776>

3 years agor600/sfn: Use the constant buffer ID when given
Gert Wollny [Sun, 31 Jan 2021 17:54:29 +0000 (18:54 +0100)]
r600/sfn: Use the constant buffer ID when given

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8800>

3 years agor600/sfn: Fix dual source blend lowered to FRAG_DATA
Gert Wollny [Sun, 31 Jan 2021 12:39:47 +0000 (13:39 +0100)]
r600/sfn: Fix dual source blend lowered to FRAG_DATA

This fixes the Unigine benchmarks.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8800>

3 years agor600/sfn: Fix FS inputs when reading from the same position
Gert Wollny [Sat, 30 Jan 2021 20:47:26 +0000 (21:47 +0100)]
r600/sfn: Fix FS inputs when reading from the same position

Don't add another varying in this case.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8800>

3 years agor600/sfn: Add the position input as varying
Gert Wollny [Sat, 30 Jan 2021 18:09:42 +0000 (19:09 +0100)]
r600/sfn: Add the position input as varying

Like this it will be handled correctly in the shader IO structure

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8800>

3 years agor600/sfn: Set unnormalized flag for z-coordinate when fetching from array
Gert Wollny [Sat, 30 Jan 2021 18:08:55 +0000 (19:08 +0100)]
r600/sfn: Set unnormalized flag for z-coordinate when fetching from array

It shouldn't be relewant for fetch, but the TGSI code path does it, so
let's do it here as well.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8800>

3 years agor600/sfn: Fix use of cnde_int for bcsel
Gert Wollny [Sat, 30 Jan 2021 18:07:38 +0000 (19:07 +0100)]
r600/sfn: Fix use of cnde_int for bcsel

The boolean is an int, so use the int version of the opcode.

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8800>

3 years agodocs/features: mark ssbos as done for zink
Erik Faye-Lund [Fri, 29 Jan 2021 11:34:18 +0000 (12:34 +0100)]
docs/features: mark ssbos as done for zink

Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8778>

3 years agov3dv: Only lower local arrays of size up to 2 to if-chains
Arcady Goldmints-Orlov [Fri, 20 Nov 2020 07:12:51 +0000 (01:12 -0600)]
v3dv: Only lower local arrays of size up to 2 to if-chains

Larger arrays get lowered to scratch access later, as that turns out
to be faster, while the if-chain is actually faster for arrays of
2 elements.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7726>

3 years agobroadcom/compiler: Enable PER_QUAD TMU access only in uniform control flow
Arcady Goldmints-Orlov [Tue, 15 Dec 2020 19:55:23 +0000 (13:55 -0600)]
broadcom/compiler: Enable PER_QUAD TMU access only in uniform control flow

PER_QUAD TMU lookups will partially override the predication mask on TMU
writes. If some but not all lanes in a quad are predicated out, setting
PER_QUAD will force them all to be enabled. This can result in TMU
access to bogus addresses when in nonuniform control flow. Also, since
PER_QUAD is needed to make sure derivatives work with helper
invocations, and derivatives are undefined in nonuniform control flow,
there is no reason to leave it enabled in this case.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7726>

3 years agobroadcom/compiler: Emit uniform loops using uniform control flow
Arcady Goldmints-Orlov [Thu, 24 Dec 2020 16:24:56 +0000 (10:24 -0600)]
broadcom/compiler: Emit uniform loops using uniform control flow

Similarly to if statements, uniform loops are now emitted without
predication, using simple branches for breaks and continues. The
uniformity of the loop is determined by running the
nir_divergence_analysis pass.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7726>

3 years agobroadcom/compiler: Use ANYA for branches in uniform ifs
Arcady Goldmints-Orlov [Thu, 31 Dec 2020 17:04:11 +0000 (11:04 -0600)]
broadcom/compiler: Use ANYA for branches in uniform ifs

Using ANYAP instead of ALLAP makes things work correctly in cases
where all lanes are masked out.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7726>

3 years agonir/from_ssa: Respect and populate divergence information
Jason Ekstrand [Tue, 15 Oct 2019 21:14:39 +0000 (16:14 -0500)]
nir/from_ssa: Respect and populate divergence information

Reviewed-by: Arcady Goldmints-Orlov <agoldmints@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7726>

3 years agonir: store the results of divergence analysis on loops
Arcady Goldmints-Orlov [Thu, 24 Dec 2020 16:23:33 +0000 (10:23 -0600)]
nir: store the results of divergence analysis on loops

Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7726>

3 years agonir: handle v3d intrinsics in divergence analysis
Arcady Goldmints-Orlov [Tue, 29 Dec 2020 18:43:04 +0000 (12:43 -0600)]
nir: handle v3d intrinsics in divergence analysis

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7726>

3 years agonir: add more intrinsics to divergence analysis
Arcady Goldmints-Orlov [Mon, 4 Jan 2021 02:55:31 +0000 (20:55 -0600)]
nir: add more intrinsics to divergence analysis

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7726>

3 years agomesa: Remove _mesa_destroy_context()
Rob Clark [Sun, 31 Jan 2021 16:58:09 +0000 (08:58 -0800)]
mesa: Remove _mesa_destroy_context()

There was only one caller, an error path in mesa/st.  But this is now
incorrect as we need align_free().  Just remove it.

Fixes: 55e853d823e ("mesa/st: Allocate the gl_context with 16-byte alignment.")
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8801>

3 years agoandroid: pan/mdg: create nir pass to lower image coord bitsize
Mauro Rossi [Sun, 31 Jan 2021 22:16:10 +0000 (23:16 +0100)]
android: pan/mdg: create nir pass to lower image coord bitsize

Fixes the following building error:

FAILED: out/target/product/x86_64/obj/SHARED_LIBRARIES/gallium_dri_intermediates/LINKED/gallium_dri.so
...
ld.lld: error: undefined symbol: midgard_nir_lower_image_bitsize
>>> referenced by midgard_compile.c:321 (external/mesa/src/panfrost/midgard/midgard_compile.c:321)

Fixes: db725e1d52a6 ("pan/mdg: create nir pass to lower image coord bitsize")
Signed-off-by: Mauro Rossi <issor.oruam@gmail.com>
Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8802>

3 years agov3dv: Fix assert.
Vinson Lee [Sat, 23 Jan 2021 02:49:12 +0000 (18:49 -0800)]
v3dv: Fix assert.

Fix defect reported by Coverity Scan.

Side effect in assertion (ASSERT_SIDE_EFFECT)
assignment_where_comparison_intended: Assignment job->ez_state =
VC5_EZ_DISABLED has a side effect. This code will work differently in a
non-debug build.

Fixes: cec2ed7c80f ("v3dv: fix disabling Early Z for the whole frame")
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8666>

3 years agolima: Fix typos.
Vinson Lee [Fri, 22 Jan 2021 21:46:49 +0000 (13:46 -0800)]
lima: Fix typos.

Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8658>

3 years agomesa: don't count buffer references for the context that created them
Marek Olšák [Mon, 4 Jan 2021 20:25:18 +0000 (15:25 -0500)]
mesa: don't count buffer references for the context that created them

See mtypes.h - it gives you the top level view of how it works, and other
code contains a lot of comments.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8606>

3 years agomesa: pop all textures up to NumCurrentTexUsed, not just MaxTextureUnits
Marek Olšák [Sun, 20 Dec 2020 04:02:16 +0000 (23:02 -0500)]
mesa: pop all textures up to NumCurrentTexUsed, not just MaxTextureUnits

glPush/PopAttrib had 2 defects:
- Only MaxTextureUnits were pushed and popped (which is 8 at most).
- If some texture units had been unused, we would still push/pop them.

This fix changes how many units we push and pop to NumCurrentTexUsed,
which is the maximum texture unit + 1 that was used to by the user.

This commit:
- In glPushAttrib, save NumCurrentTexUsed texture units.
- In glPopAttrib, restore the same number of texture units, and if
  NumCurrentTexUsed has increased since glPushAttrib, bind 0 in the newly
  used units to get them to the state before glPushAttrib.

Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: don't push/pop default texture attributes redundantly
Marek Olšák [Sun, 20 Dec 2020 00:55:59 +0000 (19:55 -0500)]
mesa: don't push/pop default texture attributes redundantly

Since default texture objects are bound in almost all texture units and all
texture targets, we can skip saving and restoring their attributes if we
just do that for default texture objects outside the loop saving all texture
units.

This reduces CPU time spent in glPushAttrib from 2.1% to 1.35% in one
subtest of viewperf13/catia.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: don't save gl_shared_state in glPushAttrib
Marek Olšák [Sun, 20 Dec 2020 00:12:48 +0000 (19:12 -0500)]
mesa: don't save gl_shared_state in glPushAttrib

glPushAttrib only saves values and names. It doesn't save objects.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: partially skip glPush/PopAttrib for MSAA textures and texture buffers
Marek Olšák [Sat, 19 Dec 2020 08:21:25 +0000 (03:21 -0500)]
mesa: partially skip glPush/PopAttrib for MSAA textures and texture buffers

This is based on the GL 4.6 Compatibility profile spec. Some fields just
don't have to be restored. This decreases CPU overhead.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: only pop states in glPopAttrib that have been changed since glPushAttrib
Marek Olšák [Sat, 19 Dec 2020 07:46:03 +0000 (02:46 -0500)]
mesa: only pop states in glPopAttrib that have been changed since glPushAttrib

PopAttribState records all state changes. glPopAttrib uses it to skip
restoring state groups that haven't been changed.

This eliminates a lot of glPopAttrib overhead.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: optimize out _NEW_ALL in glPopAttrib(GL_ENABLE_BIT)
Marek Olšák [Sat, 19 Dec 2020 07:41:32 +0000 (02:41 -0500)]
mesa: optimize out _NEW_ALL in glPopAttrib(GL_ENABLE_BIT)

I reviewed all affected states and this if the minimum attrib mask.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: fix trivial bugs in glPopAttrib
Marek Olšák [Sat, 19 Dec 2020 07:40:15 +0000 (02:40 -0500)]
mesa: fix trivial bugs in glPopAttrib

There were quite a few. Hopefully the comments make it clear.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: for every state change, remember states we changed for glPopAttrib
Marek Olšák [Sat, 19 Dec 2020 06:37:40 +0000 (01:37 -0500)]
mesa: for every state change, remember states we changed for glPopAttrib

The idea is to restore only those states in glPopAttrib that have been
changed. This will reduce glPopAttrib overhead a lot.

This is based on the state tables in the OpenGL 4.6 Compatibility Profile
specification and many extension specifications.

This code might superfluously flag GL_TEXTURE_BIT for texture and
sampler functions that don't have effect on states popped by glPopAttrib,
but I don't wanna test my luck and make a mistake. Thus,
if _NEW_TEXTURE_OBJECT if flagged, GL_TEXTURE_BIT is usually flagged too.

This has no effect on glPopAttrib yet. glPopAttrib will use this in a later
commit. This only adds attrib masks into FLUSH_VERTICES based on specs.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: flush glBegin/End before changing GL_DEPTH_STENCIL_TEXTURE_MODE
Marek Olšák [Sat, 19 Dec 2020 06:48:40 +0000 (01:48 -0500)]
mesa: flush glBegin/End before changing GL_DEPTH_STENCIL_TEXTURE_MODE

Fixes: 23e81b93bbe3 "mesa: Add core API support for GL_ARB_stencil_texturing (from 4.3)."

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: fix glPopAttrib for many texture fields
Marek Olšák [Sat, 19 Dec 2020 06:19:35 +0000 (01:19 -0500)]
mesa: fix glPopAttrib for many texture fields

Move the fields that should be restored by glPopAttrib into the Attrib
structure, which is the only portion of texture objects that is restored
by glPopAttrib. Also moves fields that should not be restored by glPopAttrib
out of the Attrib structure.

This is based on the GL 4.6 Compatibility spec.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: don't push/pop gl_texture_object::Target
Marek Olšák [Sun, 20 Dec 2020 00:33:40 +0000 (19:33 -0500)]
mesa: don't push/pop gl_texture_object::Target

This field is immutable because each texture unit is an array of texture
target slots and only matching targets can be bound into each slot.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: optimize glPopAttrib(GL_VIEWPORT_BIT)
Marek Olšák [Sat, 19 Dec 2020 08:14:01 +0000 (03:14 -0500)]
mesa: optimize glPopAttrib(GL_VIEWPORT_BIT)

We can just copy the variables because they are already clamped
to ctx->Const limits.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: optimize most _mesa_ActiveTexture calls in glPopAttrib
Marek Olšák [Sat, 19 Dec 2020 08:04:45 +0000 (03:04 -0500)]
mesa: optimize most _mesa_ActiveTexture calls in glPopAttrib

_mesa_ActiveTexture changes CurrentUnit and the texture matrix stack
if the matrix mode is a texture matrix. In these cases, the texture matrix
stack is not touched.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agomesa: remove/replace FLUSH_VERTICES when it doesn't do anything
Marek Olšák [Sat, 19 Dec 2020 06:41:04 +0000 (01:41 -0500)]
mesa: remove/replace FLUSH_VERTICES when it doesn't do anything

In _mesa_PopAttrib, we call FLUSH_VERTICES at the beginning, so we don't
need to do it again.

In the MultiMode functions, we call standard Draw functions
using the dispatch, which do the flushing by themselves.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8181>

3 years agoradeonsi: precompute NGG cull flags in si_create_rs_state
Marek Olšák [Thu, 14 Jan 2021 12:43:19 +0000 (07:43 -0500)]
radeonsi: precompute NGG cull flags in si_create_rs_state

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: prefetch VB descriptors right after uploading
Marek Olšák [Mon, 11 Jan 2021 20:14:40 +0000 (15:14 -0500)]
radeonsi: prefetch VB descriptors right after uploading

This skips the logic that sets and checks prefetch_L2_mask.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: set VB user SGPRs in si_upload_vertex_buffer_descriptors
Marek Olšák [Mon, 11 Jan 2021 20:02:48 +0000 (15:02 -0500)]
radeonsi: set VB user SGPRs in si_upload_vertex_buffer_descriptors

so that we don't have to enter the state emit loop and invoke the more
complicated function si_emit_graphics_shader_pointers.

Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: reorganize si_draw_vbo for lower register pressure (part 2)
Marek Olšák [Sun, 10 Jan 2021 02:43:33 +0000 (21:43 -0500)]
radeonsi: reorganize si_draw_vbo for lower register pressure (part 2)

Move statements that use the least number of local variables as close
to the beginning as possible. Also move local variables closer to their use.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: reorganize si_draw_vbo for lower register pressure (part 1)
Marek Olšák [Sun, 10 Jan 2021 02:43:33 +0000 (21:43 -0500)]
radeonsi: reorganize si_draw_vbo for lower register pressure (part 1)

Move statements that use the least number of local variables as close
to the beginning as possible. Also move local variables closer to their use.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: optimize si_emit_prefetch_L2 when it's split
Marek Olšák [Sat, 9 Jan 2021 22:41:17 +0000 (17:41 -0500)]
radeonsi: optimize si_emit_prefetch_L2 when it's split

When using the prefetch with VS_ONLY=true followed by VS_ONLY=false,
we tested the VS_ONLY bits in the mask when executing VS_ONLY=false where
the bits were always 0. It's also useless to clear the prefetch mask when
VS_ONLY=true.

This commit skips those tests by splitting the function properly using
BEFORE_DRAW and AFTER_DRAW template parameters.

Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: don't check for redundant and NULL states in si_emit_all_states
Marek Olšák [Sat, 9 Jan 2021 13:12:38 +0000 (08:12 -0500)]
radeonsi: don't check for redundant and NULL states in si_emit_all_states

All places set dirty_states correctly now.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: delete si_pm4_delete_state
Marek Olšák [Wed, 27 Jan 2021 23:06:57 +0000 (18:06 -0500)]
radeonsi: delete si_pm4_delete_state

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: move si_pm4_delete_state logic into si_pm4_free_state
Marek Olšák [Sat, 9 Jan 2021 12:55:59 +0000 (07:55 -0500)]
radeonsi: move si_pm4_delete_state logic into si_pm4_free_state

also clear dirty_states.

Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: mark shader_pointers dirty once outside the upload descriptors loop
Marek Olšák [Tue, 12 Jan 2021 06:30:53 +0000 (01:30 -0500)]
radeonsi: mark shader_pointers dirty once outside the upload descriptors loop

Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoradeonsi: optimize no-op cases in si_upload_shader_descriptors
Marek Olšák [Tue, 12 Jan 2021 06:29:28 +0000 (01:29 -0500)]
radeonsi: optimize no-op cases in si_upload_shader_descriptors

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agoac,radeonsi: track memory usage in KB to reduce types from uint64 to uint32
Marek Olšák [Sun, 10 Jan 2021 05:29:01 +0000 (00:29 -0500)]
ac,radeonsi: track memory usage in KB to reduce types from uint64 to uint32

Decreasing the time spent in radeon_cs_memory_below_limit is the motivation.

Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8794>

3 years agodocs: update calendar for 21.0.0-rc3
Dylan Baker [Sat, 30 Jan 2021 04:14:07 +0000 (20:14 -0800)]
docs: update calendar for 21.0.0-rc3

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

3 years agodocs: update calendar for 21.0.0-rc2
Dylan Baker [Sat, 30 Jan 2021 04:13:58 +0000 (20:13 -0800)]
docs: update calendar for 21.0.0-rc2

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

3 years agodocs: update calendar and link releases notes for 20.3.4
Dylan Baker [Sat, 30 Jan 2021 04:13:33 +0000 (20:13 -0800)]
docs: update calendar and link releases notes for 20.3.4

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

3 years agodocs: Add sha256sum for 20.3.4
Dylan Baker [Sat, 30 Jan 2021 04:11:41 +0000 (20:11 -0800)]
docs: Add sha256sum for 20.3.4

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

3 years agodocs: add release notes for 20.3.4
Dylan Baker [Fri, 29 Jan 2021 18:12:48 +0000 (10:12 -0800)]
docs: add release notes for 20.3.4

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

3 years agospirv: Store SPIR-V version of the module
Caio Marcelo de Oliveira Filho [Mon, 11 Jan 2021 19:51:24 +0000 (11:51 -0800)]
spirv: Store SPIR-V version of the module

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8786>

3 years agospirv: Don't remove dead variables in `create_library` mode
Caio Marcelo de Oliveira Filho [Thu, 21 Jan 2021 10:35:43 +0000 (02:35 -0800)]
spirv: Don't remove dead variables in `create_library` mode

The issues fixed by the removal happen when a module has multiple
entry points and conflicting global variables.  Neither conditions are
expected in a library.

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8786>

3 years agospirv: Don't bother counting num_images/num_textures
Caio Marcelo de Oliveira Filho [Tue, 12 Jan 2021 17:21:07 +0000 (09:21 -0800)]
spirv: Don't bother counting num_images/num_textures

Not only these are recalculated in nir_shader_gather_info, but
currently they are also counting all the images / textures in the
module instead of in the shader (entrypoint).

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8786>

3 years agomesa/st: Allocate the gl_context with 16-byte alignment.
Eric Anholt [Fri, 29 Jan 2021 17:59:34 +0000 (09:59 -0800)]
mesa/st: Allocate the gl_context with 16-byte alignment.

The _ModelProjectMatrix matrix embedded inside has members inside of it
marked as 16-byte aligned, and so the context also has to be 16-byte
aligned or access to those members would be invalid.  I believe the
compiler used this to use better 16-byte-aligned load/stores to other
members of the context, breaking when the context's alignment was only 8
(as normal mallocs guarantee).

Fixes: 3175b63a0dfa ("mesa: don't allocate matrices with malloc")
Tested-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8783>

3 years agolavapipe: add missing loader interface negoitation
Dave Airlie [Thu, 28 Jan 2021 20:32:57 +0000 (06:32 +1000)]
lavapipe: add missing loader interface negoitation

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8769>

3 years agomicrosoft/compiler: Make resource_state_manager only build with_gallium_d3d12
Michael Tang [Fri, 29 Jan 2021 20:48:43 +0000 (12:48 -0800)]
microsoft/compiler: Make resource_state_manager only build with_gallium_d3d12

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

3 years agoCI: windows: Force using LLVM 12
Benjamin Tissoires [Fri, 29 Jan 2021 13:30:23 +0000 (14:30 +0100)]
CI: windows: Force using LLVM 12

LLVM is moving to the 13 release, but LLVM-SPIRV is still so in the past.
Given that LLVM 12.0.0 is still not out (we are at 12.0.0-rc1 today),
use the `release/12.x` branch for LLVM.

We should also tag LLVM-SPIRV, but... it seems that they haven't caught up
yet, so keep using the master branch, but add a note for a future
committer.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8740>

3 years agoCI: windows: split the layers to meet new registry requirements
Benjamin Tissoires [Wed, 27 Jan 2021 14:17:28 +0000 (15:17 +0100)]
CI: windows: split the layers to meet new registry requirements

The new registry caching in place for registry.fd.o can not handle layers
bigger than 5 GB. The last layer we used to build on windows was 5.2 GB,
meaning that the upload would fail.

Split the layers by calling multiple `RUN`, hoping that the size will be
roughly split between those steps if we have a special layer for VS2019.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8740>

3 years agoCI: windows: augment the timeout of building the windows container
Benjamin Tissoires [Wed, 27 Jan 2021 14:21:37 +0000 (15:21 +0100)]
CI: windows: augment the timeout of building the windows container

https://gitlab.freedesktop.org/mesa/mesa/-/jobs/6898838 failed at
uploading the containers but got kicked out right before being able to
give us a valid error.

Bump the timeout for windows container builds, to not have this
unfortunate situation.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8740>

3 years agoglsl: support 64bit integer loop iterators
Mike Blumenkrantz [Mon, 26 Oct 2020 14:47:37 +0000 (10:47 -0400)]
glsl: support 64bit integer loop iterators

this was crashing due to the assumption that non-32bit integer values must be
floats

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7316>

3 years agopan/bi: Add packing format tests
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:31:34 +0000 (13:31 -0500)]
pan/bi: Add packing format tests

These are based on reference outputs generated by the blob.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>

3 years agopan/bi: Test pack_sync
Alyssa Rosenzweig [Tue, 29 Dec 2020 16:29:45 +0000 (11:29 -0500)]
pan/bi: Test pack_sync

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>

3 years agopan/bi: Test pack_tuple_bits
Alyssa Rosenzweig [Tue, 29 Dec 2020 16:18:02 +0000 (11:18 -0500)]
pan/bi: Test pack_tuple_bits

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>

3 years agopan/bi: Test pack_upper
Alyssa Rosenzweig [Tue, 29 Dec 2020 16:00:31 +0000 (11:00 -0500)]
pan/bi: Test pack_upper

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>

3 years agopan/bi: Test pack_literal
Alyssa Rosenzweig [Tue, 29 Dec 2020 15:56:08 +0000 (10:56 -0500)]
pan/bi: Test pack_literal

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>

3 years agopan/bi: Add packing unit test group
Alyssa Rosenzweig [Tue, 29 Dec 2020 15:35:11 +0000 (10:35 -0500)]
pan/bi: Add packing unit test group

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>

3 years agopan/bi: Pack multiple tuples per clause
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:43:37 +0000 (13:43 -0500)]
pan/bi: Pack multiple tuples per clause

Use all of the new helpers to pick formats and use them.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>

3 years agopan/bi: Calculate pos for constant packing
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:42:44 +0000 (13:42 -0500)]
pan/bi: Calculate pos for constant packing

We do not yet support multiple (format 12 quadword) constants per clause
but this is a step in the right direction.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>

3 years agopan/bi: Add pack_format helper
Alyssa Rosenzweig [Wed, 6 Jan 2021 18:41:06 +0000 (13:41 -0500)]
pan/bi: Add pack_format helper

Packs a single quadword of a clause with a particular format and
parameters.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8723>