diff options
author | Dominik Vogt <vogt@linux.vnet.ibm.com> | 2015-09-29 13:22:07 +0100 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2015-09-29 13:22:07 +0100 |
commit | 7ecc513a44095d614f10e89c67d9be5826abacf9 (patch) | |
tree | 150a49774f29ce8a95989942d9780c3edc10bf17 /opcodes/s390-mkopc.c | |
parent | 56e6cf80bd4be6dc95ed9b84b633e3c11ae8c86b (diff) | |
download | gdb-7ecc513a44095d614f10e89c67d9be5826abacf9.zip gdb-7ecc513a44095d614f10e89c67d9be5826abacf9.tar.gz gdb-7ecc513a44095d614f10e89c67d9be5826abacf9.tar.bz2 |
Add support for extensions in the .machine pseudoop on S/390, e.g. ".machine zEC12+nohtm+vx"
gas * doc/c-s390.texi: Add documentation.
Add missing code markup.
* config/tc-s390.c (current_flags): New static variable.
(s390_parse_cpu): Parse cpu flags a la "+nohtm" etc.
(s390_setup_opcodes): Use cpu flags to determine the set of opcodes.
Fix indentation.
(md_parse_option): Call s390_parse_cpu with the new signature.
(s390_machine): Likewise.
Keep track of current_flags.
Simplify code a bit.
undefine MAX_HISTORY at end of function.
(s390_machinemode): undefine MAX_HISTORY at end of function.
Update an error message.
tests * gas/s390/s390.exp: Add new tests.
* gas/s390/machine-parsing-1.s: New test file.
* gas/s390/machine-parsing-1.l: Likewise.
* gas/s390/machine-parsing-2.s: Likewise.
* gas/s390/machine-parsing-2.l: Likewise.
* gas/s390/machine-parsing-3.s: Likewise.
* gas/s390/machine-parsing-3.l: Likewise.
* gas/s390/machine-parsing-4.s: Likewise.
* gas/s390/machine-parsing-4.l: Likewise.
* gas/s390/machine-parsing-5.s: Likewise.
* gas/s390/machine-parsing-5.l: Likewise.
* gas/s390/machine-parsing-6.s: Likewise.
* gas/s390/machine-parsing-6.l: Likewise.
opcode * s390.h (S390_INSTR_FLAG_HTM): New flag.
(S390_INSTR_FLAG_VX): New flag.
(S390_INSTR_FLAG_FACILITY_MASK): New flag mask.
opcodes * s390-mkopc.c (main): Parse htm and vx flag.
* s390-opc.txt: Mark instructions from the hardware transactional
memory and vector facilities with the "htm"/"vx" flag.
Diffstat (limited to 'opcodes/s390-mkopc.c')
-rw-r--r-- | opcodes/s390-mkopc.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/opcodes/s390-mkopc.c b/opcodes/s390-mkopc.c index 30f58c7..2433977 100644 --- a/opcodes/s390-mkopc.c +++ b/opcodes/s390-mkopc.c @@ -401,6 +401,14 @@ main (void) && (str[7] == 0 || str[7] == ',')) { flag_bits |= S390_INSTR_FLAG_OPTPARM; str += 7; + } else if (strncmp (str, "htm", 3) == 0 + && (str[3] == 0 || str[3] == ',')) { + flag_bits |= S390_INSTR_FLAG_HTM; + str += 3; + } else if (strncmp (str, "vx", 2) == 0 + && (str[2] == 0 || str[2] == ',')) { + flag_bits |= S390_INSTR_FLAG_VX; + str += 2; } else { fprintf (stderr, "Couldn't parse flags string %s\n", flags_string); |