* lib/gdb.exp: Revert patch of 2003-01-06, which set LC_ALL.
This was a workaround for a UTF-8 bug in readline 4.3. The bug
has been fixed in gdb/readline on 2003-01-09.
* d10v-tdep.c: Include "frame-unwind.h".
(d10v_gdbarch_init): Append d10v_frame_p to the unwind predicate
list.
(next_addr, uses_frame): Delete.
(struct d10v_unwind_cache): Define.
(prologue_find_regs): Add struct d10v_unwind_cache info parameter.
Use info instead of next_addr and uses_frame globals.
(d10v_frame_init_saved_regs): Delete function.
(d10v_init_extra_frame_info): Delete function.
(d10v_gdbarch_init): Do not initialize init_extra_frame_info,
frame_init_saved_regs or pop_frame, frame_chain, frame_chain_valid,
init_frame_pc or frame_saved_pc.
(d10v_pop_frame): Delete function.
(do_d10v_pop_frame): Delete function.
(d10v_frame_chain): Delete function.
(d10v_frame_chain_valid): Delete function.
(d10v_frame_pc_unwind): New function.
(d10v_frame_id_unwind): New function.
(saved_regs_unwinder): New function.
(d10v_frame_register_unwind): New function.
(d10v_frame_pop): New function.
(d10v_frame_unwind): New variable.
(d10v_frame_p): New function.
(d10v_frame_saved_pc): Delete function.
* Makefile.in (d10v-tdep.o): Update dependencies.
* frame.c (frame_saved_regs_id_unwind): Assert FRAME_CHAIN_P.
(legacy_get_prev_frame): Assert FRAME_CHAIN_P.
(get_prev_frame): When FRAME_CHAIN_P, call legacy_get_prev_frame.
(frame_saved_regs_pc_unwind): Assert FRAME_SAVED_PC_P.
* gdbarch.sh (FRAME_CHAIN): Change to a function with predicate.
(FRAME_SAVED_PC): Change to a function with predicate.
* gdbarch.h, gdbarch.c: Re-generate.
(struct mips_got_entry): Make symndx and gotidx signed. Moved
addend into union along with address and link hash entry.
(struct mips_got_info): Added bfd2got and next.
(struct mips_elf_hash_sort_data): Added max_unref_got_dynindx.
(mips_elf_got_section, mips_elf_create_got_section): Use
SEC_EXCLUDE bit to tell whether we really need the got
section. Take boolean arguments to disregard an excluded
section, or to create it as excluded. Adjust all callers.
Use mips_elf_got_section all over.
(mips_elf_local_got_index, mips_elf_got_page,
mips_elf_got16_entry): Take input bfd as argument, and pass it
on to mips_elf_create_local_got_entry.
(mips_elf_global_got_index, mips_elf_create_local_got_entry):
Take input bfd as argument, and manage entries in the
appropriate GOT.
(mips_elf_got_offset_from_index): Take input bfd as argument,
and use it to adjust the GP offset of the bfd.
(mips_elf_sort_hash_table, mips_elf_sort_hash_table_f): Move
unreferenced GOT entries of global symbols to the end.
(mips_elf_record_global_got_symbol): Take input bfd as
argument. Add entries to the master GOT hash table.
(struct mips_elf_bfd2got_hash): New.
(struct mips_elf_got_per_bfd_arg): New.
(struct mips_elf_set_global_got_offset_arg): New.
(mips_elf_hash_bfd_vma, mips_elf_multi_got_entry_hash,
mips_elf_multi_got_entry_eq, mips_elf_bfd2got_entry_hash,
mips_elf_bfd2got_entry_eq, mips_elf_make_got_per_bfd,
mips_elf_merge_gots, mips_elf_set_global_got_offset,
mips_elf_resolve_final_got_entry,
mips_elf_resolve_final_got_entries, mips_elf_adjust_gp,
mips_elf_got_for_ibfd): New functions.
(ELF_MIPS_GP_OFFSET): Don't depend on SGI_COMPAT.
(MIPS_ELF_GOT_MAX_SIZE): New macro.
(STUB_LW): Generate 64-bit stub regardless of SGI_COMPAT.
(mips_elf_got_entry_hash): Take new fields into account. Use
mips_elf_hash_bfd_vma.
(mips_elf_got_entry_eq): Take new fields into account.
(mips_elf_create_got_section): Initialize new fields.
(mips_elf_calculate_relocation): Pass input_bfd to functions
that now take it. Adjust gp for the input_bfd.
(mips_elf_allocate_dynamic_relocation,
mips_elf_create_dynamic_relocation,
_bfd_mips_elf_create_dynamic_sections): Use...
(mips_elf_rel_dyn_section): New function. Borrow code from...
(_bfd_mips_elf_check_relocs): Pass input_bfd to functions that
now take it. Create the got section if needed, even if
excluded, before recording a global got symbol. Move some
code to...
(mips_elf_record_local_got_symbol): New fn.
(_bfd_mips_elf_size_dynamic_sections): Disable combreloc.
Compute multi-got global entries offsets. Move GOT code to...
(_bfd_mips_elf_always_size_sections): Call mips_elf_multi_got
if the GOT is too big.
(_bfd_mips_elf_finish_dynamic_symbol): Set got entry of
undefweak symbol to zero. Generate dynamic relocations for
non-primary GOT entries for global symbols.
(_bfd_mips_elf_finish_dynamic_sections): Handle multi-got
case. Generate dynamic relocations for local got entries.
Sort dynamic relocations on N64 too, using...
(sort_dynamic_relocs_64): New fns.
(_bfd_mips_elf_hide_symbol): Adjust multi-got counters.
(_bfd_mips_elf_merge_private_bfd_data): Ignore EF_MIPS_XGOT.
* configure: Rebuilt.
* config/te-irix.h: New file.
* config/tc-mips.c (mips_dwarf2_format): Use TE_IRIX to decide
whether to use Irix-specific 64-bit format.
* sentinel-frame.h, sentinel-frame.c: New files.
* Makefile.in (frame.o): Update dependencies.
(SFILES): Add sentinel-frame.c.
(sentinel_frame_h): Define.
(COMMON_OBS): Add sentinel-frame.o.
(sentinel-frame.o): Specify dependencies.
* frame.c: Include "sentinel-frame.h".
(frame_register_unwind): Rewrite assuming that there is always a a
->next frame.
(frame_register, generic_unwind_get_saved_register): Ditto.
(frame_read_unsigned_register, frame_read_signed_register): Ditto.
(create_sentinel_frame, unwind_to_current_frame): New functions.
(get_current_frame): Rewrite using create_sentinel_frame and
unwind_to_current_frame. When possible, always create a frame.
(create_new_frame): Set next to the sentinel frame.
(get_next_frame): Rewrite. Don't go below the level 0 frame.
(deprecated_update_frame_pc_hack): Update the next frame's PC and
ID cache when necessary.
(frame_saved_regs_id_unwind): Use frame_relative_level.
(deprecated_generic_get_saved_register): Use frame_relative_level,
get_frame_saved_regs, get_frame_pc, get_frame_base and
get_next_frame.
(frame_saved_regs_register_unwind): Use get_frame_saved_regs and
frame_register.