aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite
AgeCommit message (Collapse)AuthorFilesLines
2009-09-02 * gdb.dwarf2/callframecfa.exp: Use gdb_continue_to_breakpoint.Tom Tromey2-2/+10
2009-09-02gdbTom Tromey3-0/+369
* frame.h (frame_unwinder_is): Declare. * frame.c (frame_unwinder_is): New function. * dwarf2loc.c: Include dwarf2-frame.h. (dwarf_expr_frame_cfa): New function. (dwarf2_evaluate_loc_desc): Use it. (needs_frame_frame_cfa): New function. (dwarf2_loc_desc_needs_frame): Use it. * dwarf2expr.h (struct dwarf_expr_context) <get_frame_cfa>: New field. * dwarf2expr.c (execute_stack_op) <DW_OP_call_frame_cfa>: New case. * dwarf2-frame.h (dwarf2_frame_cfa): Declare. * dwarf2-frame.c (no_get_frame_cfa): New function. (execute_stack_op): Use it. (dwarf2_frame_cfa): New function. gdb/testsuite * gdb.dwarf2/callframecfa.exp: New file. * gdb.dwarf2/callframecfa.S: New file.
2009-09-01gdb/testsuite/Jan Kratochvil4-0/+196
* gdb.base/solib-overlap.exp, gdb.base/solib-overlap-lib.c, gdb.base/solib-overlap-main.c: New.
2009-08-28 PR gdb/10565Daniel Jacobowitz3-0/+41
* value.c (value_primitive_field): Do not save value_offset for bitfields. (unpack_bits_as_long): Do not read an entire ULONGEST. testsuite/ PR gdb/10565 * gdb.base/bitfields.c (struct container, container): New. (main): Initialize it and call break5. * gdb.base/bitfields.exp (bitfield_at_offset): New test.
2009-08-28gdb/Jan Kratochvil3-0/+143
Support constant DW_AT_data_member_location by GCC PR debug/40659. * dwarf2read.c (dwarf2_add_field <DW_TAG_member> <DW_AT_data_member_location>): Initialize BYTE_OFFSET to 0 by default. Explicitly check if attr_form_is_block. (dwarf2_add_field <DW_TAG_inheritance> <DW_AT_data_member_location>) (read_common_block <DW_AT_data_member_location>): New variable byte_offset. Fix crash on non-DW_BLOCK ATTR values. gdb/testsuite/ Support constant DW_AT_data_member_location by GCC PR debug/40659. * gdb.dwarf2/dw2-inheritance.exp, gdb.dwarf2/dw2-inheritance.S: New.
2009-08-27gdb/Jan Kratochvil2-0/+9
* varobj.c (varobj_create): Error if the specified frame was not found and it is needed. gdb/testsuite/ * gdb.mi/mi2-var-cmd.exp (create variable with invalid FRAME-ADDR): New.
2009-08-272009-08-26 Michael Snyder <msnyder@vmware.com>Michael Snyder4-1/+341
* gdb.base/i386-reverse.c: New file. * gdb.base/i386-reverse.exp: New file. * gdb.base/Makefile.in: Add new files to be removed.
2009-08-26 * gdb.mi/mi-basics.exp (test_cwd_specification): Do not testJoseph Myers3-2/+16
environment-pwd for remote host. * gdb.mi/mi2-basics.exp (test_cwd_specification): Likewise.
2009-08-24 * gdb.cp/cpcompletion.exp (test_class_complete): New procedure.Keith Seitz2-0/+48
Add two new C++ completer tests which limit the output to a given class.
2009-08-242009-08-24 Michael Snyder <msnyder@vmware.com>Michael Snyder3-3/+8
* gdb.base/del.exp: Fix typo in comment. * gdb.base/step-bt.exp: Fix cut and paste error in comment.
2009-08-22Regenerate tree using Autoconf 2.64 and Automake 1.11.Ralf Wildenhues9-10783/+15898
config/: * override.m4 (_GCC_AUTOCONF_VERSION): Bump to 2.64. /: * configure: Regenerate. etc/: * configure: Regenerate. sim/common/: * config.in: Regenerate. * configure: Likewise. sim/iq2000/: * config.in: Regenerate. * configure: Likewise. sim/d10v/: * config.in: Regenerate. * configure: Likewise. sim/igen/: * config.in: Regenerate. * configure: Likewise. sim/m32r/: * config.in: Regenerate. * configure: Likewise. sim/frv/: * config.in: Regenerate. * configure: Likewise. sim/: * avr/config.in: Regenerate. * avr/configure: Likewise. * configure: Likewise. * cris/config.in: Likewise. * cris/configure: Likewise. sim/h8300/: * config.in: Regenerate. * configure: Likewise. sim/mn10300/: * config.in: Regenerate. * configure: Likewise. sim/ppc/: * config.in: Regenerate. * configure: Likewise. sim/erc32/: * config.in: Regenerate. * configure: Likewise. sim/arm/: * config.in: Regenerate. * configure: Likewise. sim/m68hc11/: * config.in: Regenerate. * configure: Likewise. sim/lm32/: * config.in: Regenerate. * configure: Likewise. sim/sh64/: * config.in: Regenerate. * configure: Likewise. sim/v850/: * config.in: Regenerate. * configure: Likewise. sim/cr16/: * config.in: Regenerate. * configure: Likewise. sim/moxie/: * config.in: Regenerate. * configure: Likewise. sim/m32c/: * config.in: Regenerate. * configure: Likewise. sim/mips/: * config.in: Regenerate. * configure: Likewise. sim/mcore/: * config.in: Regenerate. * configure: Likewise. sim/testsuite/d10v-elf/: * configure: Regenerate. sim/testsuite/: * configure: Regenerate. sim/testsuite/frv-elf/: * configure: Regenerate. sim/testsuite/m32r-elf/: * configure: Regenerate. sim/testsuite/mips64el-elf/: * configure: Regenerate. sim/sh/: * config.in: Regenerate. * configure: Likewise. gold/: * Makefile.in: Regenerate. * aclocal.m4: Likewise. * config.in: Likewise. * configure: Likewise. * testsuite/Makefile.in: Likewise. gprof/: * Makefile.in: Regenerate. * aclocal.m4: Likewise. * configure: Likewise. * gconfig.in: Likewise. opcodes/: * Makefile.in: Regenerate. * aclocal.m4: Likewise. * config.in: Likewise. * configure: Likewise. gas/: * Makefile.in: Regenerate. * aclocal.m4: Likewise. * config.in: Likewise. * configure: Likewise. * doc/Makefile.in: Likewise. ld/: * Makefile.in: Regenerate. * aclocal.m4: Likewise. * config.in: Likewise. * configure: Likewise. gdb/: * aclocal.m4: Regenerate. * config.in: Likewise. * configure: Likewise. * gnulib/Makefile.in: Likewise. gdb/doc/: * configure: Regenerate. gdb/gdbserver/: * aclocal.m4: Regenerate. * config.in: Likewise. * configure: Likewise. gdb/testsuite/: * configure: Regenerate. * gdb.hp/configure: Likewise. * gdb.hp/gdb.aCC/configure: Likewise. * gdb.hp/gdb.base-hp/configure: Likewise. * gdb.hp/gdb.compat/configure: Likewise. * gdb.hp/gdb.defects/configure: Likewise. * gdb.hp/gdb.objdbg/configure: Likewise. * gdb.stabs/configure: Likewise. binutils/: * Makefile.in: Regenerate. * aclocal.m4: Likewise. * config.in: Likewise. * configure: Likewise. * doc/Makefile.in: Likewise. bfd/: * Makefile.in: Regenerate. * aclocal.m4: Likewise. * config.in: Likewise. * configure: Likewise. bfd/doc/: * Makefile.in: Regenerate. readline/: * configure: Regenerate. readline/examples/rlfe/: * configure: Regenerate.
2009-08-19ChangeLog:Ulrich Weigand3-0/+40
* value.c (enum internalvar_kind): Replace INTERNALVAR_SCALAR by INTERNALVAR_INTEGER and INTERNALVAR_POINTER. (union internalvar_data): Replace "scalar" member by "integer" and "pointer". (value_of_internalvar): Handle INTERNALVAR_INTEGER and INTERNALVAR_POINTER instead of INTERNALVAR_SCALAR. (get_internalvar_integer): Likewise. (set_internalvar): Likewise. (set_internalvar_integer): Likewise. (preserve_one_internalvar): Likewise. (value_from_pointer): Handle typedef'd pointer types. testsuite/ChangeLog: 2009-08-19 Doug Evans <dje@google.com> * gdb.base/gdbvars.c: New file. * gdb.base/gdbvars.exp: Test convenience vars with program variables.
2009-08-142009-08-14 Pedro Alves <pedro@codesourcery.com>Pedro Alves4-3/+8
gdb/ * top.c (any_thread_of): Delete. (kill_or_detach): Use any_thread_of_process. * top.c (print_inferior_quit_action): New. (quit_confirm): Rewrite to print info about all inferiors. * target.c (dispose_inferior): New. (target_preopen): Use it. 2009-08-14 Pedro Alves <pedro@codesourcery.com> gdb/testsuite/ * gdb.threads/killed.exp, gdb.threads/manythreads.exp, gdb.threads/staticthreads.exp: Adjust to "quit" output changes.
2009-08-132009-08-13 Pedro Alves <pedro@codesourcery.com>Pedro Alves3-2/+10
PR gdb/8869: * language.c (language, type, range, case_sensitive): Make const. (show_language_command): Don't call deprecated_show_value_hack. Special case "auto". (set_language_command): An unrecognized language is now an internal error instead of a user error. Don't call set_lang_str. (show_type_command): Don't call deprecated_show_value_hack. Special case "auto". Use warning. (set_type_command): An unrecognized type is now an internal error instead of a user error. Output type check mismatch with language here. Don't call set_type_str. (show_range_command): Don't call deprecated_show_value_hack. Special case "auto". Use warning. (set_range_command): An unrecognized range check is now an internal error instead of a warning. Output range check mismatch with language here. Don't call set_range_str. (show_case_command): Don't call deprecated_show_value_hack. Special case "auto". Use warning. (set_case_command): Don't call set_case_str. An unrecognized case check is now an internal error instead of a warning. Output range check mismatch with language here. Don't call set_case_str. (set_type_range_case): Don't call set_type_str, set_range_str or set_case_str here. (set_lang_str, set_type_str, set_range_str, set_case_str): Delete. (add_language): Install or reinstall the "set language" command here, and make it an enum command. Build the enumeration and the help string from the current list of known languages. (_initialize_language): Don't install "set language" here. Make "set check type", "set check range" and "set case-sensitive" enum commands. Register the "auto" "local" and "unknown" languages in that order. 2009-08-13 Pedro Alves <pedro@codesourcery.com> * gdb.base/default.exp: Adjust "set language test": it's now an enum command. Larger help string moved to "help set language". * gdb.base/help.exp: Adjust "help set language" expected output, now lists all known languages.
2009-08-11 * gdb.arch/altivec-abi.exp (altivec_abi_tests): Turn on printing ofNathan Froyd3-0/+9
all frame arguments. * gdb.arch/altivec-regs.exp: Likewise.
2009-08-07gdbTom Tromey2-0/+20
* language.c (set_language_command): Strip whitespace. (set_type_command): Likewise. (set_range_command): Likewise. gdb/testsuite * gdb.base/setshow.exp: Add tests for changes to set language, set check range, and set check type.
2009-08-042009-08-04 Thiago Jung Bauermann <thiago.bauermann@gmail.com>Thiago Jung Bauermann2-0/+92
gdb/ * linux-tdep.c (check_is_pie_binary, _initialize_linux_tdep): New functions. gdb/testsuite/ * gdb.base/pie-support.exp: New file. * gdb.base/pie-support.c: New file.
2009-08-03 Implement -break-commandsVladimir Prus3-6/+39
* breakpoint.c (get_breakpoint, breakpoint_set_commands): New. (commands_command): Use breakpoint_set_commands. * breakpoint.h (get_breakpoint, breakpoint_set_commands): Declare. * mi/mi-cmds.h (mi_cmd_break_commands): New. * mi/mi-cmds.c: Register -break-commands. * mi/mi-cmd-break.c (mi_cmd_break_commands, mi_read_next_line) (mi_command_line_array, mi_command_line_array_cnt) (mi_command_line_array_ptr): New.
2009-08-03 Refactor reading of commandsVladimir Prus1-0/+3
* defs.h (read_command_lines_1): Declare. * cli/cli-script.c (read_next_line): Only return string, do not process. (process_next_line): New, extracted from read_next_line. (recurse_read_control_structure): Take a function pointer to the read function. (get_command_line) Pass the read_next_line as reader function into recurse_read_control_structure. (read_command_lines_1): New, extracted from... (read_command_lines): ...here.
2009-07-31Fix previous check-in.Ulrich Weigand1-0/+182
2009-07-31 * configure.ac: Run gdb.cell tests when appropriate.Ulrich Weigand39-0/+4999
* configure: Regenerate. * lib/cell.exp: New file. * gdb.cell: New directory. * gdb.cell/configure.ac: New file. * gdb.cell/configure: New file. * gdb.cell/Makefile.in: New file. * gdb.cell/arch.exp: New file. * gdb.cell/break.c: New file. * gdb.cell/break.exp: New file. * gdb.cell/break-spu.c: New file. * gdb.cell/bt.c: New file. * gdb.cell/bt2-spu.c: New file. * gdb.cell/bt-spu.c: New file. * gdb.cell/bt.exp: New file. * gdb.cell/coremaker.c: New file. * gdb.cell/coremaker-spu.c: New file. * gdb.cell/core.exp: New file. * gdb.cell/gcore.exp: New file. * gdb.cell/data.c: New file. * gdb.cell/data.exp: New file. * gdb.cell/data-spu.c: New file. * gdb.cell/ea-cache.exp: New file. * gdb.cell/ea-cache.c: New file. * gdb.cell/ea-cache-spu.c: New file. * gdb.cell/ea-standalone.c: New file. * gdb.cell/ea-standalone.exp: New file. * gdb.cell/ea-test.c: New file. * gdb.cell/ea-test.exp: New file. * gdb.cell/f-regs.exp: New file. * gdb.cell/mem-access.c: New file. * gdb.cell/mem-access.exp: New file. * gdb.cell/mem-access-spu.c: New file. * gdb.cell/ptype.exp: New file. * gdb.cell/registers.exp: New file. * gdb.cell/size.c: New file. * gdb.cell/sizeof.exp: New file. * gdb.cell/size-spu.c: New file. * gdb.cell/solib.exp: New file. * gdb.cell/solib-symbol.exp: New file.
2009-07-31ChangeLog:Ulrich Weigand2-0/+14
* target.h (enum strata): New value arch_stratum. * target.c (target_require_runnable): Skip arch_stratum targets. * configure.tgt (powerpc-*-linux* | powerpc64-*-linux*): Add solib-spu.o and spu-multiarch.o to gdb_target_obs. * Makefile.in (ALL_TARGET_OBS): Add solib-spu.o and spu-multiarch.o. (ALLDEPFILES): Add solib-spu.c and spu-multiarch.c. * solib-spu.c: New file. * solib-spu.h: New file. * spu-multiarch.c: New file. * spu-tdep.h (SPUADDR, SPUADDR_SPU, SPUADDR_ADDR): New macros. * spu-tdep.c (struct gdbarch_tdep): New member id. (spu_gdbarch_id): New function. (spu_lslr): New function. (spu_address_to_pointer): New function. (spu_pointer_to_address): Support SPU ID address encoding. Use spu_gdbarch_id and spu_lslr. (spu_integer_to_address): Likewise. (spu_frame_unwind_cache): Update for encoded addresses. (spu_unwind_pc, spu_unwind_sp): Likewise. (spu_read_pc, spu_write_pc): Likewise. (spu_push_dummy_call): Likewise. (spu_software_single_step): Likewise. (spu_get_longjmp_target): Likewise. (spu_overlay_update_osect): Likewise. (spu_dis_asm_print_address): New function. (gdb_print_insn_spu): Likewise. (spu_gdbarch_init): Store SPU ID in tdep structure. Install spu_address_to_pointer and gdb_print_insn_spu. * ppc-linux-tdep.c: Include "observer.h", "auxv.h", "elf/common.h" and "solib-spu.h". (ppc_linux_entry_point_addr): New static variable. (ppc_linux_inferior_created): New function. (ppc_linux_displaced_step_location): Likewise. (ppc_linux_init_abi): Enable Cell/B.E. support if supported by the target. (_initialize_ppc_linux_tdep): Attach to inferior_created observer. * NEWS: Mention multi-architecture and Cell/B.E. debugging capabilities. testsuite/ChangeLog: * gdb.xml/tdesc-regs.exp: Skip for SPU targets.
2009-07-28 * NEWS: Mention ARM VFP support.Daniel Jacobowitz2-0/+9
* target-descriptions.c (tdesc_register_type): Make public. (tdesc_unnumbered_register): New function. (tdesc_register_reggroup_p): Allow missing pseudo_register_reggroup_p. * target-descriptions.h (tdesc_register_type): Declare. (tdesc_unnumbered_register): Declare. * arm-tdep.c (arm_neon_quad_read, arm_neon_quad_write): New functions. (arm_push_dummy_call): Use arm_neon_quad_write. (arm_neon_double_type, arm_neon_quad_type): New functions. (arm_register_type): Handle VFP and NEON registers. Override the types of double-precision registers for NEON. Disable FPA registers if they are not present. (arm_dwarf_reg_to_regnum): Add current VFP and NEON register numbers. (arm_return_value): Use arm_neon_quad_write and arm_neon_quad_read. (arm_register_name): Handle VFP single and NEON quad registers. (arm_pseudo_read, arm_pseudo_write): New functions. (arm_gdbarch_init): Check for VFP and NEON in the target description. Assign numbers to double-precision registers. Register VFP and NEON pseudo registers. Remove a shadowed "i" variable. * arm-tdep.h (enum gdb_regnum): Add ARM_D0_REGNUM and ARM_D31_REGNUM. (struct gdbarch_tdep): Add have_neon_pseudos, have_neon, have_vfp_registers, have_vfp_pseudos, neon_double_type, and neon_quad_type. * features/Makefile: Make expedite settings only architecture specific. (WHICH): Add new ARM descriptions. * features/arm-with-neon.xml, features/arm-with-vfpv2.c, features/arm-with-vfpv3.c, features/arm-vfpv2.xml, features/arm-vfpv3.xml, features/arm-with-vfpv2.xml, features/arm-with-vfpv3.xml, features/arm-with-neon.c: New files. * regformats/arm-with-neon.dat, regformats/arm-with-vfpv2.dat, regformats/arm-with-vfpv3.dat: Generate. doc/ * gdb.texinfo (ARM Features): Document org.gnu.gdb.arm.vfp and org.gnu.gdb.arm.neon. gdbserver/ * linux-low.c (linux_write_memory): Update debugging output. * Makefile.in (clean): Add new descriptions. (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o) (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules. * configure.srv: Add new files for arm*-*-linux*. * linux-arm-low.c: Add new declarations. (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined. (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3) (HWCAP_VFPv3D16): New. (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT instead of __IWMMXT__. (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap) (arm_arch_setup): New. (target_regsets): Remove #ifdef. Add VFP regset. (the_low_target): Use arm_arch_setup. testsuite/ * gdb.base/float.exp: Handle VFP registers.
2009-07-152009-07-14 Michael Snyder <msnyder@vmware.com>Michael Snyder2-34/+9
* gdb.reverse/finish-reverse.exp: Do not expect reverse-finish to bring gdb to the beginning of the calling line.
2009-07-152009-07-14 Michael Snyder <msnyder@vmware.com>Michael Snyder2-0/+10
* gdb.arch/i386-signal.c (sigframe): Add a nop to avoid confusing the i386 epilogue unwinder.
2009-07-14 gdb/Stan Shebs2-1/+10
Conditional tracepoints. * ax-gdb.h (gen_eval_for_expr): Declare. * ax-gdb.c (gen_expr): Generate bytecodes for BINOP_EQUAL and other comparisons. (gen_eval_for_expr): New function. (agent_eval_command): New maintenance command. (_initialize_ax_gdb): Define the command. * remote.c (struct remote_state): New field cond_tracepoints. (PACKET_ConditionalTracepoints): New packet config type. (remote_cond_tracepoint_feature): New function. (remote_protocol_features): Add ConditionalTracepoints. (remote_supports_cond_tracepoints): New function. (_initialize_remote): Add ConditionalTracepoints. * tracepoint.c (download_tracepoint): Add conditional. * NEWS: Mention conditional tracepoints. gdb/doc/ * gdb.texinfo (Tracepoint Conditions): New section. (General Query Packets): Describe ConditionalTracepoints. (Tracepoint Packets): Describe condition field. (Maintenance Commands): Describe maint agent-eval. * agentexpr.texi (Using Agent Expressions): Mention eval usage. gdb/testsuite/ * gdb.trace/tracecmd.exp: Add basic test of tracepoint conditions.
2009-07-142009-07-14 Michael Snyder <msnyder@vmware.com>Michael Snyder2-2/+12
* gdb.reverse/step-reverse.exp (stepi into function call): Call instruction may not be first instruction in the line. (reverse stepi from a function call): Used wrong line number.
2009-07-13gdb/Jan Kratochvil3-0/+71
Fix memory access from signed 32bit inferior registers on 64bit GDB. * linux-nat.c (linux_xfer_partial <TARGET_OBJECT_MEMORY>): New variable addr_bit. Mask OFFSET by the ADDR_BIT width. gdb/testsuite/ * gdb.arch/amd64-i386-address.exp, gdb.arch/amd64-i386-address.S: New.
2009-07-13gdb/testsuite/Jan Kratochvil5-54/+22
Fix gdb.base/macscp.exp when using custom inputrc. * gdb.base/completion.exp: Remove env(INPUTRC) set and restore. * gdb.base/readline.exp: Remove env(INPUTRC) set and restore. Remove env(TERM) set. * gdb.cp/cpcompletion.exp: Remove env(INPUTRC) set. * lib/gdb.exp (default_gdb_start): Add env(INPUTRC) and env(TERM) set.
2009-07-13gdb/testsuite/Jan Kratochvil13-139/+51
Fix racy clashing of output files for gdb.base{1,2}/ parallel run. * gdb.base/annota1.exp (thread_test): Import global $testfile. Change the compilation target to match the testcase name. * gdb.base/sect-cmd.exp: Change the compilation target to match the testcase name. * a2-run.exp: Use for setup prepare_for_testing. Change the compilation target to match the testcase name. * gdb.base/commands.exp: Likewise. * gdb.base/finish.exp: Likewise. * gdb.base/float.exp: Likewise. * gdb.base/info-target.exp: Likewise. * gdb.base/relational.exp: Likewise. * gdb.base/term.exp: Likewise. * gdb.base/until.exp: Likewise. * gdb.base/volatile.exp: Likewise. * gdb.base/whatis-exp.exp: Likewise.
2009-07-112009-07-11 Hui Zhu <teawater@gmail.com>Hui Zhu2-1/+5
* gdb.base/help.exp (disassemble): Update expected help text.
2009-07-10gdb/docTom Tromey2-0/+51
* gdbint.texinfo (Testsuite): Document test transcripts. gdb/testsuite * lib/gdb.exp: Handle TRANSCRIPT. (remote_spawn, remote_close, send_gdb): New procs.
2009-07-102009-07-10 Phil Muldoon <pmuldoon@redhat.com>Phil Muldoon6-0/+57
* python/python-internal.h (apply_varobj_pretty_printer): Update definition. (python_string_to_target_python_string): Add definition. * python/python-utils.c (unicode_to_encoded_python_string) (unicode_to_target_python_string) (python_string_to_target_python_string): New Functions. * python/python-prettyprint.c (pretty_print_one_value): Likewise. (print_string_repr): Refactor to logic to account for PyObject returned strings. (apply_varobj_pretty_printer): Likewise. * python/python-value.c (valpy_string): Parse length keyword. Use length keyword in LA_GET_STRING. * varobj.c (value_get_print_value): Refactor logic to account for PyObject returned strings. * c-lang.c (c_get_string): If the length parameter is specified, use that. Return value in characters. Update comments. * language.h: Update c_get_string prototype comments. 2009-07-10 Phil Muldoon <pmuldoon@redhat.com> * gdb.texinfo (Values From Inferior): Add length parameter description. 2009-07-10 Phil Muldoon <pmuldoon@redhat.com> * gdb.python/python-prettyprint.c: Add counted null string structure. * gdb.python/python-prettyprint.exp: Print null string. Test for embedded nulls. * gdb.python/python-prettyprint.py (pp_ns): New Function. * gdb.python/python-value.exp (test_value_in_inferior): Add variable length string fetch tests. * gdb.python/python-value.c (main): Add strings for string fetch tests.
2009-07-09gdb/Jan Kratochvil2-0/+8
Report error on inaccessible memory. * cli/cli-dump.c: Include gdbcore.h. (dump_memory_to_file): Call read_memory instead of target_read_memory. gdb/testsuite/ * gdb.base/dump.exp (inaccessible memory is reported): New test.
2009-07-07gdbTom Tromey14-55/+76
* c-lang.c (convert_octal): Only allow 3 octal digits. (print_wchar): Prefer 3-digit octal form. Fall back to hex if needed. * c-exp.y (c_parse_escape): Only allow 3 octal digits. gdb/testsuite * gdb.base/call-rt-st.exp: Update for change to escape output. * gdb.base/callfuncs.exp: Likewise. * gdb.base/charset.exp: Likewise. * gdb.base/constvars.exp: Likewise. * gdb.base/long_long.exp: Likewise. * gdb.base/pointers.exp: Likewise. * gdb.base/printcmds.exp: Likewise. * gdb.base/setvar.exp: Likewise. * gdb.base/store.exp: Likewise. * gdb.cp/ref-types.exp: Likewise. * gdb.mi/mi-var-child.exp: Likewise. * gdb.mi/mi-var-display.exp: Likewise. * gdb.mi/mi2-var-display.exp: Likewise. * gdb.base/charset.exp: Test octal escape sequence length. Update for change to escape output.
2009-07-07gdb/testsuite/Jan Kratochvil2-0/+8
* gdb.mi/mi2-var-cmd.exp (floating varobj invalidation): New test.
2009-07-06 * lib/java.exp (java_init): Ignore $GCJ if it is empty.Daniel Jacobowitz2-1/+5
2009-07-06gdb/testsuite/Jan Kratochvil2-19/+37
* lib/gdbserver-support.exp (gdbserver_start): Loop spawning gdbserver increasing $portnum if "Can't bind address" has been seen.
2009-07-05 * gdb.base/ending-run.exp: Add "step out of main" pattern forPedro Alves2-0/+9
mingw32ce.
2009-07-05 * gdb.base/long_long.exp: arm-mingw32ce defaults to natural-endianPedro Alves2-0/+6
VFP format.
2009-07-02gdb/Pedro Alves4-39/+63
2009-07-02 Pedro Alves <pedro@codesourcery.com> * linux-nat.c (linux_child_follow_fork): If we're staying attached to the child process, enable event reporting on it. Don't handle checkpoints here. Instead, add the child fork to the lwp thread and inferior lists without clobbering the previous inferior. Let the thread_db layer learn about a new child process, even if following the parent. (linux_nat_switch_fork): Delete lwps of the current inferior only, instead of clearing the whole list. Use thread_change_ptid to give the core the illusion the new checkpoint is still the same inferior. Clear the register cache. (linux_handle_extended_wait): Handle checkpoints here. (linux_multi_process): Turn on. * linux-fork.c (struct fork_info) <pc>: Remove field. (init_fork_list): Do not delete the checkpoint from the inferior list (it is not there). (fork_load_infrun_state): Don't switch inferior_ptid here. Pass the new checkpoint's ptid to linux_nat_switch_fork. (fork_save_infrun_state): Make static. Don't stop the pc field of fork_info, it's gone. (linux_fork_mourn_inferior): Don't delete the checkpoint from the inferior list, it's not there. (linux_fork_detach): Ditto. (delete_fork_command): Replace mention of fork/checkpoint by checkpoint only. (detach_fork_command): Likewise. Don't delete the checkpoint from the inferior list. (info_forks_command): Adjust. (restore_detach_fork): Delete. (checkpointing_pid): New. (linux_fork_checkpointing_p): New. (save_detach_fork): Delete. (checkpoint_command): Delete temp_detach_fork. Don't remove breakpoints, that's a nop. Store the pid of the process we're checkpointing, and use make_cleanup_restore_integer to restore it. Don't reinsert breakpoints here. (process_command, fork_command): Delete. (restart_command): Update comments to only mention checkpoints, not forks. (_initialize_linux_fork): Delete "fork", "process", "info forks" commands. * linux-fork.h (fork_save_infrun_state, fork_list): Delete declarations. (linux_fork_checkpointing_p): Declare. * cli/cli-cmds.c (killlist): New. * cli/cli-cmds.h (killlist): Declare. * gdbcmd.h (killlist): Declare. * inferior.c: Include "gdbthread.h". (detach_inferior_command, kill_inferior_command) (inferior_command): New. (info_inferiors_command): Allow specifying a specific inferior id. (_initialize_inferiors): Register "inferior", "kill inferior" and "detach inferior" commands. * infcmd.c (_initialize_infcmd): Make "kill" a prefix command. * gdbthread.h (any_thread_of_process): Declare. * thread.c (any_thread_of_process): New. * NEWS: Mention multi-inferior debugging. Mention 'info inferiors', 'inferior', 'detach inferior' and 'kill inferior' as new commands. (Removed commands): New section, mentioning that 'info forks', 'fork', 'process', 'delete fork' and 'detach fork' are now gone. gdb/testsuite/ 2009-07-02 Pedro Alves <pedro@codesourcery.com> * gdb.base/multi-forks.exp: Only run detach-on-fork tests on linux. Adjust to use "inferior", "info inferiors", "detach inferior" and "kill inferior" instead of "restart", "info fork", "detach fork" and "delete fork". * gdb.base/ending-run.exp: Spell out "info". * gdb.base/help.exp: Adjust to use test_prefix_command_help for the "kill" command. gdb/doc/ 2009-07-02 Pedro Alves <pedro@codesourcery.com> * gdb.texinfo (Debugging multiple inferiors): Document the "inferior", "detach inferior" and "kill inferior" commands. (Debugging Programs with Multiple Processes): Adjust to mention generic "inferior" commands. Delete mention of "detach fork" and "delete fork". Cross reference to "Debugging multiple inferiors" section.
2009-07-02 * defs.h (strlen_paddr, paddr, paddr_nz): Remove.Ulrich Weigand2-1/+6
(paddress): Add GDBARCH parameter. * utils.c (strlen_paddr, paddr, paddr_nz): Remove. (paddress): Add GDBARCH parameter, use it instead of current_gdbarch. * ui-out.h (ui_out_field_core_addr): Add GDBARCH parameter. * ui-out.c (ui_out_field_core_addr): Add GDBARCH parameter, use it instead of current_gdbarch. Update calls to ui_out_field_core_addr to pass architecture: * ada-lang.c (print_one_exception): Update. * breakpoint.c (print_one_breakpoint_location, print_one_exception_catchpoint): Update. * disasm.c (dump_insns): Update. * darwin-nat-info.c (darwin_debug_regions_recurse): Update. * mi/mi-main.c (mi_cmd_data_read_memory): Update. * mi/mi-symbol-cmds.c: Include "objfiles.h". (mi_cmd_symbol_list_lines): Update. * stack.c (print_frame_info, print_frame): Update. Update callers of paddress to pass architecture: * ada-tasks.c (info_task): Update. * ada-valprint.c (ada_val_print_1): Update. * annotate.c (annotate_source, annotate_frame_begin): Update. * breakpoint.c (insert_bp_location, describe_other_breakpoints, mention): Update. * cli/cli-cmds.c (edit_command, list_command, print_disassembly): Update. * corefile.c (memory_error): Update. * c-valprint.c (print_function_pointer_address, c_val_print): Update. * disasm.c (dis_asm_print_address): Update. * exec.c (print_section_info): Update. * f-valprint.c (f_val_print): Update. * infcmd.c: Include "arch-utils.h". (jump_command, program_info): Update. * linux-fork.c: Include "arch-utils.h". (info_forks_command): Update. * m2-valprint.c (print_function_pointer_address, print_unpacked_pointer, print_variable_at_address, m2_val_print): Update. * m32r-rom.c (m32r_load_section, m32r_load, m32r_upload_command): Update. * printcmd.c (print_address, print_address_demangle, address_info): Update. * p-valprint.c (pascal_val_print): Update. * source.c: Include "arch-utils.h". (line_info): Update. * stack.c (frame_info, print_block_frame_labels): Update. * symfile.c (add_symbol_file_command, list_overlays_command): Update. * symmisc.c (dump_msymbols, dump_psymtab, dump_symtab_1, print_symbol, print_partial_symbols, maintenance_info_psymtabs, maintenance_check_symtabs): Update. * symtab.c (find_pc_sect_symtab): Update. * target.c (deprecated_debug_xfer_memory): Update. * tracepoint.c (scope_info): Update. * tui/tui-stack.c (tui_make_status_line): Update. * valprint.c (val_print_string): Update. Update callers of paddr_nz to use paddress instead (keeping user-visible output identical): * alpha-tdep.c (alpha_heuristic_proc_start): Update. * amd64-tdep.c (fixup_riprel, amd64_displaced_step_copy_insn, amd64_displaced_step_fixup): Update. * arch-utils.c (simple_displaced_step_copy_insn): Update. * auxv.c (fprint_target_auxv): Update. * breakpoint.c (insert_single_step_breakpoint): Update. * buildsym.c (finish_block): Update. * cli/cli-dump.c (restore_section_callback): Update. * fbsd-nat.c (fbsd_find_memory_regions): Update. * frame.c (frame_unwind_register_value): Update. * gcore.c (gcore_create_callback): Update. * hppa-tdep.c (hppa_frame_cache, hppa_skip_trampoline_code): Update. * i386-tdep.c (i386_displaced_step_fixup, i386_record_modrm, i386_record_lea_modrm_addr, i386_record_lea_modrm, i386_process_record): Update. * ia64-tdep.c (ia64_frame_this_id, ia64_sigtramp_frame_this_id, ia64_libunwind_frame_this_id, ia64_libunwind_sigtramp_frame_this_id, ia64_dummy_id, ia64_access_reg, ia64_access_rse_reg): Update. * infrun.c (displaced_step_prepare, displaced_step_fixup, handle_inferior_event, insert_step_resume_breakpoint_at_sal, insert_longjmp_resume_breakpoint): Update. * linux-nat.c (linux_nat_find_memory_regions): Update. * linux-record.c (record_linux_system_call): Update. * mips-tdep.c (heuristic_proc_start, mips_eabi_push_dummy_call, mips_n32n64_push_dummy_call, mips_o32_push_dummy_call, mips_o64_push_dummy_call): Update. * monitor.c (monitor_error, monitor_remove_breakpoint): Update. * record.c (record_arch_list_add_mem, record_wait, record_xfer_partial): Update. * remote-mips.c (mips_fetch_word, mips_check_lsi_error, mips_common_breakpoint): Update. * remote-sim.c (gdbsim_xfer_inferior_memory): Update. * rs6000-tdep.c (ppc_displaced_step_fixup): Update. * solib-som.c (som_current_sos): Update. * symfile.c (load_progress, generic_load): Update. * symfile-mem.c (add_vsyscall_page): Update. * valops.c (value_fetch_lazy): Update. * windows-tdep.c (windows_xfer_shared_library): Update. Update callers of paddr_nz to use paddress instead (changing user-visible output to make it more correct): * dwarf2loc.c (locexpr_describe_location): Update. * ia64-tdep.c (ia64_memory_insert_breakpoint, ia64_memory_remove_breakpoint): Update. * jv-valprint.c (java_value_print): Update. * m32c-tdep.c (m32c_m16c_address_to_pointer): Update. * monitor.c (monitor_read_memory): Update. Update callers of paddr to use paddress instead (changing user-visible output to make it more correct): * arm-tdep.c (arm_push_dummy_call): Update. * breakpoint.c (insert_bp_location, create_thread_event_breakpoint, create_breakpoint): Update. * darwin-nat-info.c (darwin_debug_regions): Update. * dcache.c (dcache_info): Update. * dsrec.c (load_srec, make_srec): Update. * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program, dwarf2_frame_cache): Update. * gcore.c (gcore_copy_callback): Update. * gnu-nat.c (gnu_xfer_memory): Update. * mips-linux-nat.c (mips_show_dr): Update. * monitor.c (monitor_write_memory, monitor_insert_breakpoint, monitor_remove_breakpoint): Update. * remote.c (compare_sections_command): Update. * remote-m32r-sdi.c (m32r_xfer_memory, m32r_insert_breakpoint, m32r_remove_breakpoint, m32r_insert_watchpoint, m32r_remove_watchpoint): Update. * sol-thread.c (info_cb): Update. * symfile.c (load_progress): Update. Update callers of paddress or paddr_nz to use hex_string instead (changes output of internal/error/debug messages only): * dwarf2read.c (dump_die_shallow): Update. * frame.c (fprint_field, fprint_frame, frame_pc_unwind, get_frame_func, create_new_frame): Update. * hppa-tdep.c (find_unwind_entry, unwind_command): Update. * ia64-tdep.c (get_kernel_table, ia64_find_proc_info_x, ia64_get_dyn_info_list): Update. * maint.c (maintenance_translate_address): Update. * mi/mi-cmd-var.c (mi_cmd_var_create): Update. * target.c (target_flash_erase): Update. Update callers of paddr/paddr_nz to use phex/phex_nz instead, using an appropriate address size. Remove use of strlen_paddr. * exec.c (exec_files_info): Update. * i386-nat.c (i386_show_dr): Update. * remote.c (remote_flash_erase): Update. * m32r-rom.c (m32r_load_section): Update. * monitor.c (monitor_vsprintf, monitor_store_register): Update. * remote.c (remote_check_symbols, remote_search_memory): Update. * remote-mips.c (mips_request, mips_common_breakpoint): Update. * scm-valprint.c (scm_ipruk, scm_scmval_print): Update. * sh64-tdep.c (sh64_show_media_regs, sh64_show_compact_regs): Update. * sh-tdep.c (sh_generic_show_regs, sh3_show_regs, sh2e_show_regs, sh2a_show_regs, sh2a_nofpu_show_regs, sh3e_show_regs, sh3_dsp_show_regs, sh4_show_regs, sh4_nofpu_show_regs, sh_dsp_show_regs): Update. * xcoffsolib.c (sharedlibrary_command): Update. * maint.c (maint_print_section_info): Add ADDR_SIZE parameter. Use hex_string_custom instead of paddr. (print_bfd_section_info): Pass address size. (print_objfile_section_info): Likewise. * annotate.h (annotate_source): Add GDBARCH parameter. (annotate_frame_begin): Likewise. * annotate.c (annotate_source): Add GDBARCH parameter. (annotate_frame_begin): Likewise. * source.c (identify_source_line): Update call to annotate_source. * stack.c (print_frame_info, print_frame): Update call to annotate_frame_begin. * breakpoint.c (describe_other_breakpoints): Add GDBARCH parameter. (create_breakpoint, create_ada_exception_breakpoint): Update call. * stack.c (print_block_frame_labels): Add GDBARCH parameter. (print_frame_label_vars): Update call. * symmisc.c (print_partial_symbols): Add GDBARCH parameter. (dump_psymtab): Update call to print_partial_symbols. (struct print_symbol_args): Add GDBARCH member. (dump_symtab_1): Set print_symbol_args architecture member. (print_symbol): Use it. * windows-tdep.h (windows_xfer_shared_library): Add GDBARCH parameter. * windows-tdep.c (windows_xfer_shared_library): Likewise. * i386-cygwin-tdep.c (struct cpms_data): Add GDBARCH member. (core_process_module_section): Pass architecture from cpms_data to windows_xfer_shared_library. (windows_core_xfer_shared_libraries): Initialize cmps_data architecture member. * windows-nat.c (windows_xfer_shared_libraries): Pass architecture to windows_xfer_shared_library. * defs.h (print_address): Add GDBARCH parameter. * printcmd.c (print_address): Add GDBARCH parameter. (print_scalar_formatted, do_examine): Update call. * findcmd.c (find_command): Update call. * tracepoint.c: Include "arch-utils.h". (trace_find_line_command): Update call. * tui/tui-disasm.c (tui_disassemble): Update call. * value.h (print_address_demangle): Add GDBARCH parameter. * printcmd.c (print_address_demangle): Add GDBARCH parameter. * c-valprint.c (print_function_pointer_address, c_val_print): Update call. * f-valprint.c (f_val_print): Update call. * gnu-v3-abi.c (gnuv3_print_method_ptr): Update call. * jv-valprint.c (java_val_print): Update call. * m2-valprint.c (print_function_pointer_address, m2_val_print): Update call. * p-valprint.c (pascal_val_print): Update call. * disasm.c (gdb_disassemble_info): Install architecture into di.application_data field. testsuite/ChangeLog: * gdb.threads/tls-shared.exp: Update to locexpr_describe_location change to prefix TLS offset in hex with 0x. doc/ChangeLog: * gdbint.texinfo (Item Output Functions): Update signature for ui_out_field_core_addr.
2009-07-02ChangeLog:Ulrich Weigand2-12/+5
* printcmd.c (next_gdbarch): New static variable. (set_next_address, do_examine, x_command): Set it. (decode_format): Use 'a' size to indicate width of an address. (do_examine): Add GDBARCH argument. Handle 'a' size. (x_command): Pass architecture to do_examine. Error if called without argument the first time. (do_one_display): Pass architecture to do_examine. (examine_i_type, examine_b_type, examine_h_type, examine_w_type, examine_g_type): Remove. (_initialize_printcmd): Do not initialize them. (do_examine): Use builin_type_int... instead of examine_..._type. testsuite/ChangeLog: * gdb.base/default.exp: Update test case for "x" changes.
2009-07-012009-07-01 Tristan Gingold <gingold@adacore.com>Tristan Gingold2-0/+5
* gdb.base/bigcore.exp: Make darwin untested.
2009-06-30gdb/testsuite/Jan Kratochvil2-9/+27
* gdb.base/completion.exp (directory completion): Create the directory. New variables uniquedir, escapeduniquedir, uniquesu, uniquesub, escapeuniquesub. (directory completion 2): Expect now ${escapeuniquesub}. (Glob remaining of directory test): Remove one excessive newline. Expect the real output.
2009-06-30gdb/Jan Kratochvil2-6/+11
* Makefile.in (TARGET_FLAGS_TO_PASS): Include also FORCE_PARALLEL. (check//%): Construct FORCE_PARALLEL for the sub-make. Extend the comment for it. gdb/testsuite/ Fix `make check//%' target after `make check' has been ran. * Makefile.in (TEST_TARGETS): Remove the %/.dir dependency. Add a mkdir call. (check-gdb.base%): Remove the gdb.base%/.dir dependency. (%/.dir): Remove.
2009-06-30gdb/testsuite/Jan Kratochvil2-1/+6
* lib/mi-support.exp (mi_check_thread_states): Permit any output before the expected result record.
2009-06-30gdb/testsuite/Jan Kratochvil2-3/+6
Remove racy FAILs relying just on the timeouts. * gdb.base/setshow.exp (set annotate 2, show annotate (2)) (annotation_level 2): Remove racy FAILs.
2009-06-30ChangeLog:Paul Pluzhnikov3-0/+92
2009-06-30 Paul Pluzhnikov <ppluzhnikov@google.com> gdb/10275 * dwarf2-frame.c (dwarf2_frame_state): Move cfa_offset, cfa_reg, cfa_how and cfa_exp into regs and adjust users. testsuite/ChangeLog: 2009-06-30 Paul Pluzhnikov <ppluzhnikov@google.com> gdb/10275 * gdb.dwarf2/dw2-restore.{S,exp}: New test.
2009-06-30 * dwarf2read.c (inherit_abstract_dies): Work around GCC PR 40573.Daniel Jacobowitz2-24/+8
testsuite/ * gdb.opt/inline-locals.exp: Remove XFAIL with duplicated arg1.