diff options
author | Catherine Moore <clm@redhat.com> | 1998-08-31 16:06:30 +0000 |
---|---|---|
committer | Catherine Moore <clm@redhat.com> | 1998-08-31 16:06:30 +0000 |
commit | cdb3d5f90252e5ba6f88269224eb4373e6a453a7 (patch) | |
tree | 7d30a40c43293692425c30b70f51ab5ccf0f5022 /gas | |
parent | bb3b4377a4cd0eee77ccfce64218ef8e3a34492e (diff) | |
download | gdb-cdb3d5f90252e5ba6f88269224eb4373e6a453a7.zip gdb-cdb3d5f90252e5ba6f88269224eb4373e6a453a7.tar.gz gdb-cdb3d5f90252e5ba6f88269224eb4373e6a453a7.tar.bz2 |
* config/tc-arm.c: Remove OBJ_ELF definitions for
S_GET_STORAGE_CLASS and S_SET_STORAGE_CLASS. Only
use arm_adjust_symtab for OBJ_COFF.
(armelf_adjust_symtab): New Routine.
* config/tc-arm.h: Define obj_adjust_symtab to
armelf_adjust_symtab for OBJ_ELF.
Diffstat (limited to 'gas')
-rw-r--r-- | gas/ChangeLog | 9 | ||||
-rw-r--r-- | gas/config/tc-arm.c | 35 | ||||
-rw-r--r-- | gas/config/tc-arm.h | 7 |
3 files changed, 45 insertions, 6 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index 4e881cc..1a53773 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,12 @@ +Mon Aug 31 10:58:06 1998 Catherine Moore <clm@cygnus.com> + + * config/tc-arm.c: Remove OBJ_ELF definitions for + S_GET_STORAGE_CLASS and S_SET_STORAGE_CLASS. Only + use arm_adjust_symtab for OBJ_COFF. + (armelf_adjust_symtab): New Routine. + * config/tc-arm.h: Define obj_adjust_symtab to + armelf_adjust_symtab for OBJ_ELF. + Sat Aug 29 22:18:51 1998 Richard Henderson <rth@cygnus.com> * configure.in: Make all i386-elf targets use bfd_gas. diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c index a0b6f0a..1b345bd 100644 --- a/gas/config/tc-arm.c +++ b/gas/config/tc-arm.c @@ -6310,13 +6310,13 @@ arm_frob_label (sym) ARM ones. */ #ifdef OBJ_ELF -#define S_GET_STORAGE_CLASS(S) (elf_symbol ((S)->bsym)->internal_elf_sym.st_other) -#define S_SET_STORAGE_CLASS(S,V) (elf_symbol ((S)->bsym)->internal_elf_sym.st_other = (V)) +#define S_GET_STORAGE_CLASS(S) (elf_symbol ((S)->bsym)->internal_elf_sym.st_info) +#define S_SET_STORAGE_CLASS(S,V) (elf_symbol ((S)->bsym)->internal_elf_sym.st_info = (V)) #endif +#ifdef OBJ_COFF void arm_adjust_symtab () { -#if defined OBJ_COFF || defined OBJ_ELF symbolS * sym; for (sym = symbol_rootP; sym != NULL; sym = symbol_next (sym)) @@ -6329,6 +6329,7 @@ arm_adjust_symtab () if ( S_GET_STORAGE_CLASS (sym) == C_STAT || S_GET_STORAGE_CLASS (sym) == C_LABEL) /* This can happen! */ S_SET_STORAGE_CLASS (sym, C_THUMBSTATFUNC); + else if (S_GET_STORAGE_CLASS (sym) == C_EXT) S_SET_STORAGE_CLASS (sym, C_THUMBEXTFUNC); else @@ -6350,14 +6351,36 @@ arm_adjust_symtab () } } -#ifdef OBJ_COFF if (ARM_IS_INTERWORK (sym)) coffsymbol(sym->bsym)->native->u.syment.n_flags = 0xFF; -#endif } +} #endif +#ifdef OBJ_ELF +void +armelf_adjust_symtab () +{ + symbolS * sym; + elf_symbol_type *elf_sym; + char bind; + + for (sym = symbol_rootP; sym != NULL; sym = symbol_next (sym)) + { + if (ARM_IS_THUMB (sym)) + { + if (THUMB_IS_FUNC (sym)) + { + elf_sym = elf_symbol(sym->bsym); + bind = ELF_ST_BIND(elf_sym); + elf_sym->internal_elf_sym.st_info = ELF_ST_INFO(bind, STT_ARM_TFUNC); + } + + } + } } +#endif + #ifdef OBJ_ELF void armelf_frob_symbol (symp, puntp) @@ -6367,6 +6390,7 @@ armelf_frob_symbol (symp, puntp) { elf_frob_symbol (symp, puntp); +/* if (S_IS_EXTERNAL (symp)) S_SET_STORAGE_CLASS(symp, C_EXT); @@ -6378,6 +6402,7 @@ armelf_frob_symbol (symp, puntp) else S_SET_STORAGE_CLASS (symp, C_STAT); } +*/ } #endif int diff --git a/gas/config/tc-arm.h b/gas/config/tc-arm.h index e382662..65024a5 100644 --- a/gas/config/tc-arm.h +++ b/gas/config/tc-arm.h @@ -150,8 +150,13 @@ char *arm_canonicalize_symbol_name PARAMS ((char *)); #endif /* Finish processing the entire symbol table: */ -#define tc_adjust_symtab() arm_adjust_symtab () +#ifdef OBJ_ELF +#define obj_adjust_symtab() armelf_adjust_symtab () +extern void armelf_adjust_symtab PARAMS ((void)); +#else +#define obj_adjust_symtab() arm_adjust_symtab () extern void arm_adjust_symtab PARAMS ((void)); +#endif #if 0 #define tc_crawl_symbol_chain(a) {;} /* not used */ |