]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit - gas/ChangeLog
[GAS, Arm] CLI with architecture sensitive extensions
authorAndre Vieira <andre.simoesdiasvieira@arm.com>
Mon, 1 Apr 2019 09:43:32 +0000 (10:43 +0100)
committerAndre Vieira <andre.simoesdiasvieira@arm.com>
Mon, 1 Apr 2019 09:43:32 +0000 (10:43 +0100)
commit34ef62f46541d423b991850b2b7ba34d8749a6ba
tree79824aa5fb2396b92bbe93ff81c4c124717d6a8e
parent52093e1b936fa4f3f8bb3868c5a44d0df25c8db4
[GAS, Arm] CLI with architecture sensitive extensions

This patch adds a new framework to add architecture sensitive extensions, like
GCC does.  This patch also implements all architecture extensions currently
available in GCC.

This framework works as follows.  To enable architecture sensitive extensions
for a particular architecture, that architecture must contain an ARM_ARCH_OPT2
entry in the 'arm_archs' table.  All fields here are the same as previous, with
the addition of a new extra field at the end to <name> it's extension table.
This <name>, corresponds to a <name>_ext_table of type 'struct arm_ext_table'.
This struct can be filled with three types of entries:

  ARM_ADD (string <ext>, arm_feature_set <enable_bits>), which means +<ext> will
      enable <enable_bits>
  ARM_REMOVE (string <ext>, arm_feature_set <disable_bits>), which means
      +no<ext> will disable <disable_bits>
  ARM_EXT (string <ext>, arm_feature_set <enable_bits>, arm_feature_set
      <disable_bits>), which means +<ext> will enable <enable_bits> and +no<ext>
      will disable <disable_bits> (this is to be used instead of adding an
      ARM_ADD and ARM_REMOVE for the same <ext>)

This patch does not disable the use of the old extensions, even if some of them
are duplicated in the new tables.  This is a "in-between-step" as we may want to
deprecate the old table of extensions in later patches.  For now, GAS will first
look for the +<ext> or +no<ext> in the new table and if no entry is found it
will continue searching in the old table, following old behaviour.  If only an
ARM_ADD or an ARM_REMOVE is defined for <ext> and +no<ext> or +<ext> resp. is
used then it also continues to search the old table for it.

A couple of caveats:
- This patch does not enable the use of these architecture extensions with the
'.arch_extension' directive.  This is future work that I will tend to later.
- This patch does not enable the use of these architecture extensions with the
-mcpu option.  This is future work that I will tend to later.
- This patch does not change the current behaviour when combining an
architecture extension and using -mfpu on the command-line.  The current
behaviour of GAS is to stage the union of feature bits enabled by both -march
and -mfpu.  GCC behaves differently here, so this is something we may want to
revisit on a later date.
43 files changed:
gas/ChangeLog
gas/config/tc-arm.c
gas/doc/c-arm.texi
gas/testsuite/gas/arm/armv8-2-fp16-scalar-bad-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8-2-fp16-scalar-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8-2-fp16-scalar-thumb-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8-2-fp16-simd-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8-2-fp16-simd-thumb-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8-2-fp16-simd-warning-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8-2-fp16-simd-warning-thumb-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8_2+rdma-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8_2-a-fp16-thumb2-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8_2-a-fp16_ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8_3-a-fp-bad-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8_3-a-fp-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8_3-a-fp16-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8_3-a-simd-bad-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8_4-a-fp16-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8m.main+fp.d [new file with mode: 0644]
gas/testsuite/gas/arm/armv8m.main+fp.dp.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-fpv5-d16.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-fpv5.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-idiv.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-mp.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-neon-fp16.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-neon-vfpv3.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-neon-vfpv4.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-sec.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv3-d16-fp16.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv3-d16.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv3-fp16.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv3.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv3xd-fp.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv3xd.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv4-d16.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv4-sp-d16.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-ext-vfpv4.d [new file with mode: 0644]
gas/testsuite/gas/arm/attr-mfpu-neon-fp16.d
gas/testsuite/gas/arm/dotprod-mandatory-ext.d [new file with mode: 0644]
gas/testsuite/gas/arm/fpv5-d16.s [new file with mode: 0644]
gas/testsuite/gas/arm/fpv5-sp-d16.s [new file with mode: 0644]
include/ChangeLog
include/opcode/arm.h