aarch64: Add support for Armv8.8-A
authorRichard Sandiford <richard.sandiford@arm.com>
Thu, 2 Dec 2021 15:00:56 +0000 (15:00 +0000)
committerRichard Sandiford <richard.sandiford@arm.com>
Thu, 2 Dec 2021 15:00:56 +0000 (15:00 +0000)
This patch adds skeleton support for -march=armv8.8-a, testing only
that it correctly inherits from armv8.7-a.

include/
* opcode/aarch64.h (AARCH64_FEATURE_V8_8): New macro.
(AARCH64_ARCH_V8_8): Likewise.

gas/
* doc/c-aarch64.texi: Document armv8.8-a.
* config/tc-aarch64.c (aarch64_archs): Add armv8-8-a
* testsuite/gas/aarch64/v8-8-a.s,
* testsuite/gas/aarch64/v8-8-a.d: New test.

gas/config/tc-aarch64.c
gas/doc/c-aarch64.texi
gas/testsuite/gas/aarch64/v8-8-a.d [new file with mode: 0644]
gas/testsuite/gas/aarch64/v8-8-a.s [new file with mode: 0644]
include/opcode/aarch64.h

index 497c126ea83bf5b034563bd5a31d4659f6baccfc..2181fa12bfd4f142817904974c49e33c8a3adae3 100644 (file)
@@ -9820,6 +9820,7 @@ static const struct aarch64_arch_option_table aarch64_archs[] = {
   {"armv8.5-a", AARCH64_ARCH_V8_5},
   {"armv8.6-a", AARCH64_ARCH_V8_6},
   {"armv8.7-a", AARCH64_ARCH_V8_7},
+  {"armv8.8-a", AARCH64_ARCH_V8_8},
   {"armv8-r",  AARCH64_ARCH_V8_R},
   {"armv9-a",  AARCH64_ARCH_V9},
   {NULL, AARCH64_ARCH_NONE}
index 6c3996362663936c6c1480f391f191e5bc961c8d..3051b6f6d76f97c0d4247a37ecff2ef1206b168f 100644 (file)
@@ -110,8 +110,8 @@ issue an error message if an attempt is made to assemble an
 instruction which will not execute on the target architecture.  The
 following architecture names are recognized: @code{armv8-a},
 @code{armv8.1-a}, @code{armv8.2-a}, @code{armv8.3-a}, @code{armv8.4-a}
-@code{armv8.5-a}, @code{armv8.6-a}, @code{armv8.7-a}, @code{armv8-r}, and
-@code{armv9-a}.
+@code{armv8.5-a}, @code{armv8.6-a}, @code{armv8.7-a}, @code{armv8.8-a},
+@code{armv8-r}, and @code{armv9-a}.
 
 If both @option{-mcpu} and @option{-march} are specified, the
 assembler will use the setting for @option{-mcpu}.  If neither are
diff --git a/gas/testsuite/gas/aarch64/v8-8-a.d b/gas/testsuite/gas/aarch64/v8-8-a.d
new file mode 100644 (file)
index 0000000..50fb822
--- /dev/null
@@ -0,0 +1,2 @@
+# objdump: -dr
+#...
diff --git a/gas/testsuite/gas/aarch64/v8-8-a.s b/gas/testsuite/gas/aarch64/v8-8-a.s
new file mode 100644 (file)
index 0000000..f2568ef
--- /dev/null
@@ -0,0 +1,5 @@
+       .arch armv8.8-a
+
+       ld64b x0, [x1]
+       dsb oshnxs
+       msr hcrx_el2, x0
index fa79aa9c25a9988fe9fc0dfb72eb2ddc9e28f884..493b7973f1c10e471f00f6c80f01c0c8e1188b10 100644 (file)
@@ -94,6 +94,7 @@ typedef uint32_t aarch64_insn;
 #define AARCH64_FEATURE_V9          (1ULL << 56) /* Armv9.0-A processors.  */
 #define AARCH64_FEATURE_SME_F64             (1ULL << 57) /* SME F64.  */
 #define AARCH64_FEATURE_SME_I64             (1ULL << 58) /* SME I64.  */
+#define AARCH64_FEATURE_V8_8        (1ULL << 59) /* Armv8.8 processors.  */
 
 /* Crypto instructions are the combination of AES and SHA2.  */
 #define AARCH64_FEATURE_CRYPTO (AARCH64_FEATURE_SHA2 | AARCH64_FEATURE_AES)
@@ -141,6 +142,8 @@ typedef uint32_t aarch64_insn;
 #define AARCH64_ARCH_V8_7      AARCH64_FEATURE (AARCH64_ARCH_V8_6,     \
                                                 AARCH64_FEATURE_V8_7   \
                                                 | AARCH64_FEATURE_LS64)
+#define AARCH64_ARCH_V8_8      AARCH64_FEATURE (AARCH64_ARCH_V8_7,     \
+                                                AARCH64_FEATURE_V8_8)
 #define AARCH64_ARCH_V8_R      (AARCH64_FEATURE (AARCH64_ARCH_V8_4,    \
                                                 AARCH64_FEATURE_V8_R)  \
                              & ~(AARCH64_FEATURE_V8_A | AARCH64_FEATURE_LOR))