da19c18af2
Update 002-vc4-add-meson-option-to-disable-optional-neon-suppor.patch to fix an syntax error introduced by commit 'package/{mesa3d, mesa3d-headers}: bump version to 23.1.0' ([1]) Fixes: .../build/mesa3d-23.1.2/src/gallium/drivers/vc4/meson.build:87:76: ERROR: Trying to compare values of different types (UserFeatureOption, str) using !=. This was deprecated and undefined behavior previously and is as of 0.60.0 a hard error. [1] https://git.buildroot.net/buildroot/commit/?id=e6203db11ed40122a2d9f29012db5683a7eb10d0 Signed-off-by: Peter Seiderer <ps.report@gmx.net> Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
87 lines
2.9 KiB
Diff
87 lines
2.9 KiB
Diff
From f719e942dde0a46a9ff0080001cb3466012ffcc0 Mon Sep 17 00:00:00 2001
|
|
From: Peter Seiderer <ps.report@gmx.net>
|
|
Date: Mon, 9 Mar 2020 13:01:14 +0100
|
|
Subject: [PATCH] vc4: add meson option to disable optional neon support
|
|
|
|
Not all toolchains are able to compile the runtime
|
|
optional vc4 neon support, so add an meson option
|
|
to force disabling it at compile time.
|
|
|
|
Upstream: https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4114
|
|
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
|
|
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
|
|
[rebased for 20.2.0, 20.3.0, 21.1.0 & 23.1.0]
|
|
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
|
|
[fix syntax error after previous rebases]
|
|
---
|
|
meson_options.txt | 7 +++++++
|
|
src/gallium/drivers/vc4/meson.build | 4 ++--
|
|
src/gallium/drivers/vc4/vc4_tiling.h | 4 ++--
|
|
3 files changed, 11 insertions(+), 4 deletions(-)
|
|
|
|
diff --git a/meson_options.txt b/meson_options.txt
|
|
index 8e0bf2a..1cf0e07 100644
|
|
--- a/meson_options.txt
|
|
+++ b/meson_options.txt
|
|
@@ -116,6 +116,13 @@ option(
|
|
description : 'enable gallium va frontend.',
|
|
)
|
|
|
|
+option(
|
|
+ 'gallium-vc4-neon',
|
|
+ type : 'feature',
|
|
+ deprecated: {'true': 'enabled', 'false': 'disabled'},
|
|
+ description : 'enable gallium vc4 optional neon support.',
|
|
+)
|
|
+
|
|
option(
|
|
'va-libs-path',
|
|
type : 'string',
|
|
diff --git a/src/gallium/drivers/vc4/meson.build b/src/gallium/drivers/vc4/meson.build
|
|
index 84da951..7f950de 100644
|
|
--- a/src/gallium/drivers/vc4/meson.build
|
|
+++ b/src/gallium/drivers/vc4/meson.build
|
|
@@ -84,7 +84,7 @@ files_libvc4 = files(
|
|
vc4_c_args = []
|
|
|
|
libvc4_neon = []
|
|
-if host_machine.cpu_family() == 'arm'
|
|
+if host_machine.cpu_family() == 'arm' and not get_option('gallium-vc4-neon').disabled()
|
|
libvc4_neon = static_library(
|
|
'vc4_neon',
|
|
'vc4_tiling_lt_neon.c',
|
|
@@ -93,7 +93,7 @@ if host_machine.cpu_family() == 'arm'
|
|
],
|
|
c_args : '-mfpu=neon',
|
|
)
|
|
- vc4_c_args += '-DUSE_ARM_ASM'
|
|
+ vc4_c_args += '-DVC4_TILING_LT_NEON'
|
|
endif
|
|
|
|
if dep_simpenrose.found()
|
|
diff --git a/src/gallium/drivers/vc4/vc4_tiling.h b/src/gallium/drivers/vc4/vc4_tiling.h
|
|
index 5afe329..919b299 100644
|
|
--- a/src/gallium/drivers/vc4/vc4_tiling.h
|
|
+++ b/src/gallium/drivers/vc4/vc4_tiling.h
|
|
@@ -89,7 +89,7 @@ vc4_load_lt_image(void *dst, uint32_t dst_stride,
|
|
void *src, uint32_t src_stride,
|
|
int cpp, const struct pipe_box *box)
|
|
{
|
|
-#ifdef USE_ARM_ASM
|
|
+#ifdef VC4_TILING_LT_NEON
|
|
if (util_get_cpu_caps()->has_neon) {
|
|
vc4_load_lt_image_neon(dst, dst_stride, src, src_stride,
|
|
cpp, box);
|
|
@@ -105,7 +105,7 @@ vc4_store_lt_image(void *dst, uint32_t dst_stride,
|
|
void *src, uint32_t src_stride,
|
|
int cpp, const struct pipe_box *box)
|
|
{
|
|
-#ifdef USE_ARM_ASM
|
|
+#ifdef VC4_TILING_LT_NEON
|
|
if (util_get_cpu_caps()->has_neon) {
|
|
vc4_store_lt_image_neon(dst, dst_stride, src, src_stride,
|
|
cpp, box);
|
|
--
|
|
2.41.0
|
|
|