mesa: fix with DEBUG_BUILD enabled
PATCH 1/1 mesa: fix with DEBUG_BUILD enabled
From: Kai Kang <[email protected]>
It fails to compile mesa-native when DEBUG_BUILD is enabled:
../mesa-22.1.3/src/compiler/nir/nir_inline_helpers.h: In function ‘nir_opt_move_block’:../mesa-22.1.3/src/compiler/nir/nir_opt_move.c:55:1: error: inlining failed in call to
always_inline ‘src_is_ssa’: indirect function call with a yet undetermined callee
src_is_ssa(nir_src *src, void *state)
^~~~~~~~~~
Remove 'ALWAYS_INLINE' for function src_is_ssa.
--- .../mesa/files/0001-nir-fix-build-at-Og.patch | 31 +++++++++++++++++++ meta/recipes-graphics/mesa/mesa.inc | 1 + 2 files changed, 32 insertions(+) create mode 100644 meta/recipes-graphics/mesa/files/0001-nir-fix-build-at-Og.patch
meta/recipes-graphics/mesa/files/0001-nir-fix-build-at-Og.patch new file +31 -0
@@ -0,0 +1,31 @@ +At -Og with gcc 12.1, it fails to compile: + +../mesa-22.1.3/src/compiler/nir/nir_inline_helpers.h: In function ‘nir_opt_move_block’: +../mesa-22.1.3/src/compiler/nir/nir_opt_move.c:55:1: error: inlining failed in call to always_inline ‘src_is_ssa’: indirect function call with a yet undetermined callee src_is_ssa(nir_src *src, void *state) + ^~~~~~~~~~ + +Remove 'ALWAYS_INLINE' for function src_is_ssa. + +Upstream-Status: Submitted [https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17589] + +Signed-off-by: Kai Kang <[email protected]> +--- + src/compiler/nir/nir_opt_move.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/compiler/nir/nir_opt_move.c b/src/compiler/nir/nir_opt_move.c +index 81bcde5c436..09db6717002 100644 +--- a/src/compiler/nir/nir_opt_move.c ++++ b/src/compiler/nir/nir_opt_move.c +@@ -51,7 +51,7 @@ + * lower register pressure. + */ + +-static ALWAYS_INLINE bool ++static bool + src_is_ssa(nir_src *src, void *state) + { + return src->is_ssa; +-- +2.34.1 +
meta/recipes-graphics/mesa/mesa.inc +1 -0
@@ -22,6 +22,7 @@ SRC_URI = "https://mesa.freedesktop.org/archive/mesa-${PV}.tar.xz \ file://0001-util-format-Check-for-NEON-before-using-it.patch \ file://0001-Revert-egl-wayland-deprecate-drm_handle_format-and-d.patch \ file://0001-swrast_kms-use-swkmsDRI2Extension-instead-of-driDRI2.patch \ + file://0001-nir-fix-build-at-Og.patch \ " SRC_URI[sha256sum] = "b98f32ba7aa2a1ff5725fb36eb999c693079f0ca16f70aa2f103e2b6c3f093e3"
Signature · 1 line
2.17.1
This patch has been rejected upstream, please switch for https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17439 instead.
Ross
Quoted 82 lines · kai via lists.openembedded.org
From: Kai Kang <[email protected]>
It fails to compile mesa-native when
DEBUG_BUILDis enabled:
../mesa-22.1.3/src/compiler/nir/nir_inline_helpers.h: In function ‘nir_opt_move_block’:../mesa-22.1.3/src/compiler/nir/nir_opt_move.c:55:1: error: inlining failed in call to
always_inline‘src_is_ssa’: indirect function call with a yet undetermined calleesrc_is_ssa(nir_src *src, void *state)
^~~~~~~~~~Remove '
ALWAYS_INLINE' for functionsrc_is_ssa.Signed-off-by Kai Kang <[email protected]>---
.../mesa/files/0001-nir-fix-build-at-Og.patch| 31 +++++++++++++++++++
meta/recipes-graphics/mesa/mesa.inc | 1 +2 files changed, 32 insertions(+)create mode 100644
meta/recipes-graphics/mesa/files/0001-nir-fix-build-at-Og.patchmeta/recipes-graphics/mesa/files/0001-nir-fix-build-at-Og.patch new file +31
-0@@ -0,0 +1,31 @@ +At -Og with gcc 12.1, it fails to compile: + +../mesa-22.1.3/src/compiler/nir/nir_inline_helpers.h: In function ‘nir_opt_move_block’: +../mesa-22.1.3/src/compiler/nir/nir_opt_move.c:55:1: error: inlining failed in call to always_inline ‘src_is_ssa’: indirect function call with a yet undetermined callee src_is_ssa(nir_src *src, void *state) + ^~~~~~~~~~ + +Remove 'ALWAYS_INLINE' for function src_is_ssa. + +Upstream-Status: Submitted [https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17589] + +Signed-off-by: Kai Kang <[email protected]> +--- + src/compiler/nir/nir_opt_move.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/compiler/nir/nir_opt_move.c b/src/compiler/nir/nir_opt_move.c +index 81bcde5c436..09db6717002 100644 +--- a/src/compiler/nir/nir_opt_move.c ++++ b/src/compiler/nir/nir_opt_move.c +@@ -51,7 +51,7 @@ + * lower register pressure. + */ + +-static ALWAYS_INLINE bool ++static bool + src_is_ssa(nir_src *src, void *state) + { + return src->is_ssa; +-- +2.34.1 +meta/recipes-graphics/mesa/mesa.inc +1
-0@@ -22,6 +22,7 @@ SRC_URI = "https://mesa.freedesktop.org/archive/mesa-${PV}.tar.xz \ file://0001-util-format-Check-for-NEON-before-using-it.patch \ file://0001-Revert-egl-wayland-deprecate-drm_handle_format-and-d.patch \ file://0001-swrast_kms-use-swkmsDRI2Extension-instead-of-driDRI2.patch \ + file://0001-nir-fix-build-at-Og.patch \ "SRC_URI[sha256sum] = "
b98f32ba7aa2a1ff5725fb36eb999c693079f0ca16f70aa2f103e2b6c3f093e3"Signature · 10 lines
2.17.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#168189): https://lists.openembedded.org/g/openembedded-core/message/168189 Mute This Topic: https://lists.openembedded.org/mt/92451455/6875888 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
Quoted 1 line · Ross Burton
This patch has been rejected upstream, please switch for https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17439 instead.
OK.
Kai
Quoted 85 lines
Ross
Quoted 82 lines · kai via lists.openembedded.org
From: Kai Kang <[email protected]>
It fails to compile mesa-native when
DEBUG_BUILDis enabled:
../mesa-22.1.3/src/compiler/nir/nir_inline_helpers.h: In function ‘nir_opt_move_block’:../mesa-22.1.3/src/compiler/nir/nir_opt_move.c:55:1: error: inlining failed in call to
always_inline‘src_is_ssa’: indirect function call with a yet undetermined calleesrc_is_ssa(nir_src *src, void *state)
^~~~~~~~~~Remove '
ALWAYS_INLINE' for functionsrc_is_ssa.Signed-off-by Kai Kang <[email protected]>---
.../mesa/files/0001-nir-fix-build-at-Og.patch| 31 +++++++++++++++++++
meta/recipes-graphics/mesa/mesa.inc | 1 +2 files changed, 32 insertions(+)create mode 100644
meta/recipes-graphics/mesa/files/0001-nir-fix-build-at-Og.patchmeta/recipes-graphics/mesa/files/0001-nir-fix-build-at-Og.patch new file +31
-0@@ -0,0 +1,31 @@ +At -Og with gcc 12.1, it fails to compile: + +../mesa-22.1.3/src/compiler/nir/nir_inline_helpers.h: In function ‘nir_opt_move_block’: +../mesa-22.1.3/src/compiler/nir/nir_opt_move.c:55:1: error: inlining failed in call to always_inline ‘src_is_ssa’: indirect function call with a yet undetermined callee src_is_ssa(nir_src *src, void *state) + ^~~~~~~~~~ + +Remove 'ALWAYS_INLINE' for function src_is_ssa. + +Upstream-Status: Submitted [https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17589] + +Signed-off-by: Kai Kang <[email protected]> +--- + src/compiler/nir/nir_opt_move.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/compiler/nir/nir_opt_move.c b/src/compiler/nir/nir_opt_move.c +index 81bcde5c436..09db6717002 100644 +--- a/src/compiler/nir/nir_opt_move.c ++++ b/src/compiler/nir/nir_opt_move.c +@@ -51,7 +51,7 @@ + * lower register pressure. + */ + +-static ALWAYS_INLINE bool ++static bool + src_is_ssa(nir_src *src, void *state) + { + return src->is_ssa; +-- +2.34.1 +meta/recipes-graphics/mesa/mesa.inc +1
-0@@ -22,6 +22,7 @@ SRC_URI = "https://mesa.freedesktop.org/archive/mesa-${PV}.tar.xz \ file://0001-util-format-Check-for-NEON-before-using-it.patch \ file://0001-Revert-egl-wayland-deprecate-drm_handle_format-and-d.patch \ file://0001-swrast_kms-use-swkmsDRI2Extension-instead-of-driDRI2.patch \ + file://0001-nir-fix-build-at-Og.patch \ "SRC_URI[sha256sum] = "
b98f32ba7aa2a1ff5725fb36eb999c693079f0ca16f70aa2f103e2b6c3f093e3"Signature · 10 lines
2.17.1 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#168189): https://lists.openembedded.org/g/openembedded-core/message/168189 Mute This Topic: https://lists.openembedded.org/mt/92451455/6875888 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
Signature · 2 lines
Kai Kang Wind River Linux