summaryrefslogtreecommitdiff
path: root/gdb/dwarf2loc.c
Commit message (Collapse)AuthorAgeFilesLines
* gdb/qiyao2012-08-021-13/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * dwarf2loc.c (entry_values_debug): Add 'unsigned'. (_initialize_dwarf2loc): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * dwarf2loc.h: Update the declaration of 'entry_values_debug'. * dwarf2read.c (dwarf2_die_debug): Add 'unsigned'. (_initialize_dwarf2_read): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * darwin-nat.c (dwarwin_debug_flag): Add 'unsigned'. (_initialize_darwin_inferior): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * frame.c (frame_debug): Add 'unsigned'. (_intialize_frame): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * frame.h: Update the declaration of 'frame_debug'. * gdbtypes.c (overload_debug): Add 'unsigned'. (_initialize_gdbtypes): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * inferior.h: Update declaration of 'debug_infrun'. * infrun.c (debug_infrun): Add 'unsigned'. (_initialize_infrun): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * jit.c (jit_debug): Add 'unsigned'. (_initialize_jit): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * linux-nat.c (debug_linux_nat): Add 'unsigned'. (_initialize_linux_nat): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * linux-thread-db.c (libthread_db_debug): Add 'unsigned'. (_initialize_thread_db): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * machoread.c (mach_o_debug_level): Add 'unsigned'. (_initialize_machoread): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * mi/mi-cmd-var.c: Update the declaration of 'varobjdebug'. * microblaze-tdep.c (microblaze_debug_flag): Add 'unsigned'. (_initialize_microblaze_tdep): Call add_setshow_zuinteger_cmd intead of add_setshow_zinteger_cmd. * mips-tdep.c (mips_debug): Add 'unsigned'. (_initialize_mips_tdep): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * monitor.c (monitor_debug): Add 'unsigned'. (_initialize_remote_monitors): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * observer.c (observer_debug): Add 'unsigned'. (_initialize_observer): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * parse.c (expressiondebug): Add 'unsigned'. (_initialize_parse): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * record.c (record_debug): Add 'unsigned'. (_initialize_record): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * record.h: Update the declaration of 'record_debug'. * stap-probe.c (stap_expression_debug): Add 'unsigned'. (_initialize_stap_probe): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * serial.c (global_serial_debug_p): Add 'unsigned'. (_initialize_serial): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * solib-dsbt.c (solib_dsbt_debug): Add 'unsigned'. (_initialize_dsbt_solib): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * solib-frv.c (solib_frv_debug): Add 'unsigned'. (_initialize_frv_solib): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * target.c (targetdebug): Add 'unsigned'. (initialize_targets): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * valops.c (overload_debug): Add 'unsigned'. * varobj.c (varobjdebug): Add 'unsigned'. (_initialize_varobj): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * xtensa-tdep.c (xtensa_debug_level): Add 'unsigned'. (_initialize_xtensa_tdep): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * arch-utils.h: Remove the declaration of 'gdbarch_debug'. * gdbarch.sh (gdbarch_debug): Add 'unsigned'. (extern void _initialize_gdbarch): Call add_setshow_zuinteger_cmd instead of add_setshow_zinteger_cmd. * gdbarch.c, gdbarch.h: Re-generated.
* 2012-07-26 Tristan Gingold <gingold@adacore.com>Tristan Gingold2012-07-261-1/+1
| | | | | * dwarf2loc.c (locexpr_describe_location_piece): Use uint64_t for offset.
* * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Expand parametersiddhesh2012-07-261-6/+6
| | | | | | | | | | | | | SIZE to size_t. (dwarf2_evaluate_loc_desc): Likewise. (dwarf2_loc_desc_needs_frame): Likewise. (locexpr_describe_location_1): Likewise. * dwarf2loc.h (struct dwarf2_locexpr_baton): Make SIZE as size_t. (struct dwarf2_loclist_baton): Likewise. * dwarf2read.c (struct dwarf_block): Likewise. (dump_die_shallow): Use pulongest to print dwarf_block.size. (decode_locdesc): Expand SIZE and I to size_t.
* gdb/Jan Kratochvil2012-07-131-0/+6
| | | | | * dwarf2loc.c (disassemble_dwarf_expression): Handle DW_OP_GNU_parameter_ref.
* * dwarf2expr.c (execute_stack_op): Handle DW_OP_GNU_const_index.Doug Evans2012-06-191-1/+37
| | | | | | | | | | | Adjust address for DW_OP_GNU_addr_index. * dwarf2expr.h (dwarf_expr_context): Update comment. * dwarf2loc.c (locexpr_describe_location_piece): New arg per_cu, all callers updated. Handle TLS vars described with DW_OP_GNU_const_index. (disassemble_dwarf_expression): Handle DW_OP_GNU_addr_index and DW_OP_GNU_const_index. * dwarf2read.c (decode_locdesc): Handle DW_OP_GNU_addr_index.
* gdb/Jan Kratochvil2012-06-171-0/+5
| | | | | | | | | | | | | | | | | * dwarf2expr.c (execute_stack_op): Support DW_OP_GNU_parameter_ref. * dwarf2loc.c (call_site_parameter_matches): Support CALL_SITE_PARAMETER_PARAM_OFFSET. (needs_dwarf_reg_entry_value): Push stub value. * dwarf2read.c (read_call_site_scope): New variable origin. Support CALL_SITE_PARAMETER_PARAM_OFFSET and its DW_AT_abstract_origin. * gdbtypes.h (enum call_site_parameter_kind): New item CALL_SITE_PARAMETER_PARAM_OFFSET. (struct call_site.parameter.u): New field param_offset. gdb/testsuite/ * gdb.arch/amd64-entry-value-param.S: New file. * gdb.arch/amd64-entry-value-param.c: New file. * gdb.arch/amd64-entry-value-param.exp: New file.
* gdb/Jan Kratochvil2012-06-171-31/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Code cleanup: Generalize call_site.parameter key. * dwarf2expr.c (execute_stack_op) <DW_OP_GNU_entry_value>: Remove variable dwarf_reg. New variable kind_u. Update parameters to push_dwarf_reg_entry_value. (ctx_no_push_dwarf_reg_entry_value): Update parameters. * dwarf2expr.h (enum call_site_parameter_kind) (union call_site_parameter_u): Forward declarations. (struct dwarf_expr_context_funcs): Update parameters and their description for push_dwarf_reg_entry_value. (ctx_no_push_dwarf_reg_entry_value): Update parameters. * dwarf2loc.c (call_site_parameter_matches): New function. (dwarf_expr_reg_to_entry_parameter): Update parameters and their description. Use call_site_parameter_matches. (dwarf_expr_push_dwarf_reg_entry_value, value_of_dwarf_reg_entry): Update parameters and their description. (value_of_dwarf_block_entry): Remove variables dwarf_reg and fb_offset. New variable kind_u. Adjust the caller for updated parameters. (needs_dwarf_reg_entry_value): Update parameters. * dwarf2read.c (read_call_site_scope): New variable loc. Use it instead of attr. Update for the changed fields of struct call_site_parameter. * gdbtypes.h: Include dwarf2expr.h. (enum call_site_parameter_kind): New. (struct call_site.parameter): New field kind. Wrap dwarf_reg and fb_offset into new union u.
* * dwarf2loc.c (debug_loc_kind): Add DEBUG_LOC_START_LENGTH.Doug Evans2012-06-141-9/+29
| | | | | | | | | (DEBUG_LOC_START_END): Renamed from DEBUG_LOC_NORMAL. All uses updated. (decode_debug_loc_dwo_addresses): New arg "byte_order". All callers updated. Handle DEBUG_LOC_START_LENGTH. (dwarf2_find_location_expression): Handle DEBUG_LOC_START_LENGTH. (loclist_describe_location): Ditto.
* * dwarf2-frame.c (execute_cfa_program): Update to handle long long ->Doug Evans2012-05-241-15/+15
| | | | | | | | | | | | | | | | int64_t change to leb128 API. (read_encoded_value, decode_frame_entry_1): Ditto. * dwarf2expr.c (safe_read_uleb128, safe_read_sleb128): Ditto. (dwarf_block_to_dwarf_reg, dwarf_block_to_dwarf_reg_deref): Ditto. (dwarf_block_to_fb_offset, dwarf_block_to_sp_offset): Ditto. (execute_stack_op): Ditto. * dwarf2expr.h (gdb_read_uleb128, gdb_read_sleb128): Ditto. (safe_read_uleb128, safe_read_sleb128): Ditto. * dwarf2loc.c (decode_debug_loc_dwo_addresses): Ditto. (dwarf2_compile_expr_to_ax): Ditto. (locexpr_describe_location_piece): Ditto. (disassemble_dwarf_expression): Ditto. (locexpr_describe_location_1): Ditto.
* * dwarf2-frame.c (struct dwarf2_cie): Make initial_instructions, endDoug Evans2012-05-221-107/+230
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | "const gdb_byte *". (struct dwarf2_fde): Make instructions, end "const gdb_byte *". (execute_cfa_program): Update to match API of leb128 functions. (read_1_byte, read_4_bytes, read_8_bytes): Make buf parameter "const gdb_byte *". (read_unsigned_leb128, read_signed_leb128): Delete. (read_initial_length): Change type of buf argument to "const gdb_byte *". (read_encoded_value): Update to match API of leb128 functions. (decode_frame_entry): Change result to "const gdb_byte *", and similarly for "start" parameter. (decode_frame_entry_1): Ditto. Use new leb128 reader functions. (dwarf2_build_frame_info): Change local frame_ptr to "const gdb_byte *". * dwarf2expr.c (safe_read_uleb128, safe_read_sleb128): Replaces read_uleb128, read_sleb128. All callers updated. (safe_skip_leb128): New function. (dwarf_block_to_dwarf_reg): Update to match API of leb128 functions. Call gdb_read_uleb128, gdb_skip_leb128 instead of read_uleb128. (dwarf_block_to_dwarf_reg_deref): Update to match API of leb128 functions. Call gdb_read_uleb128, gdb_read_sleb128 instead of read_uleb128, read_sleb128. (dwarf_block_to_fb_offset, dwarf_block_to_sp_offset): Ditto. (execute_stack_op): Update to match API of leb128 functions. * dwarf2expr.h: #include "leb128.h". (read_uleb128, read_sleb128): Delete. (gdb_read_uleb128, gdb_read_sleb128, gdb_skip_leb128): New functions. (safe_read_uleb128, safe_read_sleb128, safe_skip_leb128): Declare. * dwarf2loc.c (debug_loc_kind): New enum. (decode_debug_loc_addresses): New function. (decode_debug_loc_dwo_addresses): New function. (dwarf2_find_location_expression): Rewrite. (dwarf2_compile_expr_to_ax): Update to match API of leb128 functions. (locexpr_describe_location_piece): Ditto. (disassemble_dwarf_expression): Ditto. (locexpr_describe_location_1): Ditto. (loclist_describe_location): Rewrite. * dwarf2loc.h (dwarf2_loclist_baton): New member "from_dwo". * dwarf2read.c (die_reader_specs): New member "buffer_end". (dwarf2_section_buffer_overflow_complaint): Renamed from dwarf2_macros_too_long_complaint. All callers updated. (skip_leb128): Delete. (init_cu_die_reader): Initialize reader->buffer_end. (skip_one_die): Replace call to skip_leb128 with safe_skip_leb128. (skip_form_bytes): New arg buffer_end. All callers updated. Replace call to skip_leb128 with gdb_skip_leb128. (skip_unknown_opcode): New arg mac_end. All callers updated. (fill_in_loclist_baton): Initialize baton->from_dwo.
* 2012-05-18 Sergio Durigan Junior <sergiodj@redhat.com>sergiodj2012-05-181-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ada-lang.c: * ada-tasks.c: * ada-varobj.c: * amd64-darwin-tdep.c: * arm-symbian-tdep.c: * arm-tdep.c: * avr-tdep.c: * ax-gdb.c: * bfin-linux-tdep.c: * breakpoint.c: * c-valprint.c: * cli/cli-cmds.c: * coffread.c: * cp-support.c: * cris-tdep.c: * dwarf2-frame-tailcall.c: * dwarf2-frame.c: * dwarf2expr.c: * dwarf2loc.c: * dwarf2read.c: * elfread.c: * eval.c: * expprint.c: * f-valprint.c: * frv-tdep.c: * h8300-tdep.c: * hppa-hpux-tdep.c: * hppa-tdep.c: * hppanbsd-tdep.c: * i386-nto-tdep.c: * i386-tdep.c: * i387-tdep.c: * ia64-tdep.c: * jit.c: * linespec.c: * linux-tdep.c: * lm32-tdep.c: * m2-valprint.c: * m32c-tdep.c: * m32r-rom.c: * m32r-tdep.c: * m68k-tdep.c: * m68klinux-tdep.c: * mi/mi-main.c: * microblaze-tdep.c: * mips-linux-tdep.c: * mips-tdep.c: * mn10300-tdep.c: * p-valprint.c: * parse.c: * ppc-linux-tdep.c: * ppc-sysv-tdep.c: * printcmd.c: * python/py-finishbreakpoint.c: * python/py-inferior.c: * python/py-infthread.c: * python/py-type.c: * python/python.c: * remote-fileio.c: * remote-m32r-sdi.c: * remote-mips.c: * reverse.c: * rl78-tdep.c: * rs6000-aix-tdep.c: * rs6000-tdep.c: * s390-tdep.c: * score-tdep.c: * sh64-tdep.c: * skip.c: * solib-darwin.c: * solib-dsbt.c: * solib-frv.c: * sparc-tdep.c: * spu-multiarch.c: * spu-tdep.c: * stack.c: * symfile.c: * symtab.c: * tic6x-tdep.c: * tracepoint.c: * v850-tdep.c: * valarith.c: * valprint.c: * value.c: * xcoffread.c: * xtensa-tdep.c: * ada-lang.c: * ada-tasks.c: * ada-varobj.c: * amd64-darwin-tdep.c: * arm-symbian-tdep.c: * arm-tdep.c: Delete unused variables.
* * dwarf2read.c (dwarf_tag_name): Return const char *. UseTom Tromey2012-05-071-4/+4
| | | | | | | | | | | | | get_DW_TAG_name. (dwarf_attr_name): Return const char *. Use get_DW_AT_name. (dwarf_form_name): Return const char *. Use get_DW_FORM_name. (dwarf_stack_op_name): Remove. (dwarf_cfi_name): Return const char *. Use get_DW_ATE_name. (decode_locdesc): Use get_DW_OP_name. * dwarf2loc.c (unimplemented): Use get_DW_OP_name. (dwarf2_compile_expr_to_ax): Likewise. (disassemble_dwarf_expression): Likewise. * dwarf2expr.h: (dwarf_stack_op_name): Remove.
* Initial support for Fission. http://gcc.gnu.org/wiki/DebugFissionDoug Evans2012-04-281-2/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * symfile.c (default_symfile_relocate): Use sectp->owner instead of objfile->obfd. * symfile.h (dwarf2_debug_sections): New member addr. * dwarf2expr.c (execute_stack_op): New case DW_OP_GNU_addr_index. (ctx_no_get_addr_index): New function. * dwarf2expr.h (dwarf_expr_context_funcs): New member get_addr_index. (ctx_no_get_addr_index): Declare. * dwarf2-frame.c (dwarf2_frame_ctx_funcs): Update. * dwarf2loc.c (dwarf_expr_get_addr_index): New function. (dwarf_expr_ctx_funcs): Update. (needs_get_addr_index): New function. (needs_frame_ctx_funcs): Update. * dwarf2loc.h (dwarf2_read_addr_index): Declare. * dwarf2read.c: #include "gdbcore.h". (dwarf2_per_objfile): New members addr, dwo_files. (dwarf2_elf_names): Add entry for addr. (struct dwo_section_names): New type. (dwo_section_names): New static global. (dwarf2_cu): New members dwo_unit, addr_base, have_addr_base. (dwarf2_per_cu_data): New member is_debug_types, all boolean uses of old debug_types_section member updated to use this. Rename member debug_types_section to info_or_types_section, all uses updated. (signatured_type): Rename member type_offset to type_offset_in_tu, all uses updated. New member type_offset_in_section. (struct dwo_sections): New type. (struct dwo_unit): New type. (struct dwo_file): New type. (die_reader_specs): New member dwo_file. (dwarf2_locate_sections): Watch for .debug_addr. (zlib_decompress_section): Use sectp->owner instead of objfile->obfd. (dwarf2_read_section): Get bfd of section from bfd's asection, instead of objfile. (create_cus_from_index): Initialize the_cu->info_or_types_section. (create_signatured_type_table_from_index): Initialize sig_type->info_or_types_section. (dw2_get_file_names): Statement lists for type units with DWO files live in the DWO file. (create_debug_types_hash_table): New function. (create_all_type_units): Rewrite. (init_cu_die_reader): New arg dwo_file, all callers updated. (init_and_read_dies_worker): Get section from this_cu->info_or_types_section. Set sig_type->type_offset_in_section. Watch for DW_AT_GNU_dwo_name and if present lookup the file and continue reading the CU/TU from there. (init_cutu_and_read_dies_no_follow): New arg dwo_file, all callers updated. Get section from this_cu->info_or_types_section. (create_all_comp_units): Initialize this_cu->info_or_types_section. (skip_one_die): New cases DW_FORM_GNU_addr_index, DW_FORM_GNU_str_index. (hash_dwo_file, eq_dwo_file): New functions. (allocate_dwo_file_hash_table): New function. (hash_dwo_unit, eq_dwo_unit): New functions. (allocate_dwo_unit_table): New function. (dwarf2_locate_dwo_sections): New function. (struct create_dwo_info_table_data): New type. (create_debug_info_hash_table_reader): New function. (create_debug_info_hash_table): New function. (try_open_dwo_file, open_dwo_file, init_dwo_file): New function. (lookup_dwo_file): New function. (lookup_dwo_comp_unit, lookup_dwo_type_unit): New functions. (free_dwo_file, free_dwo_file_cleanup): New functions. (free_dwo_file_from_slot, free_dwo_files): New functions. (dwarf2_get_pc_bounds): Handle DW_FORM_GNU_addr_index. (dwarf2_record_block_ranges): Ditto. (read_partial_die): Ditto. (process_enumeration_scope): Update to use type_offset_in_section. (read_full_die_1): New function. (read_full_die): Rewrite. (read_attribute_value): New cases DW_FORM_GNU_addr_index, DW_FORM_GNU_str_index. (read_addr_index_1, read_addr_index): New functions. (read_addr_index_from_leb128): New function. (struct dwarf2_read_addr_index_data): New type. (dwarf2_read_addr_index_reader): New function. (dwarf2_read_addr_index): New function. (read_str_index): New function. (leb128_size): New function. (dwarf_decode_line_header): Delete arg abfd, all callers updated. If processing a type unit from a DWO file, get the line section from the DWO file. (var_decode_location): Watch for DW_OP_GNU_addr_index. (dwarf2_const_value_attr): New cases DW_FORM_GNU_addr_index, DW_FORM_GNU_str_index. (lookup_die_type): Check whether section offset of type's die is known before looking it up. Remove assert. Condition can legimately happen for inter-cu type references. (dwarf_attr_name): Handle Fission attributes. (dwarf_form_name): Handle Fission forms. (dump_die_shallow): New cases DW_FORM_GNU_addr_index, DW_FORM_GNU_str_index. (follow_die_sig): Update to use type_offset_in_section. (decode_locdesc): New case DW_OP_GNU_addr_index. (skip_form_bytes): New cases DW_FORM_GNU_addr_index, DW_FORM_GNU_str_index. (cu_debug_loc_section): New function. (fill_in_loclist_baton, dwarf2_symbol_mark_computed): Call it. (dwarf2_per_objfile_free): Unmap .debug_addr section. Free DWO files if present. * xcoffread.c (dwarf2_xcoff_names): Add .debug_addr. testsuite/ * gdb.dwarf2/dw2-intercu.S (.Ltype_int2_in_cu2): Renamed from .Ltype_int_in_cu2. Use name "int2" instead of "int". All uses updated. * gdb.dwarf2/dw2-intercu.exp: Add "ptype int2" ahead of "ptype func_cu1" to expand cu2 before cu1.
* gdb/Jan Kratochvil2012-03-191-18/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Code cleanupp: Use cu_offset and sect_offset compile time type checking. * dwarf2expr.c (add_piece, dwarf_get_base_type, execute_stack_op) (ctx_no_dwarf_call, ctx_no_get_base_type): Use cu_offset and sect_offset. * dwarf2expr.h (cu_offset, sect_offset): New types. (struct dwarf_expr_context_funcs) <dwarf_call> (struct dwarf_expr_context_funcs) <get_base_type>: Use cu_offset and sect_offset. (struct dwarf_expr_context) <len>: Improve the comment. (struct dwarf_expr_piece, ctx_no_dwarf_call, ctx_no_get_base_type): Use cu_offset and sect_offset. * dwarf2loc.c (per_cu_dwarf_call, dwarf_expr_dwarf_call) (dwarf_expr_get_base_type, needs_frame_dwarf_call) (dwarf2_compile_expr_to_ax, disassemble_dwarf_expression): Likewise. * dwarf2loc.h: Include dwarf2expr.h. (dwarf2_fetch_die_location_block, dwarf2_get_die_type): Use cu_offset and sect_offset. * dwarf2read.c (struct dwarf2_per_objfile) <debug_types_type_hash>: Improve the comment. (struct comp_unit_head, struct dwarf2_cu, struct dwarf2_per_cu_data) (struct signatured_type, struct line_header, struct partial_die_info) (struct die_info, find_partial_die, dwarf2_get_ref_die_offset) (lookup_signatured_type_at_offset, dwarf2_find_containing_comp_unit) (get_die_type_at_offset, create_cus_from_index) (create_signatured_type_table_from_index, dw2_get_file_names) (offset_in_cu_p, read_comp_unit_head, error_check_comp_unit_head) (read_and_check_comp_unit_head, read_and_check_type_unit_head) (create_debug_types_hash_table, process_psymtab_comp_unit) (load_partial_comp_unit, create_all_comp_units) (partial_die_parent_scope, partial_die_full_name, skip_one_die) (load_full_comp_unit, dwarf2_physname, read_import_statement) (inherit_abstract_dies, read_func_scope, read_call_site_scope) (dwarf2_add_member_fn, process_enumeration_scope, read_module_type) (read_typedef, die_hash, die_eq, read_full_die, dwarf2_read_abbrevs) (load_partial_dies, read_partial_die, find_partial_die_in_comp_unit) (find_partial_die, read_attribute_value, lookup_die_type) (dump_die_shallow, store_in_ref_table): Use cu_offset and sect_offset. (is_ref_attr): New function comment. (dwarf2_get_ref_die_offset): New function comment, new variable retval. Use cu_offset and sect_offset. (follow_die_offset, follow_die_ref, dwarf2_fetch_die_location_block) (dwarf2_get_die_type, follow_die_sig, lookup_signatured_type_at_offset) (load_full_type_unit, read_signatured_type, per_cu_header_read_in) (dwarf2_find_containing_comp_unit, struct dwarf2_offset_and_type) (offset_and_type_hash, offset_and_type_eq, set_die_type) (get_die_type_at_offset, partial_die_hash, partial_die_eq) (write_one_signatured_type, write_psymtabs_to_index): Use cu_offset and sect_offset.
* gdb:qiyao2012-03-131-0/+2
| | | | | | | | | | | | | | | | | | | | | * inferior.h (struct inferior): Remove fields any_syscall_count, syscalls_counts and total_syscalls_count. Move them to new struct catch_syscall_inferior_data in breakpoint.c. * breakpoint.c: Call DEF_VEC_I(int). (struct catch_syscall_inferior_data): New. (get_catch_syscall_inferior_data): New. (catch_syscall_inferior_data_cleanup): New. (insert_catch_syscall): Update to access data in struct catch_syscall_inferior_data. (insert_catch_syscall): Likewise. (remove_catch_syscall): Likewise. (remove_catch_syscall): Likewise. (is_syscall_catchpoint_enabled): Likewise. (add_catch_command): Likewise. (_initialize_breakpoint): Register cleanup. * breakpoint.h: Removed DEF_VEC_I(int). * dwarf2loc.c: Call DEF_VEC_I(int). * mi/mi-main.c: Likewise.
* 2012-03-01 Pedro Alves <palves@redhat.com>Pedro Alves2012-03-011-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * amd64-linux-tdep.c (amd64_linux_record_signal): Make static. * breakpoint.c (create_exception_master_breakpoint, trace_command) (ftrace_command, strace_command): Make static. * d-lang.c (_initialize_d_language): Declare. * dwarf2expr.c (_initialize_dwarf2expr): Declare. * dwarf2loc.c (_initialize_dwarf2loc): * dwarf2read.c (process_psymtab_comp_unit): Make static. * exec.c (exec_get_section_table): Make static. * i386-linux-tdep.c (i386_linux_record_signal): Make static. * infcmd.c (ensure_valid_thread, ensure_not_tfind_mode): Make static. * inferior.c (remove_inferior_command, add_inferior_command) (clone_inferior_command): Make static. * linux-nat.c (linux_nat_thread_address_space) (linux_nat_core_of_thread): Make static. * linux-tdep.c (_initialize_linux_tdep): Declare. * objc-lang.c (_initialize_objc_lang): Declare. * opencl-lang.c (builtin_opencl_type, opencl_language_arch_info): Make static. (_initialize_opencl_language): Declare. * record.c (_initialize_record): Declare. * remote.c (demand_private_info, remote_get_tib_address) (remote_supports_cond_tracepoints) (remote_supports_fast_tracepoints, remote_get_tracepoint_status): Make static. * skip.c (_initialize_step_skip): Declare. * symtab.c (skip_prologue_using_lineinfo): Make static. * tracepoint.c (delete_trace_state_variable) (trace_variable_command, delete_trace_variable_command) (get_uploaded_tsv, find_matching_tracepoint_location) (find_matching_tsv, create_tsv_from_upload, get_traceframe_info): Make static. * value.c (pack_unsigned_long): Make static. * varobj.c (varobj_ensure_python_env): Make static. * windows-tdep.c (_initialize_windows_tdep): Declare. * xml-syscall.c (make_cleanup_free_syscalls_info): Make static.
* Copyright year update in most files of the GDB Project.Joel Brobecker2012-01-041-2/+1
| | | | | | gdb/ChangeLog: Copyright year update in most files of the GDB Project.
* the "ambiguous linespec" seriesTom Tromey2011-12-061-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gdb 2011-12-06 Joel Brobecker <brobecker@acacore.com> * language.h (struct language_defn): Add new component la_symbol_name_compare. * symfile.h (struct quick_symbol_functions): Update the profile of parameter "name_matcher" for the expand_symtabs_matching method. Update the documentation accordingly. * ada-lang.h (ada_name_for_lookup): Add declaration. * ada-lang.c (ada_name_for_lookup): New function, extracted out from ada_iterate_over_symbols. (ada_iterate_over_symbols): Do not encode symbol name anymore. (ada_expand_partial_symbol_name): Adjust profile. (ada_language_defn): Add value for la_symbol_name_compare field. * linespec.c: #include "ada-lang.h". (iterate_name_matcher): Add language parameter. Replace call to strcmp_iw by call to language->la_symbol_name_compare. (decode_variable): Encode COPY if current language is Ada. * dwarf2read.c (dw2_expand_symtabs_matching): Adjust profile of name_matcher parameter. Adjust call to name_matcher. * psymtab.c (expand_symtabs_matching_via_partial): Likewise. (expand_partial_symbol_names): Update profile of parameter "fun". * psymtab.h (expand_partial_symbol_names): Update profile of parameter "fun". * symtab.c (demangle_for_lookup): Update function documentation. (search_symbols_name_matches): Add language parameter. (expand_partial_symbol_name): Likewise. * c-lang.c (c_language_defn, cplus_language_defn) (asm_language_defn, minimal_language_defn): Add value for la_symbol_name_compare field. * d-lang.c (d_language_defn): Likewise. * f-lang.c (f_language_defn): Ditto. * jv-lang.c (java_language_defn): Ditto. * m2-lang.c (m2_language_defn): Ditto. * objc-lang.c (objc_language_defn): Ditto. * opencl-lang.c (opencl_language_defn): Ditto. * p-lang.c (pascal_language_defn): Ditto. * language.c (unknown_language_defn, auto_language_defn) (local_language_defn): Ditto. 2011-12-06 Tom Tromey <tromey@redhat.com> * linespec.c (iterate_over_all_matching_symtabs): Use LA_ITERATE_OVER_SYMBOLS. (lookup_prefix_sym, add_matching_symbols_to_info): Likewise. (find_function_symbols, decode_variable): Remove Ada special case. * language.h (struct language_defn) <la_iterate_over_symbols>: New field. (LA_ITERATE_OVER_SYMBOLS): New macro. * language.c (unknown_language_defn, auto_language_defn) (local_language_defn): Update. * c-lang.c (c_language_defn, cplus_language_defn) (asm_language_defn, minimal_language_defn): Update. * d-lang.c (d_language_defn): Update. * f-lang.c (f_language_defn): Update. * jv-lang.c (java_language_defn): Update. * m2-lang.c (m2_language_defn): Update. * objc-lang.c (objc_language_defn): Update. * opencl-lang.c (opencl_language_defn): Update. * p-lang.c (pascal_language_defn): Update. * ada-lang.c (ada_iterate_over_symbols): New function. (ada_language_defn): Update. 2011-12-06 Tom Tromey <tromey@redhat.com> Joel Brobecker <brobecker@acacore.com> PR breakpoints/13105, PR objc/8341, PR objc/8343, PR objc/8366, PR objc/8535, PR breakpoints/11657, PR breakpoints/11970, PR breakpoints/12023, PR breakpoints/12334, PR breakpoints/12856, PR shlibs/8929, PR shlibs/7393: * python/py-type.c (compare_maybe_null_strings): Rename from compare_strings. (check_types_equal): Update. * utils.c (compare_strings): New function. * tui/tui-winsource.c (tui_update_breakpoint_info): Update for location changes. * tracepoint.c (scope_info): Update. (trace_find_line_command): Use DECODE_LINE_FUNFIRSTLINE. * symtab.h (iterate_over_minimal_symbols) (iterate_over_some_symtabs, iterate_over_symtabs) (find_pcs_for_symtab_line, iterate_over_symbols) (demangle_for_lookup): Declare. (expand_line_sal): Remove. * symtab.c (iterate_over_some_symtabs, iterate_over_symtabs) (lookup_symtab_callback): New functions. (lookup_symtab): Rewrite. (demangle_for_lookup): New function, extract from lookup_symbol_in_language. (lookup_symbol_in_language): Use it. (iterate_over_symbols): New function. (find_line_symtab): Update. (find_pcs_for_symtab_line): New functions. (find_line_common): Add 'start' argument. (decode_line_spec): Update. Change argument to 'flags', change interpretation. (append_expanded_sal): Remove. (append_exact_match_to_sals): Remove. (expand_line_sal): Remove. * symfile.h (struct quick_symbol_functions) <lookup_symtab>: Remove. <map_symtabs_matching_filename>: New field. * stack.c (func_command): Only look in the current program space. Use DECODE_LINE_FUNFIRSTLINE. * source.c (line_info): Set pspace on sal. Check program space in the loop. Use DECODE_LINE_LIST_MODE. (select_source_symtab): Use DECODE_LINE_FUNFIRSTLINE. * solib-target.c: Remove DEF_VEC_I(CORE_ADDR). * python/python.c (gdbpy_decode_line): Update. * psymtab.c (partial_map_expand_apply): New function. (partial_map_symtabs_matching_filename): Rename from lookup_partial_symbol. Update arguments. (lookup_symtab_via_partial_symtab): Remove. (psym_functions): Update. * objc-lang.h (parse_selector, parse_method): Don't declare. (find_imps): Update. * objc-lang.c (parse_selector, parse_method): Now static. (find_methods): Change arguments. Fill in a vector of symbol names. (uniquify_strings): New function. (find_imps): Change arguments. * minsyms.c (iterate_over_minimal_symbols): New function. * linespec.h (enum decode_line_flags): New. (struct linespec_sals): New. (struct linespec_result) <canonical>: Remove. <pre_expanded, addr_string, sals>: New fields. (destroy_linespec_result, make_cleanup_destroy_linespec_result) (decode_line_full): Declare. (decode_line_1): Update. * linespec.c (struct address_entry, struct linespec_state, struct collect_info): New types. (add_sal_to_sals_basic, add_sal_to_sals, hash_address_entry) (eq_address_entry, maybe_add_address): New functions. (total_number_of_methods): Remove. (iterate_name_matcher, iterate_over_all_matching_symtabs): New functions. (find_methods): Change arguments. Don't canonicalize input. Simplify logic. (add_matching_methods, add_constructors) (build_canonical_line_spec): Remove. (filter_results, convert_results_to_lsals): New functions. (decode_line_2): Change arguments. Rewrite for new data structures. (decode_line_internal): Rename from decode_line_1. Change arguments. Add cleanups. Update for new data structures. (linespec_state_constructor, linespec_state_destructor) (decode_line_full, decode_line_1): New functions. (decode_indirect): Change arguments. Update. (locate_first_half): Use skip_spaces. (decode_objc): Change arguments. Update for new data structures. Simplify logic. (decode_compound): Change arguments. Add cleanups. Remove fallback code, replace with error. (struct decode_compound_collector): New type. (collect_one_symbol): New function. (lookup_prefix_sym): Change arguments. Update. (compare_symbol_name, add_all_symbol_names_from_pspace) (find_superclass_methods ): New functions. (find_method): Rewrite. (struct symtab_collector): New type. (add_symtabs_to_list, collect_symtabs_from_filename): New functions. (symtabs_from_filename): Change API. Rename from symtab_from_filename. (collect_function_symbols): New function. (find_function_symbols): Change API. Rename from find_function_symbol. Rewrite. (decode_all_digits): Change arguments. Rewrite. (decode_dollar): Change arguments. Use decode_variable. (decode_label): Change arguments. Rewrite. (collect_symbols): New function. (minsym_found): Change arguments. Rewrite. (check_minsym, search_minsyms_for_name) (add_matching_symbols_to_info): New function. (decode_variable): Change arguments. Iterate over all symbols. (symbol_found): Remove. (symbol_to_sal): New function. (init_linespec_result, destroy_linespec_result) (cleanup_linespec_result, make_cleanup_destroy_linespec_result): New functions. (decode_digits_list_mode, decode_digits_ordinary): New functions. * dwarf2read.c (dw2_map_expand_apply): New function. (dw2_map_symtabs_matching_filename): Rename from dw2_lookup_symtab. Change arguments. (dwarf2_gdb_index_functions): Update. * dwarf2loc.c: Remove DEF_VEC_I(CORE_ADDR). * defs.h (compare_strings): Declare. * cli/cli-cmds.c (compare_strings): Move to utils.c. (edit_command, list_command): Use DECODE_LINE_LIST_MODE. Call filter_sals. (compare_symtabs, filter_sals): New functions. * breakpoint.h (struct bp_location) <line_number, source_file>: New fields. (struct breakpoint) <line_number, source_file>: Remove. <filter>: New field. * breakpoint.c (print_breakpoint_location, init_raw_breakpoint) (momentary_breakpoint_from_master, add_location_to_breakpoint): Update for changes to locations. (init_breakpoint_sal): Add 'filter' argument. Set 'filter' on breakpoint. (create_breakpoint_sal): Add 'filter' argument. (remove_sal, expand_line_sal_maybe): Remove. (create_breakpoints_sal): Remove 'sals' argument. Handle pre-expanded sals and the filter. (parse_breakpoint_sals): Use decode_line_full. (check_fast_tracepoint_sals): Use get_sal_arch. (create_breakpoint): Create a linespec_sals. Update. (break_range_command): Use decode_line_full. Update. (until_break_command): Update. (clear_command): Update match conditions for linespec.c changes. Use DECODE_LINE_LIST_MODE. (say_where): Update for changes to locations. (bp_location_dtor): Free 'source_file'. (base_breakpoint_dtor): Free 'filter'. Don't free 'source_file'. (update_static_tracepoint): Update for changes to locations. (update_breakpoint_locations): Disable ranged breakpoint if too many locations match. Update. (addr_string_to_sals): Use decode_line_full. Resolve all sal PCs. (breakpoint_re_set_default): Don't call expand_line_sal_maybe. (decode_line_spec_1): Update. Change argument name to 'flags', change interpretation. * block.h (block_containing_function): Declare. * block.c (block_containing_function): New function. * skip.c (skip_function_command): Update. (skip_re_set): Update. * infcmd.c (jump_command): Use DECODE_LINE_FUNFIRSTLINE. * mi/mi-main.c (mi_cmd_trace_find): Use DECODE_LINE_FUNFIRSTLINE. * NEWS: Add entry. 2011-12-06 Tom Tromey <tromey@redhat.com> * elfread.c (elf_gnu_ifunc_resolver_return_stop): Allow breakpoint's pspace to be NULL. * breakpoint.h (struct breakpoint) <pspace>: Update comment. * breakpoint.c (init_raw_breakpoint): Conditionally set breakpoint's pspace. (init_breakpoint_sal): Don't set breakpoint's pspace. (prepare_re_set_context): Conditionally switch program space. (addr_string_to_sals): Check executing_startup on location's program space. 2011-12-06 Tom Tromey <tromey@redhat.com> * breakpoint.h (enum enable_state) <bp_startup_disabled>: Remove. * breakpoint.c (should_be_inserted): Explicitly check if program space is executing startup. (describe_other_breakpoints): Update. (disable_breakpoints_before_startup): Change executing_startup earlier. Remove loop. (enable_breakpoints_after_startup): Likewise. (init_breakpoint_sal): Don't use bp_startup_disabled. (create_breakpoint): Don't use bp_startup_disabled. (update_global_location_list): Use should_be_inserted. (bkpt_re_set): Update. gdb/testsuite 2011-12-06 Joel Brobecker <brobecker@acacore.com> * gdb.ada/fullname_bp.exp: Add tests for other valid linespecs involving a fully qualified function name. 2011-12-06 Tom Tromey <tromey@redhat.com> * gdb.ada/homonym.exp: Add three breakpoint tests. 2011-12-06 Tom Tromey <tromey@redhat.com> * gdb.base/solib-weak.exp (do_test): Remove kfail. * gdb.trace/tracecmd.exp: Disable pending breakpoints earlier. * gdb.objc/objcdecode.exp: Update for output changes. * gdb.linespec/linespec.exp: New file. * gdb.linespec/lspec.cc: New file. * gdb.linespec/lspec.h: New file. * gdb.linespec/body.h: New file. * gdb.linespec/base/two/thefile.cc: New file. * gdb.linespec/base/one/thefile.cc: New file. * gdb.linespec/Makefile.in: New file. * gdb.cp/templates.exp (test_template_breakpoints): Update for output changes. * gdb.cp/re-set-overloaded.exp: Remove kfail. * gdb.cp/ovldbreak.exp: Update for output changes. "all" test now makes one breakpoint. * gdb.cp/method2.exp (test_break): Update for output changes. * gdb.cp/mb-templates.exp: Update for output changes. * gdb.cp/mb-inline.exp: Update for output changes. * gdb.cp/mb-ctor.exp: Update for output changes. * gdb.cp/ovsrch.exp: Use fully-qualified names. * gdb.base/solib-symbol.exp: Run to main later. Breakpoint now has multiple matches. * gdb.base/sepdebug.exp: Disable pending breakpoints. Update for error message change. * gdb.base/list.exp (test_list_filename_and_number): Update for error message change. * gdb.base/break.exp: Disable pending breakpoints. Update for output changes. * configure.ac: Add gdb.linespec. * configure: Rebuild. * Makefile.in (ALL_SUBDIRS): Add gdb.linespec. gdb/doc 2011-12-06 Tom Tromey <tromey@redhat.com> * gdb.texinfo (Set Breaks): Update for new behavior.
* gdb/Jan Kratochvil2011-10-121-11/+11
| | | | | | | | | | | | | | | | | | | | | | | Fix empty DWARF expressions DATA vs. SIZE conditionals. * dwarf2loc.c (dwarf2_find_location_expression): Clear *LOCEXPR_LENGTH. (dwarf_expr_frame_base_1): Indicate unavailability via zero *LENGTH. (locexpr_tracepoint_var_ref): Check only zero SIZE, not zero DATA. (loclist_read_variable, loclist_tracepoint_var_ref): Do not check for zero DATA. * dwarf2loc.h (struct dwarf2_locexpr_baton): Comment DATA vs. SIZE validity. * dwarf2read.c (struct dwarf_block): Comment DATA validity. (dwarf2_fetch_die_location_block, dwarf2_symbol_mark_computed): Do not clear DATA on zero SIZE. gdb/testsuite/ Fix empty DWARF expressions DATA vs. SIZE conditionals. * gdb.dwarf2/dw2-op-call.S (arraycallnoloc, arraynoloc): New DIEs. (loclist): New. (4): New abbrev. * gdb.dwarf2/dw2-op-call.exp: Remove variable srcfile and executable. Use prepare_for_testing, remove clean_restart. (p arraynoloc, p arraycallnoloc): New tests.
* gdb/Jan Kratochvil2011-10-091-1/+2
| | | | | | Fix compatibility with older GCCs. * dwarf2loc.c (dwarf_expr_reg_to_entry_parameter): Initialize parameter. * stack.c (read_frame_arg): Initialize val_deref.
* gdb/Jan Kratochvil2011-10-091-12/+22
| | | | | | | | | | | | | | | | Entry values NEWS entries, DWARF disassembly support. * NEWS: New entry values entry. (set print entry-values, show print entry-values) (set debug entry-values, show debug entry-values): New entries. * dwarf2loc.c (disassemble_dwarf_expression): New parameters start and indent. Remove variable start. Move header printing out. Respect INDENT. Support DW_OP_GNU_entry_value. (locexpr_describe_location_1): Move the header printing here, extend the disassemble_dwarf_expression passed parameters. gdb/testsuite/ * gdb.arch/amd64-entry-value.s: New file. * gdb.mi/mi2-amd64-entry-value.s: New file.
* gdb/Jan Kratochvil2011-10-091-16/+129
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Display @entry parameter values even for references. * ada-valprint.c (ada_val_print_1) <TYPE_CODE_REF>: Try also coerce_ref_if_computed. * c-valprint.c (c_val_print) <TYPE_CODE_REF>: Likewise. * dwarf2expr.c (dwarf_block_to_dwarf_reg_deref): New function. (execute_stack_op) <DW_OP_GNU_entry_value>: Add -1 deref_size to the existing push_dwarf_reg_entry_value call. Add new detection calling dwarf_block_to_dwarf_reg_deref. Update the error message. (ctx_no_push_dwarf_reg_entry_value): New parameter deref_size. * dwarf2expr.h (struct dwarf_expr_context_funcs) <push_dwarf_reg_entry_value>: Add new parameter deref_size, describe it in the comment. (ctx_no_push_dwarf_reg_entry_value): Add new parameter deref_size. (dwarf_block_to_dwarf_reg_deref): New declaration. * dwarf2loc.c (dwarf_entry_parameter_to_value): Add new parameter deref_size, describe it in the function comment. New variables data_src and size, fetch the alternative block accoring to DEREF_SIZE. (dwarf_expr_push_dwarf_reg_entry_value): Add new parameter deref_size, describe it in the function comment. Fetch the alternative block accoring to DEREF_SIZE. (entry_data_value_coerce_ref, entry_data_value_copy_closure) (entry_data_value_free_closure, entry_data_value_funcs): New. (value_of_dwarf_reg_entry): New variables checked_type, target_type, outer_val, target_val, val and addr. Try to fetch and create also referenced value content. (pieced_value_funcs): NULL value for coerce_ref. (needs_dwarf_reg_entry_value): Add new parameter deref_size. * f-valprint.c (f_val_print) <TYPE_CODE_REF>: Try also coerce_ref_if_computed. * opencl-lang.c (opencl_value_funcs): NULL value for coerce_ref. * p-valprint.c (pascal_val_print) <TYPE_CODE_REF>: Likewise. * stack.c (read_frame_arg): Compare also dereferenced values. * value.c (value_computed_funcs): Make the parameter v const, use value_lval_const for it. (value_lval_const, coerce_ref_if_computed): New function. (coerce_ref): New variable retval. Call also coerce_ref_if_computed. * value.h (struct lval_funcs): New field coerce_ref. (value_computed_funcs): Make the parameter v const. (value_lval_const, coerce_ref_if_computed): New declarations. gdb/testsuite/ Display @entry parameter values even for references. * gdb.arch/amd64-entry-value.cc (reference, datap, datap_input): New functions. (main): New variables regvar, nodatavarp, stackvar1, stackvar2. Call reference and datap_input. * gdb.arch/amd64-entry-value.exp (reference, breakhere_reference): New breakpoints. (continue to breakpoint: entry_reference: reference) (entry_reference: bt at entry) (continue to breakpoint: entry_reference: breakhere_reference) (entry_reference: bt, entry_reference: ptype regparam) (entry_reference: p regparam, entry_reference: ptype regparam@entry) (entry_reference: p regparam@entry, entry_reference: p &regparam@entry) (entry_reference: p regcopy, entry_reference: p nodataparam) (entry_reference: p nodataparam@entry): New tests.
* gdb/Jan Kratochvil2011-10-091-0/+138
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Display @entry parameter values (without references). * dwarf2expr.c (dwarf_block_to_fb_offset, dwarf_block_to_sp_offset): New functions. * dwarf2expr.h (dwarf_block_to_fb_offset, dwarf_block_to_sp_offset): New declarations. * dwarf2loc.c (dwarf2_find_location_expression): Support location list entry record. (dwarf_entry_parameter_to_value, value_of_dwarf_reg_entry) (value_of_dwarf_block_entry, locexpr_read_variable_at_entry): New functions. (dwarf2_locexpr_funcs): Install locexpr_read_variable_at_entry. (loclist_read_variable_at_entry): New function. (dwarf2_loclist_funcs): Install loclist_read_variable_at_entry. * dwarf2read.c (read_call_site_scope): Support also DW_OP_fbreg in DW_AT_location, call dwarf_block_to_sp_offset for it. * frame.h (print_entry_values_no, print_entry_values_only) (print_entry_values_preferred, print_entry_values_if_needed) (print_entry_values_both, print_entry_values_compact) (print_entry_values_default, print_entry_values): New declarations. (struct frame_arg): New field entry_kind. (read_frame_arg): New parameter entryargp. * mi/mi-cmd-stack.c (list_arg_or_local): New gdb_assert for arg->entry_kind. Optionally print the `@entry' suffix. (list_args_or_locals): New variable entryarg, initialize it. Initialize also entry_kind of arg and entryarg. Conditionalize list_arg_or_local for arg, add list_arg_or_local for entryarg. Call xfree for entryarg.error. * stack.c (print_entry_values_no, print_entry_values_only) (print_entry_values_preferred, print_entry_values_if_needed) (print_entry_values_both, print_entry_values_compact) (print_entry_values_default, print_entry_values_choices) (print_entry_values): New variables. (print_frame_arg): New gdb_assert for arg->entry_kind. Optionally print the `@entry' suffix, possibly in combination for print_entry_values_compact. (read_frame_arg): New parameter entryargp, new variables entryval, entryval_error and val_equal. Read in also entryargp, respect print_entry_values, compare the values using val_equal, fill in also argp->entry_kind (together with entryargp->entry_kind). (print_frame_args): New variable entryarg, initialize it. Conditionalize print_frame_arg for arg, add print_frame_arg for entryarg. Call xfree for entryarg.error. (_initialize_stack): Call add_setshow_enum_cmd for `entry-values'. * symtab.h (struct symbol_computed_ops): New field read_variable_at_entry. gdb/doc/ Display @entry parameter values (without references). * gdb.texinfo (Tail Call Frames): Add anchor. Add self tail call example. (Print Settings): New description of set print entry-values and show print entry-values. gdb/testsuite/ Display @entry parameter values (without references). * gdb.arch/amd64-entry-value.cc (locexpr, stacktest, data, data2) (different, validity, invalid): New functions. (main): Call them. * gdb.arch/amd64-entry-value.exp: New breakpoints breakhere_locexpr, stacktest, breakhere_stacktest, different, breakhere_different, breakhere_validity and breakhere_invalid. (entry: bt): Update for @entry. (entry_locexpr: *, entry_stack: *, entry_equal: *, entry_different: *) (entry_validity: *, entry_invalid: *): Many new tests. * gdb.base/break.exp (run until breakpoint set at small function, optimized file): Accept also the @entry suffix. * gdb.mi/Makefile.in (PROGS): Add mi2-amd64-entry-value. * gdb.mi/mi2-amd64-entry-value.c: New files. * gdb.mi/mi2-amd64-entry-value.exp: New files.
* gdb/Jan Kratochvil2011-10-091-0/+85
| | | | | | | | | | | | | Protect entry values against self tail calls. * dwarf2loc.c (VEC (CORE_ADDR), func_verify_no_selftailcall): New. (dwarf_expr_dwarf_reg_entry_value): Call func_verify_no_selftailcall. gdb/testsuite/ Protect entry values against self tail calls. * gdb.arch/amd64-entry-value.cc (self2, self): New. (main): Call self. * gdb.arch/amd64-entry-value.exp (self: breakhere, self: bt) (set debug entry-values 1, self: bt debug entry-values): New tests.
* gdb/Jan Kratochvil2011-10-091-0/+315
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recognize virtual tail call frames. * Makefile.in (SFILES): Add dwarf2-frame-tailcall.c. (HFILES_NO_SRCDIR): Add dwarf2-frame-tailcall.h. (COMMON_OBS): Add dwarf2-frame-tailcall.o. * dwarf2-frame-tailcall.c: New file. * dwarf2-frame-tailcall.h: New file. * dwarf2-frame.c: Include dwarf2-frame-tailcall.h. (execute_cfa_program): New function comment. Return INSN_PTR. Reset REGS.PREV only after CIE execution. (struct dwarf2_frame_cache): New field tailcall_cache. (dwarf2_frame_cache): New variables entry_pc, entry_cfa_sp_offset, entry_cfa_sp_offset_p and instr. Execute FDE instructions in two parts, try to find entry_cfa_sp_offset. Call dwarf2_tailcall_sniffer_first. (dwarf2_frame_prev_register): Call dwarf2_tailcall_prev_register_first when appropriate. (dwarf2_frame_dealloc_cache): New function. (dwarf2_frame_sniffer): Preinitialize cache by dwarf2_frame_cache. (dwarf2_frame_unwind): Install dwarf2_frame_dealloc_cache. (dwarf2_signal_frame_unwind): Do not install dwarf2_frame_dealloc_cache. (dwarf2_append_unwinders): Add dwarf2_tailcall_frame_unwind. (dwarf2_frame_cfa): Support also dwarf2_tailcall_frame_unwind. * dwarf2loc.c (func_addr_to_tail_call_list) (tailcall_dump, call_sitep, VEC (call_sitep), chain_candidate) (call_site_find_chain_1, call_site_find_chain): New. * dwarf2loc.h (struct call_site_chain): New. (call_site_find_chain): New declaration. * frame.c (get_frame_address_in_block): Support also TAILCALL_FRAME. * frame.h (enum frame_type): New entry TAILCALL_FRAME. * python/py-frame.c (gdbpy_initialize_frames): Add TAILCALL_FRAME. * stack.c (frame_info): Support also TAILCALL_FRAME. gdb/doc/ Recognize virtual tail call frames. * gdb.texinfo (Optimized Code): Add reference to Tail Call Frames. (Tail Call Frames): New node. (Frames In Python): Add gdb.TAILCALL_FRAME. gdb/testsuite/ Recognize virtual tail call frames. * gdb.arch/amd64-entry-value.cc (c, a, b, amb_z, amb_y, amb_x, amb) (amb_b, amb_a): New. (main): Call a and b. * gdb.arch/amd64-entry-value.exp (tailcall: breakhere, tailcall: bt) (tailcall: p i, tailcall: p j, set $sp0=$sp, up, p $sp0 == $sp, frame 3) (p $sp0 + sizeof (void *) == $sp, ambiguous: breakhere, ambiguous: bt): New tests.
* gdb/Jan Kratochvil2011-10-091-2/+285
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implement basic support for DW_TAG_GNU_call_site. * block.c: Include gdbtypes.h and exceptions.h. (call_site_for_pc): New function. * block.h (call_site_for_pc): New declaration. * defs.h: Include hashtab.h. (make_cleanup_htab_delete, core_addr_hash, core_addr_eq): New declarations. * dwarf2-frame.c (dwarf2_frame_ctx_funcs): Install ctx_no_push_dwarf_reg_entry_value. * dwarf2expr.c (read_uleb128, read_sleb128): Support R as NULL. (dwarf_block_to_dwarf_reg): New function. (execute_stack_op) <DW_OP_GNU_entry_value>: Implement it. (ctx_no_push_dwarf_reg_entry_value): New function. * dwarf2expr.h (struct dwarf_expr_context_funcs): New field push_dwarf_reg_entry_value. (ctx_no_push_dwarf_reg_entry_value, dwarf_block_to_dwarf_reg): New declarations. * dwarf2loc.c: Include gdbcmd.h. (dwarf_expr_ctx_funcs): New forward declaration. (entry_values_debug, show_entry_values_debug, call_site_to_target_addr) (dwarf_expr_reg_to_entry_parameter) (dwarf_expr_push_dwarf_reg_entry_value): New. (dwarf_expr_ctx_funcs): Install dwarf_expr_push_dwarf_reg_entry_value. (dwarf2_evaluate_loc_desc_full): Handle NO_ENTRY_VALUE_ERROR. (needs_dwarf_reg_entry_value): New function. (needs_frame_ctx_funcs): Install it. (_initialize_dwarf2loc): New function. * dwarf2loc.h (entry_values_debug): New declaration. * dwarf2read.c (struct dwarf2_cu): New field call_site_htab. (read_call_site_scope): New forward declaration. (process_full_comp_unit): Copy call_site_htab. (process_die): Support DW_TAG_GNU_call_site. (read_call_site_scope): New function. (dwarf2_get_pc_bounds): Support NULL HIGHPC. (dwarf_tag_name): Support DW_TAG_GNU_call_site. (cleanup_htab): Delete. (write_psymtabs_to_index): Use make_cleanup_htab_delete instead of it. * exceptions.h (enum errors): New NO_ENTRY_VALUE_ERROR. * gdb-gdb.py (StructMainTypePrettyPrinter): Support FIELD_LOC_KIND_DWARF_BLOCK. * gdbtypes.h (enum field_loc_kind): New entry FIELD_LOC_KIND_DWARF_BLOCK. (struct main_type): New loc entry dwarf_block. (struct call_site, FIELD_DWARF_BLOCK, SET_FIELD_DWARF_BLOCK) (TYPE_FIELD_DWARF_BLOCK): New. * python/py-type.c: Include dwarf2loc.h. (check_types_equal): Support FIELD_LOC_KIND_DWARF_BLOCK. New internal_error call on unknown FIELD_LOC_KIND. * symtab.h (struct symtab): New field call_site_htab. * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete) (core_addr_hash, core_addr_eq): New functions. gdb/testsuite/ Implement basic support for DW_TAG_GNU_call_site. * gdb.arch/Makefile.in (EXECUTABLES): Add amd64-entry-value. * gdb.arch/amd64-entry-value.cc: New file. * gdb.arch/amd64-entry-value.exp: New file.
* gdb/Jan Kratochvil2011-10-091-0/+2
| | | | | | | | | | | | | | | | | | Fix DW_OP_GNU_implicit_pointer for DWARF32 v3+ on 64-bit arches. * dwarf2-frame.c (execute_stack_op): Initialize ctx->ref_addr_size. * dwarf2expr.c (execute_stack_op) <DW_OP_GNU_implicit_pointer>: Use ctx->ref_addr_size. Handle its invalid value. * dwarf2expr.h (struct dwarf_expr_context): New field ref_addr_size. * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) (dwarf2_loc_desc_needs_frame): Initialize ctx->ref_addr_size. * dwarf2loc.h (dwarf2_per_cu_ref_addr_size): New declaration. * dwarf2read.c (decode_locdesc): Initialize ctx->ref_addr_size. (dwarf2_per_cu_ref_addr_size): New function. gdb/testsuite/ Fix DW_OP_GNU_implicit_pointer for DWARF32 v3+ on 64-bit arches. * gdb.dwarf2/implptr-64bit.S: New file. * gdb.dwarf2/implptr-64bit.exp: New file.
* gdb/Jan Kratochvil2011-09-131-20/+3
| | | | | | | | | | | | Remove excessive DWARF expressions memory duplication. * dwarf2loc.c (per_cu_dwarf_call): Remove variable back_to and its use for block.data. (indirect_pieced_value): Remove variable result. Remove variable back_to and its use for baton.data. (dwarf2_compile_expr_to_ax): Remove variable back_to and its use for block.data. * dwarf2read.c (dwarf2_fetch_die_location_block): Remove xmemdup. Update the function comment.
* gdb/Jan Kratochvil2011-08-081-2/+14
| | | | | | | | | | * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK> (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_LITERAL>: New variable objfile_gdbarch. Fix BFD_ENDIAN_BIG case. gdb/testsuite/ * gdb.dwarf2/dw2-op-stack-value.S: New file. * gdb.dwarf2/dw2-op-stack-value.exp: New file.
* gdb/Jan Kratochvil2011-07-251-1/+3
| | | | | | | | | | | | | | | | | Fix implicit pointer offsets. * dwarf2loc.c (indirect_pieced_value): Comment byte_offset. Use also ptr.OFFSET. gdb/testsuite/ Fix implicit pointer offsets. * gdb.dwarf2/implptr.c (add): New marker baz breakpoint. * gdb.dwarf2/implptr.exp (set baz breakpoint for implptr) (continue to breakpoint: continue to baz breakpoint for implptr) (sanity check element 0, sanity check element 1) (enter the inlined function, check element 0 for the offset) (check element 1 for the offset) (continue to breakpoint: ignore the second baz breakpoint): New tests. (set foo breakpoint for implptr): Update the breakpoint number.
* gdb/Jan Kratochvil2011-07-191-0/+14
| | | | | | | | | | | | | | | | | | | | | | Fix crash if referenced CU is aged out. * dwarf2loc.c (per_cu_dwarf_call): New variable back_to, use to for xfree of block.data. (indirect_pieced_value): New variable back_to, use to for xfree of baton.data. (dwarf2_compile_expr_to_ax): New variable back_to, use to for xfree of block.data. * dwarf2read.c (dwarf2_find_base_address): New prototype. (load_cu): New function from ... (dw2_do_instantiate_symtab): ... the code here ... (process_full_comp_unit): ... and here. (dwarf2_fetch_die_location_block): Call load_cu first. Call xmemdup on retval.data. gdb/testsuite/ Fix crash if referenced CU is aged out. * gdb.dwarf2/dw2-op-call.exp (maintenance set dwarf2 max-cache-age 0): New. * gdb.dwarf2/implptr.exp: Likewise.
* gdb/Jan Kratochvil2011-07-191-1/+1
| | | | | | | | | | | | | | * dwarf2loc.c (indirect_pieced_value): Use check_typedef for VALUE's type. gdb/testsuite/ * gdb.dwarf2/implptr.S: Rebuilt. * gdb.dwarf2/implptr.c (intp, intpp, intppp): New typedefs. (bar): Use them for j, k, l. * gdb.dwarf2/implptr.exp: New variable opts. Support runtest parameter COMPILE. (print j in implptr:bar): Update for the intp typedef. (print p[0].x in implptr:foo): Use more exact regex.
* gdb/Jan Kratochvil2011-07-151-17/+32
| | | | | | | | | | | | | | | | | | Code cleanup. * dwarf2-frame.c (dwarf2_frame_ctx_funcs): New. (execute_stack_op): Use dwarf2_frame_ctx_funcs * dwarf2expr.c (dwarf_get_base_type): Access get_base_type via funcs. (execute_stack_op): Access read_reg, get_frame_base, read_mem, get_frame_cfa, get_tls_address and dwarf_call via funcs. * dwarf2expr.h (struct dwarf_expr_context): New forward declaration. (struct dwarf_expr_context_funcs): New, move here methods from ... (struct dwarf_expr_context): ... here. New fields funcs. * dwarf2loc.c (dwarf_expr_dwarf_call): Access get_frame_pc via funcs. (dwarf_expr_ctx_funcs): New. (dwarf2_evaluate_loc_desc_full): Use dwarf_expr_ctx_funcs. (needs_frame_dwarf_call): Access get_frame_pc via funcs. (needs_frame_ctx_funcs): New. (dwarf2_loc_desc_needs_frame): Use needs_frame_ctx_funcs.
* gdb/Jan Kratochvil2011-07-141-1/+1
| | | | | | | | | | | | | | | | | | Code cleanup - constify struct lval_funcs. * dwarf2loc.c (pieced_value_funcs): Make it const. * infrun.c (siginfo_value_funcs): Likewise. * opencl-lang.c (opencl_value_funcs): Likewise. * valops.c (value_assign, value_ind): Make the funcs variable const. * value.c (struct value): Make location.computed.funcs target const. Rearrange the comments. (allocate_computed_value): Make the funcs parameter target const. (value_computed_funcs): Return the funcs target const. (value_free, value_copy, set_value_component_location): Make the funcs variable const. * value.h (allocate_computed_value): Make the funcs parameter target const. (value_computed_funcs): Return the funcs target const. * windows-tdep.c (tlb_value_funcs): Make it const.
* gdb/Jan Kratochvil2011-07-131-9/+9
| | | | | | Code cleanup. * dwarf2loc.c (dwarf_expr_frame_base_1, dwarf2_evaluate_loc_desc_full): Indent prototypes so they do not get into tags.
* gdb/Jan Kratochvil2011-07-121-14/+3
| | | | | | | | | | Code cleanup making also optimized out values lazy. * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use allocate_optimized_out_value. Twice. (loclist_read_variable) Use allocate_optimized_out_value. Once. * findvar.c (read_var_value): Likewise. * value.c (allocate_optimized_out_value): New function. * value.h (allocate_optimized_out_value): New declaration.
* * dwarf2loc.c (locexpr_regname): New function.Tom Tromey2011-07-081-20/+94
| | | | | | | | | | | | (locexpr_describe_location_piece): Use it. (disassemble_dwarf_expression): Add per_cu argument. Use locexpr_regname. <DW_OP_GNU_deref_type, DW_OP_GNU_const_type, DW_OP_GNU_regval_type, DW_OP_GNU_convert, DW_OP_GNU_reinterpret>: New cases. (locexpr_describe_location_1): Add per_cu argument. (locexpr_describe_location): Update. (loclist_describe_location): Update.
* * dwarf2loc.c (disassemble_dwarf_expression): Fix instructionTom Tromey2011-05-131-2/+2
| | | | offset display.
* * utils.c (do_value_free): New function.Tom Tromey2011-05-131-1/+18
| | | | | | | | | | | | | | | (make_cleanup_value_free): Likewise. * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Handle value freeing correctly. (dwarf2_loc_desc_needs_frame): Call make_cleanup_value_free_to_mark. * dwarf2expr.h (struct dwarf_expr_context) <mark>: Remove field. * dwarf2expr.c (free_dwarf_expr_context): Don't call value_free_to_mark. (new_dwarf_expr_context): Don't call value_mark. * dwarf2-frame.c (execute_stack_op): Call make_cleanup_value_free_to_mark. * defs.h (make_cleanup_value_free): Declare.
* gdbTom Tromey2011-05-121-25/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PR gdb/12617: * value.h (value_from_contents): Declare. * value.c (value_from_contents): New function. * dwarf2read.c (dwarf_stack_op_name): Add new values. (dwarf2_get_die_type): New function. * dwarf2loc.c (dwarf_expr_get_base_type): New function. (allocate_piece_closure): Acquire reference to values. (read_pieced_value): Update for value-based expressions. (write_pieced_value): Likewise. (free_pieced_value_closure): Call value_free as needed. (dwarf2_evaluate_loc_desc_full): Set get_base_type field. Update for value-based expressions. * dwarf2loc.h (dwarf2_get_die_type): Declare. * dwarf2expr.h (struct dwarf_stack_value) <value>: Change type. <get_base_type>: New field. (struct dwarf_expr_piece) <v.value>: Change type. <v.regno>: New field. (struct dwarf_expr_context) <mark>: New field. (dwarf_expr_piece, dwarf_expr_fetch): Update. (dwarf_expr_pop, dwarf_expr_push): Remove. (dwarf_expr_push_address): Declare. * dwarf2expr.c (dwarf_arch_cookie): New global. (struct dwarf_gdbarch_types): New. (dwarf_gdbarch_types_init, dwarf_expr_address_type): New functions. (dwarf_expr_push): Change type of 'value' argument. Update. Now static. (dwarf_expr_push_address): New function. (dwarf_expr_pop): Now static. (dwarf_expr_fetch): Change return type. (dwarf_require_integral): New function. (dwarf_expr_fetch): Simplify. (add_piece): Update. (base_types_equal_p, dwarf_get_base_type, get_unsigned_type): New functions. (execute_stack_op) <sign_ext>: Remove. Use values for DWARF stack. <DW_OP_GNU_const_type, DW_OP_GNU_deref_type, DW_OP_GNU_regval_type, DW_OP_GNU_convert, DW_OP_GNU_reinterpret>: New cases. (_initialize_dwarf2expr): New function. (add_piece): Update. (new_dwarf_expr_context): Set new field. (free_dwarf_expr_context): Call value_free_to_mark. * dwarf2-frame.c (no_base_type): New function. (execute_stack_op): Set get_base_type field. Update. gdb/testsuite * gdb.dwarf2/typeddwarf.S: New file. * gdb.dwarf2/typeddwarf.c: New file. * gdb.dwarf2/typeddwarf.exp: New file.
* gdb/Jan Kratochvil2011-03-221-1/+6
| | | | | | | | | | | | * dwarf2expr.c (execute_stack_op): Handle DW_OP_GNU_entry_value. New label abort_expression. * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Handle DWARF_VALUE_OPTIMIZED_OUT. gdb/testsuite/ * gdb.dwarf2/dw2-entry-value-main.c: New file. * gdb.dwarf2/dw2-entry-value.S: New file. * gdb.dwarf2/dw2-entry-value.exp: New file.
* gdb/Pedro Alves2011-03-181-1/+17
| | | | | * dwarf2loc.c (dwarf2_evaluate_loc_desc): Catch NOT_AVAILABLE_ERROR when evaluating the location expression.
* gdb/Pedro Alves2011-03-181-4/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * dwarf2loc.c (read_pieced_value): Handle get_frame_register_bytes returning that the register piece is unavailable/optimized out. (write_pieced_value): Handle get_frame_register_bytes returning that the register piece is unavailable/optimized out when doing a read-modify write of a bitfield. * findvar.c (value_from_register): Handle get_frame_register_bytes returning that the register piece is unavailable/optimized out. * frame.c (get_frame_register_bytes): New parameters `optimizedp' and `unavailablep'. Throw error on bad debug info. Use frame_register instead of frame_register_read, to fill in the new arguments. * frame.h (get_frame_register_bytes): New parameters `optimizedp' and `unavailablep'. * valops.c: (value_assign): Adjust, and handle get_frame_register_bytes failing. * spu-tdep.c: Include exceptions.h. (spu_software_single_step): Adjust, and handle get_frame_register_bytes failing. (spu_get_longjmp_target): Ditto. * gdbarch.sh (register_to_value): Change to return int. New parameters `optimizedp' and `unavailablep'. * gdbarch.h, gdbarch.c: Regenerate. * i386-tdep.c (i386_register_to_value): Adjust to new gdbarch_register_to_value interface. * i387-tdep.c (i387_register_to_value): Ditto. * i387-tdep.h (i387_register_to_value): Ditto. * alpha-tdep.c (alpha_register_to_value): Ditto. * ia64-tdep.c (ia64_register_to_value): Ditto. * m68k-tdep.c (m68k_register_to_value): Ditto. * mips-tdep.c (mips_register_to_value): Ditto. * rs6000-tdep.c (rs6000_register_to_value): Ditto.
* PR gdb/12576:Tom Tromey2011-03-141-4/+4
| | | | | * dwarf2loc.c (dwarf_expr_dwarf_call): Remove 'return'. (needs_frame_dwarf_call): Likewise.
* 2011-03-04 Michael Snyder <msnyder@vmware.com>Michael Snyder2011-03-071-0/+1
| | | | * dwarf2loc.c (indirect_pieced_value): Assert 'piece' not null.
* 2011-02-26 Michael Snyder <msnyder@vmware.com>Michael Snyder2011-02-271-4/+4
| | | | | * dwarf2loc.c (insert_bits): Avoid shadowing a function param with a local variable of the same name.
* gdb/Jan Kratochvil2011-02-251-14/+10
| | | | | | | | * dwarf2loc.c (disassemble_dwarf_expression) <DW_OP_breg[0-9]+>: Use L and plongest. (disassemble_dwarf_expression) <DW_OP_bregx>: Drop variable offset, use L and plongest. (disassemble_dwarf_expression) <DW_OP_fbreg>: Use L and plongest.
* gdbTom Tromey2011-02-181-23/+3
| | | | | | | | | | | | | | | | | * ax-general.c (aop_map): Add pick and rot. * dwarf2loc.c (compile_dwarf_to_ax) <DW_OP_over>: Reimplement. <DW_OP_rot>: Implement. * ax.h (enum agent_op) <aop_pick, aop_rot>: New constants. (ax_pick): Declare. * ax-general.c (ax_pick): New function. doc * agentexpr.texi (Bytecode Descriptions): Document pick and rot. gdbserver * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick, gdb_agent_op_rot>: New constants. (gdb_agent_op_names): Add pick and roll. (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New cases.
* * dwarf2loc.h (dwarf2_compile_expr_to_ax): Declare.Tom Tromey2011-02-171-16/+17
| | | | | | | | | | | | | * dwarf2loc.c (dwarf2_compile_expr_to_ax): Rename from compile_dwarf_to_ax. No longer static. Call dwarf2_compile_cfa_to_ax. (locexpr_tracepoint_var_ref): Update. (loclist_tracepoint_var_ref): Update. * dwarf2-frame.h (dwarf2_compile_cfa_to_ax): Declare. * dwarf2-frame.c (execute_cfa_program): Remove 'this_frame' argument; add 'gdbarch' and 'pc'. (dwarf2_compile_cfa_to_ax): New function. (dwarf2_frame_cache): Update.
* * dwarf2loc.c (unimplemented): Fix typo.Tom Tromey2011-02-161-1/+2
|