2000-06-20 Frank Ch. Eigler <fche@redhat.com>
* compile.c: Don't include "wait.h".
(sim_resume): Use local SIM_WIFEXITED and SIM_WIFSIGNALED macros
instead of WIF* from host.
* elf-bfd.h (struct elf_obj_tdata): Define per BFD Irix 5 virtual
sections elf_{text,data}_{section,symbol}.
* elf32-mips.c: mips_elf_{text,data}_{section,symbol}{,_ptr}: Remove.
(_bfd_mips_elf_hide_symbol): New function.
(elf_backend_hide_symbol): Map to the new function.
(_bfd_mips_elf_add_symbol_hook): Change to use new per BFD
definitions of mips_elf_{text,data}_{section,symbol}.
(mips_elf_local_relocation_p): Try to find the direct symbol
based on new check_forced argument.
(mips_elf_calculate_relocation): Use new version of
mips_elf_local_relocation_p.
(mips_elf_relocate_section): Likewise.
(_bfd_mips_elf_relocate_section): Likewise.
(mips_elf_sort_hash_table): Only assert that have enough GOT
space.
(mips_elf_got16_entry): Match all 32 bits to the existing GOT
entry if the relocation based on the new external argument.
(mips_elf_create_dynamic_relocation): Assert that we have a
section contents allocated where we can swap out the dynamic
relocations.
(mips_elf_calculate_relocation): Find the real hash-table entry
correctly by using h->root.root.type. Only create a dynamic
relocation entry if the symbol is defined in a shared library.
Create an external GOT entry for the GOT16 relocation if the
symbol was forced local.
(_bfd_mips_elf_finish_dynamic_symbol): Don't assert there is a
dynamic index if the symbol was forced local.
2000-06-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
* elf32-mips.c: Fix typos in comments.
(nindy_xfer_inferior_memory): Use dcache_xfer_memory() instead of
breaking transfer into chunks and using nindy_fetch_word() and
nindy_store_word().
* remote-bug.c (bug_xfer_memory): Use dcache_xfer_memory() instead
of breaking transfer into chunks and using gr_fetch_word() and
gr_store_word().
* remote.c (remote_fetch_word, remote_store_word): Removed.
* remote-utils.h (gr_fetch_word, gr_store_word): Removed.
* remote-utils.c (gr_fetch_word, gr_store_word): Removed.
* dcache.h (dcache_fetch, dcache_poke, dcache_poke_block): Removed.
* dcache.c (dcache_fetch, dcache_poke): Removed.
* coff-i386.c (coff_i386_reloc): Don't return in case of
output_bfd == (bfd *) NULL if COFF_WITH_PE is defined.
Compensate PE relocations when linking with non-PE object
files to generate a non-PE executable.
* elflink.h (elf_link_adjust_relocs): Check for and call backend
specifific swap_reloc_{in,out} and swap_reloca_{in,out} if
available.
(elf_link_output_relocs): Likewise.
(elf_reloc_link_order): Likewise.
support. Incorporate most of tm-rs6000.h.
(find_toc_address_hook): Rename to rs6000_find_toc_address_hook.
(rs6000_set_host_arch_hook): Declare.
(read_memory_addr): Define.
(pop_frame): Rename to rs6000_pop_frame.
(rs6000_pop_frame, rs6000_fix_call_dummy, rs6000_push_arguments,
rs6000_frame_saved_pc, rs6000_frame_chain): Remove non-generic
dummy frame handling.
(branch_dest, rs6000_pop_frame, rs6000_skip_trampoline_code,
rs6000_frame_saved_pc, frame_get_saved_regs,
frame_initial_stack_address, rs6000_frame_chain,
rs6000_convert_from_func_ptr_addr): Call read_memory_addr instead
of read_memory_integer.
(branch_dest, rs6000_pop_frame, rs6000_push_arguments,
rs6000_skip_trampoline_code, rs6000_frame_saved_pc,
frame_get_saved_regs, frame_initial_stack_address,
rs6000_frame_chain): Replace 4 with TDEP->wordsize.
(skip_prologue): Recognize some 64-bit stack adjustments.
(push_dummy_frame, pop_dummy_frame, set_processor,
show_processor): Delete.
(frame_get_saved_regs): Manipulate saved register addresses using
CORE_ADDR instead of int.
(rs6000_create_inferior): New function.
(register_names_*[]): Change to struct reg registers_*[].
(variants[]): Assimilate into multi-arch approach.
(register_names_*[], variants[]): Refer to pre-PowerPC
architectures as POWER instead of RS6000.
* rs6000-nat.c: Ubiquitous changes for 64-bit support.
(vmap_secs, xcoff_relocate_symtab): Cast addresses
to unsigned long to avoid sign-extension errors.
(set_host_arch): New function.
(xcoff_relocate_symtab): Try disabling usleep(36000) workaround.
(rs6000_core_fns): Use new bfd_target_xcoff_flavour.
(_initialize_core_rs6000): Initialize rs6000_set_host_arch_hook.
* symfile.c (find_sym_fns): Remove special xcoff kludge.
* xcoffread.c (secnum_to_bfd_section): Initialize args.objfile.
(process_linenos): Query line struct size from coff
backend instead of using compile-time constant.
(enter_line_range): Likewise.
(read_xcoff_symtab): Pass "XCOFF64" instead of "XCOFF" to
record_debugformat() if appropriate.
(process_xcoff_symbol): Access symbol addresses using
SYMBOL_VALUE_ADDRESS instead of SYMBOL_VALUE.
(read_symbol_lineno): Retrieve XCOFF64 symbol names from strtbl.
(scan_xcoff_symtab): Likewise. Query syment struct size from
coff backend instead of using compile-time constant.
(xcoff_sym_fns): Set flavour to bfd_target_xcoff_flavour.
* Makefile.in (INTERNAL_LDFLAGS): Add $(MH_LDFLAGS) to list of flags
that this Makefile variable get set to. (From Kevin Buettner.)
* config/powerpc/aix.mh (MH_LDFLAGS): Add linker flags so that
the TOC doesn't overflow. (From Kevin Buettner.)
* config/powerpc/tm-ppc-aix.h: Move config decisions to
multi-arched rs6000-tdep.c.
* config/rs6000/tm-rs6000.h: Likewise.
(GDB_MULTI_ARCH): Define.
(skip_trampoline_code): Rename to rs6000_skip_trampoline_code.
(is_magic_function_pointer): Replace with
rs6000_convert_from_func_ptr_addr.
(TARGET_CREATE_INFERIOR_HOOK): Define.
(find_toc_address_hook): Rename to rs6000_find_toc_address_hook.
(rs6000_set_host_arch_hook): Declare.
* config/rs6000/nm-rs6000.h (CHILD_XFER_MEMORY): Define.
PowerPc and RS6000 machine numbers.
* bfd-in2.h: Regenerate.
* coffcode.h (coff_set_arch_mach_hook): #ifdef XCOFF64, set arch
to bfd_arch_powerpc instead of bfd_arch_rs6000. Refer to PowerPc
and RS6000 machine numbers using #defined constants from
archures.c.
* cpu-powerpc.c (arch_info_struct): Refer to PowerPc and RS6000
machine numbers using #defined constants from archures.c. Add
entries for EC603e, 630, A35, RS64II, RS64III, 7400. Specify
64-bit words in 620 entry.
* cpu-rs6000.c (arch_info_struct): Create with entries for RS1,
RSC, and RS2.
(bfd_rs6000_arch): Change default machine to 0 (bfd_mach_rs6k).