Mesa (master): gallium: add a resource flag to say no over allocation.

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Aug 17 05:01:07 UTC 2020


Module: Mesa
Branch: master
Commit: ecb617a6a757a375a66b3c2ad25990011624c41a
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=ecb617a6a757a375a66b3c2ad25990011624c41a

Author: Dave Airlie <airlied at redhat.com>
Date:   Fri Jun 19 16:25:49 2020 +1000

gallium: add a resource flag to say no over allocation.

llvmpipe overallocates buffers for buffers used as render targets,
however this breaks some vulkan apps (UE4), so add a workaround
flag to force llvmpipe to not overallocate certain buffers.

Reviewed-by: Roland Scheidegger <sroland at vmware.com>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6082>

---

 src/gallium/include/pipe/p_defines.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/gallium/include/pipe/p_defines.h b/src/gallium/include/pipe/p_defines.h
index 88e65ca787e..235c8ec06bc 100644
--- a/src/gallium/include/pipe/p_defines.h
+++ b/src/gallium/include/pipe/p_defines.h
@@ -512,6 +512,7 @@ enum pipe_flush_flags
 #define PIPE_RESOURCE_FLAG_SPARSE                (1 << 3)
 #define PIPE_RESOURCE_FLAG_SINGLE_THREAD_USE     (1 << 4)
 #define PIPE_RESOURCE_FLAG_ENCRYPTED             (1 << 5)
+#define PIPE_RESOURCE_FLAG_DONT_OVER_ALLOCATE    (1 << 6)
 #define PIPE_RESOURCE_FLAG_DRV_PRIV    (1 << 8) /* driver/winsys private */
 #define PIPE_RESOURCE_FLAG_FRONTEND_PRIV         (1 << 24) /* gallium frontend private */
 



More information about the mesa-commit mailing list