[PATCH 11/12] s390: Add CC_HAS_ASM_M_FORMAT_FLAG config option
From: Heiko Carstens
Date: Thu Sep 17 2026 - 15:52:26 EST
Add CONFIG_CC_HAS_ASM_M_FORMAT_FLAG as an indicator if the compiler
supports the 'M' operand modifier in inline assemblies. The 'M' modifier
allows to access the odd register of a TImode operand. Clang support for
this modifier was added recently to llvm-project [1].
The config option can be used to write conditional code depending on
compiler features.
[1] 28c23411e15f ("[SystemZ] Support the 'M' code for the odd register in inline-asm (#215481)")
Signed-off-by: Heiko Carstens <hca@xxxxxxxxxxxxx>
---
arch/s390/Kconfig | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
index 4b51bc6e8948..f1fbbf6eb50a 100644
--- a/arch/s390/Kconfig
+++ b/arch/s390/Kconfig
@@ -66,6 +66,12 @@ config CC_HAS_ASM_AOR_FORMAT_FLAGS
Clang versions before 19.1.0 do not support A,
O, and R inline assembly format flags.
+config CC_HAS_ASM_M_FORMAT_FLAG
+ def_bool !(CC_IS_CLANG && CLANG_VERSION < 240100)
+ help
+ Clang versions before 24.1.0 do not support the
+ M inline assembly format flags.
+
config CC_HAS_ASM_IMMEDIATE_STRINGS
def_bool !(CC_IS_GCC && GCC_VERSION < 90000)
help
--
2.53.0