diff options
author | Nick Clifton <nickc@redhat.com> | 2015-04-09 12:48:37 +0100 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2015-04-09 12:48:37 +0100 |
commit | 3525236c57a64fdbb534671fd2b16f9f846d36f3 (patch) | |
tree | 9b1b9e0a444216011509526254fccedcf34ca1c5 /include/elf | |
parent | 5a2d4533e2b9cc9c069d47071013cb30f1e0fc7e (diff) | |
download | gdb-3525236c57a64fdbb534671fd2b16f9f846d36f3.zip gdb-3525236c57a64fdbb534671fd2b16f9f846d36f3.tar.gz gdb-3525236c57a64fdbb534671fd2b16f9f846d36f3.tar.bz2 |
Add support to the RX toolchain to restrict the use of string instructions.
bfd * elf32-rx.c (describe_flags): Report the settings of the string
insn using bits.
(rx_elf_merge_private_bfd_data): Handle merging of the string insn
using bits.
bin * readelf.c (get_machine_flags): Report the setting of the string
insn using bits.
gas * config/tc-rx.c (enum options): Add OPTION_DISALLOW_STRING_INSNS.
(md_longopts): Add -mno-allow-string-insns.
(md_parse_option): Handle -mno-allow-string-insns.
(md_show_usage): Mention -mno-allow-string-insns.
(rx_note_string_insn_use): New function. Produces an error
message if a string insn is used when it is not allowed.
* config/rx-parse.y (SCMPU): Call rx_note_string_insn_use.
(SMOVU, SMOVB, SMOVF, SUNTIL, SWHILE, RMPA): Likewise.
* config/rx-defs.h (rx_note_string_insn_use): Prototype.
* doc/c-rx.texi: Document -mno-allow-string-insns.
elf * rx.h (E_FLAG_RX_SINSNS_SET): New bit in e_flags field.
(E_FLAG_RX_SINSNS_YES): Likewise.
(E_FLAG_RX_SINSNS_MASK): New define.
Diffstat (limited to 'include/elf')
-rw-r--r-- | include/elf/ChangeLog | 6 | ||||
-rw-r--r-- | include/elf/rx.h | 5 |
2 files changed, 11 insertions, 0 deletions
diff --git a/include/elf/ChangeLog b/include/elf/ChangeLog index 55bc60c..d66e507 100644 --- a/include/elf/ChangeLog +++ b/include/elf/ChangeLog @@ -1,3 +1,9 @@ +2015-04-09 Nick Clifton <nickc@redhat.com> + + * rx.h (E_FLAG_RX_SINSNS_SET): New bit in e_flags field. + (E_FLAG_RX_SINSNS_YES): Likewise. + (E_FLAG_RX_SINSNS_MASK): New define. + 2015-04-03 H.J. Lu <hongjiu.lu@intel.com> * external.h (Elf32_External_Chdr): New. diff --git a/include/elf/rx.h b/include/elf/rx.h index de367d2..f945dac 100644 --- a/include/elf/rx.h +++ b/include/elf/rx.h @@ -120,6 +120,11 @@ END_RELOC_NUMBERS (R_RX_max) #define E_FLAG_RX_PID (1 << 2) /* Unofficial - DJ */ #define E_FLAG_RX_ABI (1 << 3) /* Binary passes stacked arguments using natural alignment. Unofficial - NC. */ +#define E_FLAG_RX_SINSNS_SET (1 << 6) /* Set if bit-5 is significant. */ +#define E_FLAG_RX_SINSNS_YES (1 << 7) /* Set if string instructions are used in the binary. */ +#define E_FLAG_RX_SINSNS_NO 0 /* Bit-5 if this binary must not be linked with a string instruction using binary. */ +#define E_FLAG_RX_SINSNS_MASK (3 << 6) /* Mask of bits used to determine string instruction use. */ + /* These define the addend field of R_RX_RH_RELAX relocations. */ #define RX_RELAXA_IMM6 0x00000010 /* Imm8/16/24/32 at bit offset 6. */ #define RX_RELAXA_IMM12 0x00000020 /* Imm8/16/24/32 at bit offset 12. */ |