[PATCH, BINUTILS, AARCH64, 5/9] Add DC CVADP instruction
authorSudakshina Das <sudi.das@arm.com>
Wed, 26 Sep 2018 09:54:07 +0000 (10:54 +0100)
committerRichard Earnshaw <Richard.Earnshaw@arm.com>
Tue, 9 Oct 2018 14:39:29 +0000 (15:39 +0100)
This patch is part of the patch series to add support for ARMv8.5-A
extensions.
(https://developer.arm.com/products/architecture/cpu-architecture/a-profile/docs/ddi0596/a/a64-base-instructions-alphabetic-order/dc-data-cache-operation-an-alias-of-sys)

This patch adds the DC CVADP instruction. Since this has a separate
identification mechanism a new feature bit is added.

*** include/ChangeLog ***

2018-10-09  Sudakshina Das  <sudi.das@arm.com>

* opcode/aarch64.h (AARCH64_FEATURE_CVADP): New.

*** opcodes/ChangeLog ***

2018-10-09  Sudakshina Das  <sudi.das@arm.com>

* aarch64-opc.c (aarch64_sys_regs_dc): New entry for cvadp.
(aarch64_sys_ins_reg_supported_p): New check for above.

*** gas/ChangeLog ***

2018-10-09  Sudakshina Das  <sudi.das@arm.com>

* testsuite/gas/aarch64/sysreg-4.s: Test instruction.
* testsuite/gas/aarch64/sysreg-4.d: Likewise.
* testsuite/gas/aarch64/illegal-sysreg-4.l: Likewise.

gas/ChangeLog
gas/testsuite/gas/aarch64/illegal-sysreg-4.l
gas/testsuite/gas/aarch64/sysreg-4.d
gas/testsuite/gas/aarch64/sysreg-4.s
include/ChangeLog
include/opcode/aarch64.h
opcodes/ChangeLog
opcodes/aarch64-opc.c

index 6fa3e72e1e6f3d71adff00d074014a8b2703855e..f9582774d631f71d50b8e3b18f656518342fabc6 100644 (file)
@@ -1,3 +1,9 @@
+2018-10-09  Sudakshina Das  <sudi.das@arm.com>
+
+       * testsuite/gas/aarch64/sysreg-4.s: Test instruction.
+       * testsuite/gas/aarch64/sysreg-4.d: Likewise.
+       * testsuite/gas/aarch64/illegal-sysreg-4.l: Likewise.
+
 2018-10-09  Sudakshina Das  <sudi.das@arm.com>
 
        * config/tc-aarch64.c (aarch64_sys_regs_sr_hsh): New.
index 68471a17bd096931674efb2a40fd04980d60617e..f3167e3824f7d21a62e783146251dc5d9673b0cb 100644 (file)
@@ -5,3 +5,4 @@
 [^:]*:[0-9]+: Error: selected processor does not support `dvp rctx,x2'
 [^:]*:[0-9]+: Error: selected processor does not support system register name 'rctx'
 [^:]*:[0-9]+: Error: selected processor does not support `cpp rctx,x3'
+[^:]*:[0-9]+: Error: selected processor does not support system register name 'cvadp'
index f3ea5d1b96a5be47d73d66a02883429a946813ef..1c14016beac9cca24e90e3139f3db950416e785f 100644 (file)
@@ -10,3 +10,4 @@ Disassembly of section \.text:
 .*:    d50b7381        cfp     rctx, x1
 .*:    d50b73a2        dvp     rctx, x2
 .*:    d50b73e3        cpp     rctx, x3
+.*:    d50b7d24        dc      cvadp, x4
index 6ec069ac957e0d1fa094f641633b49d74b673907..49907c0b22e8a0eb9dae0fc9c4ba5adfdd232074 100644 (file)
@@ -3,3 +3,4 @@ func:
        cfp rctx, x1
        dvp rctx, x2
        cpp rctx, x3
+       dc cvadp, x4
index be7072aa5bf63c1967f7ce732e570d793095ea19..499312d5d4186cd5c0c0f682346a437b223a3ffd 100644 (file)
@@ -1,3 +1,7 @@
+2018-10-09  Sudakshina Das  <sudi.das@arm.com>
+
+       * opcode/aarch64.h (AARCH64_FEATURE_CVADP): New.
+
 2018-10-09  Sudakshina Das  <sudi.das@arm.com>
 
        * opcode/aarch64.h (AARCH64_FEATURE_PREDRES): New.
index 7b542c9d5088807965c047a8114cc0b322e4cb38..7656a577f792a1962d8d0ea422e0ca4bb9ed6bf1 100644 (file)
@@ -72,6 +72,8 @@ typedef uint32_t aarch64_insn;
 #define AARCH64_FEATURE_SB             0x10000000000ULL
 /* Execution and Data Prediction Restriction instructions.  */
 #define AARCH64_FEATURE_PREDRES                0x20000000000ULL
+/* DC CVADP.  */
+#define AARCH64_FEATURE_CVADP          0x40000000000ULL
 
 /* Architectures are the sum of the base and extensions.  */
 #define AARCH64_ARCH_V8                AARCH64_FEATURE (AARCH64_FEATURE_V8, \
@@ -100,7 +102,8 @@ typedef uint32_t aarch64_insn;
                                                 | AARCH64_FEATURE_FLAGMANIP \
                                                 | AARCH64_FEATURE_FRINTTS \
                                                 | AARCH64_FEATURE_SB   \
-                                                | AARCH64_FEATURE_PREDRES)
+                                                | AARCH64_FEATURE_PREDRES \
+                                                | AARCH64_FEATURE_CVADP)
 
 
 #define AARCH64_ARCH_NONE      AARCH64_FEATURE (0, 0)
