Mesa (master): microsoft/resoure_state_manager: Silence GCC invalid offsetof warning
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sun Jan 3 23:24:44 UTC 2021
Module: Mesa
Branch: master
Commit: cda9d44bae334722bfadf8af0d49bd490b1c0c9d
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=cda9d44bae334722bfadf8af0d49bd490b1c0c9d
Author: Jesse Natalie <jenatali at microsoft.com>
Date: Mon Dec 28 10:49:38 2020 -0800
microsoft/resoure_state_manager: Silence GCC invalid offsetof warning
Reviewed-by: Adam Jackson <ajax at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8248>
---
src/microsoft/resource_state_manager/D3D12ResourceState.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/microsoft/resource_state_manager/D3D12ResourceState.h b/src/microsoft/resource_state_manager/D3D12ResourceState.h
index a8d27ccbe62..f2c66434483 100644
--- a/src/microsoft/resource_state_manager/D3D12ResourceState.h
+++ b/src/microsoft/resource_state_manager/D3D12ResourceState.h
@@ -34,6 +34,10 @@
#include "util/list.h"
+#if defined(__GNUC__)
+#pragma GCC diagnostic ignored "-Winvalid-offsetof"
+#endif
+
#define UNKNOWN_RESOURCE_STATE (D3D12_RESOURCE_STATES)0x8000u
#define RESOURCE_STATE_VALID_BITS 0x2f3fff
#define RESOURCE_STATE_VALID_INTERNAL_BITS 0x2fffff
More information about the mesa-commit
mailing list