* gdb.texinfo (Index Section Format): Change the version to 5.
Describe the different formula.
gdb/
Case insensitive lookups implementation.
* dwarf2read.c: Include ctype.h.
(struct mapped_index): New field version.
(mapped_index_string_hash): New parameter index_version. New comment
for it. Call tolower appropriately.
(find_slot_in_mapped_hash): New variable cmp, initialize it, use it.
Choose the right index version for mapped_index_string_hash.
(dwarf2_read_index): Support also the index version 5. Initialize the
new struct mapped_index field version.
(hash_strtab_entry): Pass INT_MAX for the new parameter, explain why.
(find_slot): Explain the version needs. Pass INT_MAX for the new
parameter.
(write_psymtabs_to_index): Produce version 5.
* minsyms.c (lookup_minimal_symbol): New variable cmp, initialize it,
use it. New comment for SYMBOL_MATCHES_SEARCH_NAME.
* psymtab.c (lookup_partial_symbol): Find the
SYMBOL_MATCHES_SEARCH_NAME start of the found block of matching
entries.
* symtab.c (lookup_symbol_in_language): Remove the case_sensitive_off
NAME lowercasing.
(search_symbols): Pass REG_ICASE to regcomp for case_sensitive_off.
(completion_list_add_name): New variable ncmp, initialize it, use it.
* symtab.h (SYMBOL_HASH_NEXT): Always call tolower.
* utils.c (strcmp_iw): Support case_sensitive_off.
(strcmp_iw_ordered): Sort in a way compatible with case_sensitive_off.
New function comment part. New variables saved_string1,
saved_string2 and case_pass. Add a proper second pass.
gdb/testsuite/
* gdb.base/fortran-sym-case.c: New file.
* gdb.base/fortran-sym-case.exp: New file.
* gdb.dwarf2/dw2-case-insensitive-debug.S: New file.
* gdb.dwarf2/dw2-case-insensitive.c: New file.
* gdb.dwarf2/dw2-case-insensitive.exp: New file.
Replace re_comp/re_exec by regcomp/regexec.
* symtab.c (struct search_symbols_data): New fields preg, preg_p.
(search_symbols_name_matches): Use them, use regexec.
(search_symbols): New variable retval_chain, adjust the use of
old_chain against it. Replace re_comp by regcomp. Use the new struct
search_symbols_data fields, use regexec instead of re_exec.
Format the code for the next patch.
* dwarf2read.c (struct mapped_index): Include delimiting newlines.
* utils.c (strcmp_iw_ordered): Reformat the code for the next patch.
New variables c1 and c2.
* lib/gdb.exp (gdb_test_multiple): Eror on newline in $message.
* gdb.base/ifelse.exp: Give names to the "" tests as `if true else
false #1', `if true else false #2' and `if true else false #3'.
* infrun.c (proceed): Do not single-step into signal delivery
when stepping off a breakpoint location.
(insert_step_resume_breakpoint_at_frame): Move prototype earlier.
(insert_step_resume_breakpoint_at_caller): Likewise.
(insert_step_resume_breakpoint_at_sal): Likewise.
(insert_longjmp_resume_breakpoint): Likewise.
testsuite/ChangeLog:
* gdb.base/annota1.exp: Accept breakpoints-invalid annotation
while delivering signal.
add to_pass_signals.
(target_notice_signals): Remove.
(target_pass_signals): Add prototype.
* target.c (update_current_target): Remove to_notice_signals;
mention to_pass_signals.
(target_pass_signals): New function.
(debug_to_notice_signals): Remove.
(setup_target_debug): Do not install debug_to_notice_signals.
* infrun.c (signal_pass): New global.
(resume): Call target_pass_signals.
(handle_inferior_event): Report all signals while stepping over
non-steppable watchpoint. Reset trap_expected to ensure breakpoints
are re-inserted when stepping over a signal handler.
(signal_cache_update): New function.
(signal_stop_update): Call it.
(signal_print_update): Likewise.
(signal_pass_update): Likewise.
(handle_command): Call signal_cache_update and target_pass_signals
instead of target_notice_signals.
(_initialize_infrun): Initialize signal_pass.
* linux-nat.c (pass_mask): New global.
(linux_nat_pass_signals): New function.
(linux_nat_create_inferior): Report all signals initially.
(linux_nat_attach): Likewise.
(linux_nat_resume): Use pass_mask to decide whether to directly
handle an inferior signal.
(linux_nat_wait_1): Likewise.
(linux_nat_add_target): Install to_pass_signals callback.
* nto-procfs.c (notice_signals): Remove.
(procfs_resume): Do not call notice_signals.
(procfs_notice_signals): Remove.
(procfs_pass_signals): New function.
(init_procfs_ops): Install to_pass_signals callback instead of
to_notice_signals callback.
(_initialize_procfs): Report all signals initially.
* procfs.c (procfs_notice_signals): Remove.
(procfs_pass_signals): New function.
(procfs_target): Install to_pass_signals callback instead of
to_notice_signals callback.
(register_gdb_signals): Remove.
(procfs_debug_inferior): Report all signals initially.
(procfs_init_inferior): Remove redundant register_gdb_signals call.
* remote.c (remote_pass_signals): Add numsigs and pass_signals
parameters; use them instead of calling signal_..._state routines.
(remote_notice_signals): Remove.
(remote_start_remote): Report all signals initially.
(remote_resume): Do not call remote_pass_signals.
(_initialize_remote): Install to_pass_signals callback instead of
to_notice_signals callback.
gdb/
* breakpoint.c (user_settable_breakpoint): Delete.
(user_breakpoint_p): Remove check on user_settable_breakpoint.
(delete_command): Check user_breakpoint_p instead of looking at
the breakpoint's type.
(disable_command): Ditto.
(enable_command): Ditto.
(delete_trace_command): Use user_breakpoint_p instead of looking
at the breakpoint number directly. When checking if there are
user visible tracepoints, in order to know whether to ask the user
for confirmation, check whether the breakpoint is actually a
tracepoint.
* linux-nat.c: Move common macros to ...
Include linux-ptrace.h.
* common/linux-ptrace.h: ... here. New.
gdb/gdbserver/
* linux-low.c: Move common macros to linux-ptrace.h.
Include linux-ptrace.h.
* Makefile.in (linux_ptrace_h): New.
(linux-low.o): Depends on linux-ptrace.h.
(dwcfi_hash): New static hash variable.
(get_debugseg_name): New.
(alloc_debugseg_item): New.
(make_debug_seg): New.
(dwcfi_hash_insert): New.
(dwcfi_hash_find): New.
(dwcfi_hash_find_or_make): New.
(cfi_insn_data): New member cur_seg.
(cie_entry): Likewise.
(fde_entry): New cseg and handled members.
(alloc_fde_entry): Initialize cseg member.
(alloc_cfi_insn_data): Initialize cur_seg member.
(dot_cfi_sections): Compare for beginning of
section names via strncmp.
(get_cfi_seg): New.
(cfi_finish): Treat link-once sections.
(is_now_linkonce_segment): New local helper.
(output_cie): Ignore cie entries not member of current
segment.
(output_fde): Likewise.
(select_cie_for_fde): Likewise.
(cfi_change_reg_numbers): Add new argument for current segment
and ignore insn elements, if not part of current segment.
* ehopt.c (get_cie_info): Use strncmp for
section name matching.
(heck_eh_frame): Likewise.
* coffcode.h (sec_to_styp_flags): Allow linkonce for
debugging sections.
* scripttempl/pe.sc: Handle .eh_frame($|.)* sections.
* scripttempl/pep.sc: Likewise.
* ld-pe/pe.exp: Add cfi/cfi32 tests.
* ld-pe/cfi.d: New.
* ld-pe/cfi32.d: New.
* ld-pe/cfia.s: New.
* ld-pe/cfib.s: New.
Make all of the pins bidirectional, and support sending signals when
software drives the pins as outputs.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
When the mask a/b MMRs are written, the output signal might change levels
(as pins are [un]masked), so make sure we update the output level.
Further, make sure we handle edge ints correctly by first sending a high
signal followed by a low signal.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
symbol info for each input file.
* incremental.cc
(Output_section_incremental_inputs::set_final_data_size): Add local
symbol info to input file entries in incremental info.
(Output_section_incremental_inputs::write_info_blocks): Likewise.
(Sized_incr_relobj::Sized_incr_relobj): Initialize new data members.
(Sized_incr_relobj::do_add_symbols): Cosmetic change.
(Sized_incr_relobj::do_count_local_symbols): Replace stub with
implementation.
(Sized_incr_relobj::do_finalize_local_symbols): Likewise.
(Sized_incr_relobj::do_relocate): Write the local symbols.
(Sized_incr_dynobj::do_add_symbols): Cosmetic change.
* incremental.h (Incremental_inputs_reader::get_symbol_offset):
Adjust size of input file header.
(Incremental_inputs_reader::get_local_symbol_offset): New function.
(Incremental_inputs_reader::get_local_symbol_count): New function.
(Incremental_inputs_reader::get_input_section): Adjust size of input
file header.
(Incremental_inputs_reader::get_global_symbol_reader): Likewise.
(Sized_incr_relobj::This): New typedef.
(Sized_incr_relobj::sym_size): New const data member.
(Sized_incr_relobj::Local_symbol): New struct.
(Sized_incr_relobj::do_output_local_symbol_count): New function.
(Sized_incr_relobj::do_local_symbol_offset): New function.
(Sized_incr_relobj::local_symbol_count_): New data member.
(Sized_incr_relobj::output_local_dynsym_count_): New data member.
(Sized_incr_relobj::local_symbol_index_): New data member.
(Sized_incr_relobj::local_symbol_offset_): New data member.
(Sized_incr_relobj::local_dynsym_offset_): New data member.
(Sized_incr_relobj::local_symbols_): New data member.
* object.h (Relobj::output_local_symbol_count): New function.
(Relobj::local_symbol_offset): New function.
(Relobj::do_output_local_symbol_count): New function.
(Relobj::do_local_symbol_offset): New function.
(Sized_relobj::do_output_local_symbol_count): New function.
(Sized_relobj::do_local_symbol_offset): New function.
* elfread.c (elf_symfile_read): Protect dwarf2_initialize_objfile by
!objfile_has_partial_symbols. New comment.
* objfiles.c (objfile_has_partial_symbols): Call HAS_SYMBOLS if
SYM_READ_PSYMBOLS is not present. Extend the comment.
* symfile.h (struct sym_fns): Extend the sym_read_psymbols comment.
gdb/testsuite/
* gdb.base/gdbindex-stabs-dwarf.c: New file.
* gdb.base/gdbindex-stabs.c: New file.
* gdb.base/gdbindex-stabs.exp: New file.
PR ld/12696
include/
* bfdlink.h (ENUM_BITFIELD): Define.
(struct bfd_link_hash_entry): Make "type" a bitfield. Add "non_ir_ref".
(struct bfd_link_callbacks <notice>): Pass bfd_link_hash_entry pointer
rather than "name".
bfd/
* coff-aux.c (coff_m68k_aux_link_add_one_symbol): Update "notice" call.
* linker.c (_bfd_link_hash_newfunc): Clear bitfields.
(_bfd_generic_link_add_one_symbol): Update "notice" call.
* elflink.c (_bfd_elf_merge_symbol): Don't skip weak redefs when
it is a redef of an IR symbol in a real BFD.
ld/
* ldmain.c (notice): Delete "name" param, add "h".
* plugin.c (plugin_notice): Likewise. Set non_ir_ref. Handle
redefinitions of IR symbols in real BFDs.
(plugin_multiple_definition, plugin_multiple_common): Delete.
(non_ironly_hash, init_non_ironly_hash): Delete.
(is_visible_from_outside): Traverse entry_symbol chain.
(get_symbols): Use non_ir_ref flag rather than hash lookup.
* NEWS: Document the new gdbserver --once option.
gdb/doc/
* gdb.texinfo (Starting and Stopping Trace Experiments): New anchor
for disconnected tracing.
(Multi-Process Mode for @code{gdbserver}): Mention --multi and
extended-remote relationship. Mention --once.
(TCP port allocation lifecycle of @code{gdbserver}): New.
gdb/gdbserver/
* remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
(remote_prepare): New function with most of the TCP code from ...
(remote_open): ... here. Detect PORT here unconditionally. Move also
setting transport_is_reliable.
* server.c (run_once): New variable.
(gdbserver_usage): Document it.
(main): Set run_once for `--once'. Call remote_prepare. Exit after
the first run if RUN_ONCE.
* server.h (run_once, remote_prepare): New declarations.
gdb/testsuite/
* gdb.base/solib-disc.exp: Set gdbserver_reconnect_p.
* lib/gdb.exp (gdb_init): Clear gdbserver_reconnect_p.
* lib/gdbserver-support.exp (gdbserver_start): Add `--once' if
!gdbserver_reconnect_p..
(gdbserver_reconnect): Call error if !gdbserver_reconnect_p..
global symbol map.
(Sized_incremental_binary::do_apply_incremental_relocs): New function.
(Sized_incr_relobj::do_add_symbols): Add symbols to global symbol map.
(Sized_incr_relobj::do_relocate): Remap section indices in incremental
relocations.
(Sized_incr_dynobj::do_add_symbols): Add symbols to global symbol map.
(Sized_incr_dynobj::do_for_all_global_symbols): Remove FIXME.
(Sized_incr_dynobj::do_for_all_local_got_entries): Likewise.
* incremental.h
(Incremental_inputs_reader::global_symbol_reader_at_offset): New
function.
(Incremental_binary::apply_incremental_relocs): New function.
(Incremental_binary::do_apply_incremental_relocs): New function.
(Sized_incremental_binary::Sized_incremental_binary): Initialize new
data member.
(Sized_incremental_binary::add_global_symbol): New function.
(Sized_incremental_binary::global_symbol): New function.
(Sized_incremental_binary::do_apply_incremental_relocs): New function.
(Sized_incremental_binary::symbol_map_): New data member.
* layout.cc (Layout_task_runner::run): Apply incremental relocations.
* target.h (Sized_target::apply_relocation): New function.
* target-reloc.h (apply_relocation): New function.
* x86_64.cc (Target_x86_64::apply_relocation): New function.
* arm.cc (Arm_output_section::Arm_output_section): Set SHF_LINK_ORDER
flag of a SHT_ARM_EXIDX section.
* testsuite/Makefile.am (arm_exidx_test): New test rules.
* testsuite/Makefile.in: Regenerate.
* testsuite/arm_exidx_test.s: New file.
* testsuite/arm_exidx_test.sh: Same.