diff options
author | DJ Delorie <dj@redhat.com> | 2014-01-22 16:41:13 -0500 |
---|---|---|
committer | DJ Delorie <dj@redhat.com> | 2014-01-22 16:41:13 -0500 |
commit | 96b961024c796c5a609fd4d6a772b060eb3b6197 (patch) | |
tree | 30d3aac9493b2671f13696cb3316952f9c56f3b9 /gas/config/tc-msp430.c | |
parent | 7c84a0ca904a7a80262506f70ccbe09f99a68535 (diff) | |
download | gdb-96b961024c796c5a609fd4d6a772b060eb3b6197.zip gdb-96b961024c796c5a609fd4d6a772b060eb3b6197.tar.gz gdb-96b961024c796c5a609fd4d6a772b060eb3b6197.tar.bz2 |
Add .refsym to msp430 backend
* config/tc-msp430.c (msp430_refsym): New: ".refsym <symbol>"
* doc/c-msp430.texi (MSP430 Directives): Document it.
The purpose of this patch is to provide a way for one object file
to require the inclusion of another object, without having to
allocate space for a .word address reference.
Diffstat (limited to 'gas/config/tc-msp430.c')
-rw-r--r-- | gas/config/tc-msp430.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/gas/config/tc-msp430.c b/gas/config/tc-msp430.c index c2a7b9b..189319e 100644 --- a/gas/config/tc-msp430.c +++ b/gas/config/tc-msp430.c @@ -1257,6 +1257,15 @@ msp430_section (int arg) obj_elf_section (arg); } +static void +msp430_refsym (int arg ATTRIBUTE_UNUSED) +{ + char sym_name[1024]; + input_line_pointer = extract_word (input_line_pointer, sym_name, 1024); + + (void) symbol_find_or_make (sym_name); +} + const pseudo_typeS md_pseudo_table[] = { {"arch", msp430_set_arch, OPTION_MMCU}, @@ -1267,6 +1276,7 @@ const pseudo_typeS md_pseudo_table[] = {"sect", msp430_section, 0}, {"sect.s", msp430_section, 0}, {"pushsection", msp430_section, 1}, + {"refsym", msp430_refsym, 0}, {NULL, NULL, 0} }; |