index 8a5cbf52d02567f32e1c88370cc4824e38f6c78c..37bfeebddc34500a11e94da6604ad4cd735e275c 100644 (file)
@@ -1,3 +1,8 @@
+2018-10-09  Sudakshina Das  <sudi.das@arm.com>
+
+       * aarch64-opc.c (aarch64_sys_regs_dc): New entry for cvadp.
+       (aarch64_sys_ins_reg_supported_p): New check for above.
+
 2018-10-09  Sudakshina Das  <sudi.das@arm.com>
 
        * aarch64-dis.c (aarch64_ext_sysins_op): Add case for
index f3c436cf4d6e97334b3d724447767c1b3c4581df..9562ba85d8ce2b09ae31e6b3c129f1e5c486360f 100644 (file)
@@ -4349,6 +4349,7 @@ const aarch64_sys_ins_reg aarch64_sys_regs_dc[] =
     { "csw",       CPENS (0, C7, C10, 2), F_HASXT },
     { "cvau",       CPENS (3, C7, C11, 1), F_HASXT },
     { "cvap",       CPENS (3, C7, C12, 1), F_HASXT | F_ARCHEXT },
+    { "cvadp",      CPENS (3, C7, C13, 1), F_HASXT | F_ARCHEXT },
     { "civac",      CPENS (3, C7, C14, 1), F_HASXT },
     { "cisw",       CPENS (0, C7, C14, 2), F_HASXT },
     { 0,       CPENS(0,0,0,0), 0 }
@@ -4488,6 +4489,11 @@ aarch64_sys_ins_reg_supported_p (const aarch64_feature_set features,
       && !AARCH64_CPU_HAS_FEATURE (features, AARCH64_FEATURE_V8_2))
     return FALSE;
 
+  /* DC CVADP.  Values are from aarch64_sys_regs_dc.  */
+  if (reg->value == CPENS (3, C7, C13, 1)
+      && !AARCH64_CPU_HAS_FEATURE (features, AARCH64_FEATURE_CVADP))
+    return FALSE;
+
   /* AT S1E1RP, AT S1E1WP.  Values are from aarch64_sys_regs_at.  */
   if ((reg->value == CPENS (0, C7, C9, 0)
        || reg->value == CPENS (0, C7, C9, 1))