Discussion:
[PATCH, BINUTILS, AARCH64, 4/9] Add Execution and Data Restriction instructions
Sudakshina Das
2018-09-19 14:21:27 UTC
Permalink
Hi

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)

This patch adds the prediction restriction instructions (that is, cfp,
dvp, cpp). These instructions are retrospectively made optional for all
versions of the architecture from ARMv8.0 to ARMv8.4 and is mandatory
from ARMv8.5. Hence adding a new +predres which can be used by the older
architectures.

Testing done: Builds and reg tests all pass on aarch64-none-linux-gnu
and aarch64-none-elf. Added new tests.

Ok for trunk?

Thanks
Sudi
PS. I do not have commit access so if OK can someone apply for me?
Also the patch was too big to attach due to the regenerated files.



*** include/ChangeLog ***

2018-xx-xx Sudakshina Das <***@arm.com>

* opcode/aarch64.h (AARCH64_FEATURE_PREDRES): New.
(AARCH64_ARCH_V8_5): Add AARCH64_FEATURE_PREDRES by default.
(aarch64_opnd): Add AARCH64_OPND_SYSREG_SR.
(aarch64_sys_regs_sr): Declare new table.

*** opcodes/ChangeLog ***

2018-xx-xx Sudakshina Das <***@arm.com>

* aarch64-dis.c (aarch64_ext_sysins_op): Add case for
AARCH64_OPND_SYSREG_SR.
* aarch64-opc.c (aarch64_print_operand): Likewise.
(aarch64_sys_regs_sr): Define table.
(aarch64_sys_ins_reg_supported_p): Check for RCTX with
AARCH64_FEATURE_PREDRES.
* aarch64-tbl.h (aarch64_feature_predres): New.
(PREDRES, PREDRES_INSN): New.
(aarch64_opcode_table): Add entries for cfp, dvp and cpp.
(AARCH64_OPERANDS): Add new description for SYSREG_SR.
* aarch64-asm-2.c: Regenerate.
* aarch64-dis-2.c: Regenerate.
* aarch64-opc-2.c: Regenerate.

*** gas/ChangeLog ***

2018-xx-xx Sudakshina Das <***@arm.com>

* config/tc-aarch64.c (aarch64_sys_regs_sr_hsh): New.
(parse_operands): Add entry for AARCH64_OPND_SYSREG_SR.
(md_begin): Allocate and initialize aarch64_sys_regs_sr_hsh
with aarch64_sys_regs_sr.
(aarch64_features): Add new "predres" option for older
architectures.
* doc/c-aarch64.texi: Document the same.
* testsuite/gas/aarch64/sysreg-4.s: New.
* testsuite/gas/aarch64/sysreg-4.d: New.
* testsuite/gas/aarch64/illegal-sysreg-4.d: New.
* testsuite/gas/aarch64/illegal-sysreg-4.l: New.
* testsuite/gas/aarch64/predres.s: New.
* testsuite/gas/aarch64/predres.d: New.
Sudakshina Das
2018-10-08 11:48:41 UTC
Permalink
Hi Richard
Post by Sudakshina Das
Hi
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)
This patch adds the prediction restriction instructions (that is, cfp,
dvp, cpp). These instructions are retrospectively made optional for all
versions of the architecture from ARMv8.0 to ARMv8.4 and is mandatory
from ARMv8.5. Hence adding a new +predres which can be used by the older
architectures.
Testing done: Builds and reg tests all pass on aarch64-none-linux-gnu
and aarch64-none-elf. Added new tests.
Ok for trunk?
Thanks
Sudi
PS. I do not have commit access so if OK can someone apply for me?
Also the patch was too big to attach due to the regenerated files.
Based on our ofline conversation, I have updated the patch and added
suitable comments to show why I am masking out op2 for rctx. I had
also missed a WO flag for rctx previously.
Please find the new one attached. The ChangeLog still applies.

Thanks
Sudi
Post by Sudakshina Das
*** include/ChangeLog ***
          * opcode/aarch64.h (AARCH64_FEATURE_PREDRES): New.
          (AARCH64_ARCH_V8_5): Add AARCH64_FEATURE_PREDRES by default.
          (aarch64_opnd): Add AARCH64_OPND_SYSREG_SR.
          (aarch64_sys_regs_sr): Declare new table.
*** opcodes/ChangeLog ***
          * aarch64-dis.c (aarch64_ext_sysins_op): Add case for
          AARCH64_OPND_SYSREG_SR.
          * aarch64-opc.c (aarch64_print_operand): Likewise.
          (aarch64_sys_regs_sr): Define table.
          (aarch64_sys_ins_reg_supported_p): Check for RCTX with
          AARCH64_FEATURE_PREDRES.
          * aarch64-tbl.h (aarch64_feature_predres): New.
          (PREDRES, PREDRES_INSN): New.
          (aarch64_opcode_table): Add entries for cfp, dvp and cpp.
          (AARCH64_OPERANDS): Add new description for SYSREG_SR.
          * aarch64-asm-2.c: Regenerate.
          * aarch64-dis-2.c: Regenerate.
          * aarch64-opc-2.c: Regenerate.
*** gas/ChangeLog ***
          * config/tc-aarch64.c (aarch64_sys_regs_sr_hsh): New.
          (parse_operands): Add entry for AARCH64_OPND_SYSREG_SR.
          (md_begin): Allocate and initialize aarch64_sys_regs_sr_hsh
          with aarch64_sys_regs_sr.
          (aarch64_features): Add new "predres" option for older
          architectures.
    * doc/c-aarch64.texi: Document the same.
          * testsuite/gas/aarch64/sysreg-4.s: New.
          * testsuite/gas/aarch64/sysreg-4.d: New.
          * testsuite/gas/aarch64/illegal-sysreg-4.d: New.
          * testsuite/gas/aarch64/illegal-sysreg-4.l: New.
          * testsuite/gas/aarch64/predres.s: New.
          * testsuite/gas/aarch64/predres.d: New.
Continue reading on narkive:
Loading...