Date: Saturday, March 25, 2023 @ 14:20:38
Author: heftig
Revision: 1427900
23.0.1-1
Added:
lib32-mesa/trunk/0001-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
(from rev 1421544,
lib32-mesa/trunk/0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch)
lib32-mesa/trunk/0002-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
(from rev 1421544,
lib32-mesa/trunk/0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch)
Modified:
lib32-mesa/trunk/PKGBUILD
Deleted:
lib32-mesa/trunk/0001-anv-force-MEDIA_INTERFACE_DESCRIPTOR_LOAD-reemit-aft.patch
lib32-mesa/trunk/0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
lib32-mesa/trunk/0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
-----------------------------------------------------------------+
0001-anv-force-MEDIA_INTERFACE_DESCRIPTOR_LOAD-reemit-aft.patch | 55
----------
0001-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch | 51
+++++++++
0002-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch | 34 ++++++
0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch | 51
---------
0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch | 34 ------
PKGBUILD | 32 ++---
6 files changed, 100 insertions(+), 157 deletions(-)
Deleted: 0001-anv-force-MEDIA_INTERFACE_DESCRIPTOR_LOAD-reemit-aft.patch
===================================================================
--- 0001-anv-force-MEDIA_INTERFACE_DESCRIPTOR_LOAD-reemit-aft.patch
2023-03-25 14:20:15 UTC (rev 1427899)
+++ 0001-anv-force-MEDIA_INTERFACE_DESCRIPTOR_LOAD-reemit-aft.patch
2023-03-25 14:20:38 UTC (rev 1427900)
@@ -1,55 +0,0 @@
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Lionel Landwerlin <[email protected]>
-Date: Sun, 12 Jun 2022 23:59:05 +0300
-Subject: [PATCH] anv: force MEDIA_INTERFACE_DESCRIPTOR_LOAD reemit after
- 3D->GPGPU switch
-
-Seems to fix a hang in the following titles :
- - Age of Empire 4
- - Monster Hunter Rise
-
-where the HW is hung on a PIPE_CONTROL after a GPGPU_WALKER but no
-MEDIA_INTERFACE_DESCRIPTOR_LOAD was emitted since the switch from 3D
-to GPGPU.
-
-This would happen in the following case :
-
- vkCmdBindPipeline(COMPUTE, cs_pipeline);
- vkCmdDispatch(...);
- vkCmdBindPipeline(GRAPHICS, gfx_pipeline);
- vkCmdDraw(...);
- vkCmdDispatch(...);
-
-Signed-off-by: Lionel Landwerlin <[email protected]>
-Reviewed-by: Ivan Briano <[email protected]>
-Cc: mesa-stable
-Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17247>
----
- src/intel/vulkan/genX_cmd_buffer.c | 14 ++++++++++++++
- 1 file changed, 14 insertions(+)
-
-diff --git a/src/intel/vulkan/genX_cmd_buffer.c
b/src/intel/vulkan/genX_cmd_buffer.c
-index 25d337945896..1b382cae49a1 100644
---- a/src/intel/vulkan/genX_cmd_buffer.c
-+++ b/src/intel/vulkan/genX_cmd_buffer.c
-@@ -6383,6 +6383,20 @@ genX(flush_pipeline_select)(struct anv_cmd_buffer
*cmd_buffer,
- }
- #endif
-
-+#if GFX_VERx10 == 120
-+ /* Undocumented workaround to force the re-emission of
-+ * MEDIA_INTERFACE_DESCRIPTOR_LOAD when switching from 3D to Compute
-+ * pipeline without rebinding a pipeline :
-+ * vkCmdBindPipeline(COMPUTE, cs_pipeline);
-+ * vkCmdDispatch(...);
-+ * vkCmdBindPipeline(GRAPHICS, gfx_pipeline);
-+ * vkCmdDraw(...);
-+ * vkCmdDispatch(...);
-+ */
-+ if (pipeline == _3D)
-+ cmd_buffer->state.compute.pipeline_dirty = true;
-+#endif
-+
- #if GFX_VER >= 12
- /* From Tigerlake PRM, Volume 2a, PIPELINE_SELECT:
- *
Copied:
lib32-mesa/trunk/0001-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
(from rev 1421544,
lib32-mesa/trunk/0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch)
===================================================================
--- 0001-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
(rev 0)
+++ 0001-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
2023-03-25 14:20:38 UTC (rev 1427900)
@@ -0,0 +1,51 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Kai-Heng Feng <[email protected]>
+Date: Thu, 29 Dec 2022 13:43:27 +0800
+Subject: [PATCH] iris: Retry DRM_IOCTL_I915_GEM_EXECBUFFER2 on ENOMEM
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+We are seeing endless DRM_IOCTL_SYNCOBJ_WAIT ioctl when system memory is
+under pressured.
+
+Commit f9d8d9acbb6a ("iris: Avoid abort() if kernel can't allocate
+memory") avoids the abort() on ENOMEM by resetting the batch. However,
+when there's an ongoing OpenGL query, resetting the batch will make the
+snapshots_landed never be flipped, so iris_get_query_result() gets stuck
+in the while loop forever.
+
+Since there's no guarantee that the next batch after resetting won't hit
+ENOMEM, so instead of resetting the batch, be patient and wait until kernel has
+enough memory. Once the batch is submiited and snapshots_landed gets
+flipped, iris_get_query_result() can proceed normally.
+
+Reviewed-by: José Roberto de Souza <[email protected]>
+Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/6851
+Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20449>
+---
+ src/gallium/drivers/iris/iris_batch.c | 11 ++++++++---
+ 1 file changed, 8 insertions(+), 3 deletions(-)
+
+diff --git a/src/gallium/drivers/iris/iris_batch.c
b/src/gallium/drivers/iris/iris_batch.c
+index c7a08a0e1f5f..deab85ce4aaf 100644
+--- a/src/gallium/drivers/iris/iris_batch.c
++++ b/src/gallium/drivers/iris/iris_batch.c
+@@ -981,9 +981,14 @@ submit_batch(struct iris_batch *batch)
+ }
+
+ int ret = 0;
+- if (!batch->screen->devinfo->no_hw &&
+- intel_ioctl(batch->screen->fd, DRM_IOCTL_I915_GEM_EXECBUFFER2,
&execbuf))
+- ret = -errno;
++ if (!batch->screen->devinfo->no_hw) {
++ do {
++ ret = intel_ioctl(batch->screen->fd, DRM_IOCTL_I915_GEM_EXECBUFFER2,
&execbuf);
++ } while (ret && errno == ENOMEM);
++
++ if (ret)
++ ret = -errno;
++ }
+
+ simple_mtx_unlock(bo_deps_lock);
+
Copied:
lib32-mesa/trunk/0002-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
(from rev 1421544,
lib32-mesa/trunk/0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch)
===================================================================
--- 0002-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
(rev 0)
+++ 0002-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
2023-03-25 14:20:38 UTC (rev 1427900)
@@ -0,0 +1,34 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Kai-Heng Feng <[email protected]>
+Date: Thu, 29 Dec 2022 14:01:31 +0800
+Subject: [PATCH] Revert "iris: Avoid abort() if kernel can't allocate memory"
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This reverts commit f9d8d9acbb6a620684fb4dac4affe25816587d92.
+
+Now ENOMEM is handled in submit_batch(), we don't need to check it for
+resetting anymore.
+
+Reviewed-by: José Roberto de Souza <[email protected]>
+Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20449>
+---
+ src/gallium/drivers/iris/iris_batch.c | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/src/gallium/drivers/iris/iris_batch.c
b/src/gallium/drivers/iris/iris_batch.c
+index deab85ce4aaf..2993f0ab7ee8 100644
+--- a/src/gallium/drivers/iris/iris_batch.c
++++ b/src/gallium/drivers/iris/iris_batch.c
+@@ -1097,9 +1097,8 @@ _iris_batch_flush(struct iris_batch *batch, const char
*file, int line)
+ * with a new logical context, and inform iris_context that all state
+ * has been lost and needs to be re-initialized. If this succeeds,
+ * dubiously claim success...
+- * Also handle ENOMEM here.
+ */
+- if ((ret == -EIO || ret == -ENOMEM) && replace_kernel_ctx(batch)) {
++ if (ret == -EIO && replace_kernel_ctx(batch)) {
+ if (batch->reset->reset) {
+ /* Tell gallium frontends the device is lost and it was our fault. */
+ batch->reset->reset(batch->reset->data, PIPE_GUILTY_CONTEXT_RESET);
Deleted: 0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
===================================================================
--- 0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
2023-03-25 14:20:15 UTC (rev 1427899)
+++ 0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
2023-03-25 14:20:38 UTC (rev 1427900)
@@ -1,51 +0,0 @@
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Kai-Heng Feng <[email protected]>
-Date: Thu, 29 Dec 2022 13:43:27 +0800
-Subject: [PATCH] iris: Retry DRM_IOCTL_I915_GEM_EXECBUFFER2 on ENOMEM
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-We are seeing endless DRM_IOCTL_SYNCOBJ_WAIT ioctl when system memory is
-under pressured.
-
-Commit f9d8d9acbb6a ("iris: Avoid abort() if kernel can't allocate
-memory") avoids the abort() on ENOMEM by resetting the batch. However,
-when there's an ongoing OpenGL query, resetting the batch will make the
-snapshots_landed never be flipped, so iris_get_query_result() gets stuck
-in the while loop forever.
-
-Since there's no guarantee that the next batch after resetting won't hit
-ENOMEM, so instead of resetting the batch, be patient and wait until kernel has
-enough memory. Once the batch is submiited and snapshots_landed gets
-flipped, iris_get_query_result() can proceed normally.
-
-Reviewed-by: José Roberto de Souza <[email protected]>
-Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/6851
-Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20449>
----
- src/gallium/drivers/iris/iris_batch.c | 11 ++++++++---
- 1 file changed, 8 insertions(+), 3 deletions(-)
-
-diff --git a/src/gallium/drivers/iris/iris_batch.c
b/src/gallium/drivers/iris/iris_batch.c
-index c7a08a0e1f5f..deab85ce4aaf 100644
---- a/src/gallium/drivers/iris/iris_batch.c
-+++ b/src/gallium/drivers/iris/iris_batch.c
-@@ -981,9 +981,14 @@ submit_batch(struct iris_batch *batch)
- }
-
- int ret = 0;
-- if (!batch->screen->devinfo->no_hw &&
-- intel_ioctl(batch->screen->fd, DRM_IOCTL_I915_GEM_EXECBUFFER2,
&execbuf))
-- ret = -errno;
-+ if (!batch->screen->devinfo->no_hw) {
-+ do {
-+ ret = intel_ioctl(batch->screen->fd, DRM_IOCTL_I915_GEM_EXECBUFFER2,
&execbuf);
-+ } while (ret && errno == ENOMEM);
-+
-+ if (ret)
-+ ret = -errno;
-+ }
-
- simple_mtx_unlock(bo_deps_lock);
-
Deleted: 0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
===================================================================
--- 0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
2023-03-25 14:20:15 UTC (rev 1427899)
+++ 0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
2023-03-25 14:20:38 UTC (rev 1427900)
@@ -1,34 +0,0 @@
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Kai-Heng Feng <[email protected]>
-Date: Thu, 29 Dec 2022 14:01:31 +0800
-Subject: [PATCH] Revert "iris: Avoid abort() if kernel can't allocate memory"
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-This reverts commit f9d8d9acbb6a620684fb4dac4affe25816587d92.
-
-Now ENOMEM is handled in submit_batch(), we don't need to check it for
-resetting anymore.
-
-Reviewed-by: José Roberto de Souza <[email protected]>
-Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20449>
----
- src/gallium/drivers/iris/iris_batch.c | 3 +--
- 1 file changed, 1 insertion(+), 2 deletions(-)
-
-diff --git a/src/gallium/drivers/iris/iris_batch.c
b/src/gallium/drivers/iris/iris_batch.c
-index deab85ce4aaf..2993f0ab7ee8 100644
---- a/src/gallium/drivers/iris/iris_batch.c
-+++ b/src/gallium/drivers/iris/iris_batch.c
-@@ -1097,9 +1097,8 @@ _iris_batch_flush(struct iris_batch *batch, const char
*file, int line)
- * with a new logical context, and inform iris_context that all state
- * has been lost and needs to be re-initialized. If this succeeds,
- * dubiously claim success...
-- * Also handle ENOMEM here.
- */
-- if ((ret == -EIO || ret == -ENOMEM) && replace_kernel_ctx(batch)) {
-+ if (ret == -EIO && replace_kernel_ctx(batch)) {
- if (batch->reset->reset) {
- /* Tell gallium frontends the device is lost and it was our fault. */
- batch->reset->reset(batch->reset->data, PIPE_GUILTY_CONTEXT_RESET);
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2023-03-25 14:20:15 UTC (rev 1427899)
+++ PKGBUILD 2023-03-25 14:20:38 UTC (rev 1427900)
@@ -6,8 +6,8 @@
pkgbase=lib32-mesa
pkgname=('lib32-vulkan-mesa-layers' 'lib32-opencl-mesa' 'lib32-vulkan-intel'
'lib32-vulkan-radeon' 'lib32-vulkan-virtio' 'lib32-libva-mesa-driver'
'lib32-mesa-vdpau' 'lib32-mesa')
pkgdesc="An open-source implementation of the OpenGL specification (32-bit)"
-pkgver=23.0.0
-pkgrel=3
+pkgver=23.0.1
+pkgrel=1
arch=('x86_64')
makedepends=('python-mako' 'lib32-libxml2' 'lib32-expat' 'lib32-libx11'
'xorgproto' 'lib32-libdrm'
'lib32-libxshmfence' 'lib32-libxxf86vm' 'lib32-libxdamage'
'lib32-libvdpau'
@@ -18,16 +18,19 @@
url="https://www.mesa3d.org/"
license=('custom')
source=(https://mesa.freedesktop.org/archive/mesa-${pkgver}.tar.xz{,.sig}
- 0001-anv-force-MEDIA_INTERFACE_DESCRIPTOR_LOAD-reemit-aft.patch
- 0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
- 0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
+ 0001-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
+ 0002-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
LICENSE)
-sha512sums=('127e2759a2a31cacd65a0891719ab7bb4a9188844022b4bccaebbedce9c550b9ccb160ad519178ea0d851c4bcb8f0f56febda248ed2ba82b5ddf804855e4694b'
+sha256sums=('e8e586856b55893abae9bdcdb98b41c081d909bb1faf372e6e7262307bf34adf'
'SKIP'
-
'c7832724bad137461fcdffc3db8ba653ea25c56b5980d7c45955844a543ce57ec4360e88e73ab48f7cb69717a2f467a03aca13ede3591f27e36e20409f8982e8'
-
'b089a84333743f2f69889f99903616a9dab28e45edf2de7b1f64d29bbb321daaf898aa05bf60fea6d2feec6b5ff072b807d76bb21efe122ff1a15e275d8acc97'
-
'ac4f1f98c5f1d0c2f875c2cf964fe60f41385b18a3507fea77f899f0cbbbea0baee92d313936f2d325c2301a7d0dfe3294bf881722fb22fa41defd4e4fbd0f98'
-
'f9f0d0ccf166fe6cb684478b6f1e1ab1f2850431c06aa041738563eb1808a004e52cdec823c103c9e180f03ffc083e95974d291353f0220fe52ae6d4897fecc7')
+ '99264c77d63d6fa810e295914808cde9f580a64e913e99fa794c1aa25a4f8fb2'
+ 'd6ef8fb1809e8aeae0ec32bfe916adb770c64880bfd3d0f4472a616c9f356a9a'
+ '7052ba73bb07ea78873a2431ee4e828f4e72bda7d176d07f770fa48373dec537')
+b2sums=('50d358e393037381d0d848f868ac3439b0851809c3533432dc428bd77e81bc71bbfd2b598e221b6e8c4c2528ef32e5624aec4fe2e552e01ee98abbcf96a1f5b7'
+ 'SKIP'
+
'a90bfc47fb3a46eff1ef2455c7aa18c2bb515ec217b423d0a87cc5f3b824a77c0381e1378498464418644108142022dcd3c289e157877c6ae7584beaec1d9987'
+
'bd52994305fc0fa2f12c46ea3208bbb24f97495d9bad73120d83a6cdcf7e48f5ff0d14ac0055765516b70caacdf024fca4159b70b054e85f2783c78c9218aefe'
+
'1ecf007b82260710a7bf5048f47dd5d600c168824c02c595af654632326536a6527fbe0738670ee7b921dd85a70425108e0f471ba85a8e1ca47d294ad74b4adb')
validpgpkeys=('8703B6700E7EE06D7A39B8D6EDAE37B02CEB490D' # Emil Velikov
<[email protected]>
'946D09B5E4C9845E63075FF1D961C596A7203456' # Andres Gomez
<[email protected]>
'E3E8F480C52ADD73B278EE78E1ECBE07D7D70895' # Juan Antonio
Suárez Romero (Igalia, S.L.) <[email protected]>
@@ -38,15 +41,10 @@
prepare() {
cd mesa-$pkgver
- # https://gitlab.freedesktop.org/mesa/mesa/-/issues/7111
- # https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17247
- # https://github.com/HansKristian-Work/vkd3d-proton/issues/1200
- patch -Np1 -i
../0001-anv-force-MEDIA_INTERFACE_DESCRIPTOR_LOAD-reemit-aft.patch
-
# https://gitlab.freedesktop.org/drm/intel/-/issues/6851
# https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20449
- patch -Np1 -i
../0002-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
- patch -Np1 -i
../0003-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
+ patch -Np1 -i
../0001-iris-Retry-DRM_IOCTL_I915_GEM_EXECBUFFER2-on-ENOMEM.patch
+ patch -Np1 -i
../0002-Revert-iris-Avoid-abort-if-kernel-can-t-allocate-mem.patch
}
build() {