aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite
AgeCommit message (Collapse)AuthorFilesLines
2012-11-092012-11-09 Pedro Alves <palves@redhat.com>Pedro Alves3-0/+100
PR gdb/14306 * infrun.c: Include target-descriptions.h. (follow_exec): Fetch new target description. gdb/testsuite/ 2012-11-09 Pedro Alves <palves@redhat.com> PR gdb/14306 * gdb.multi/multi-arch-exec.c: New file. * gdb.multi/multi-arch-exec.exp: New file.
2012-11-092012-11-09 Yao Qi <yao@codesourcery.com>Yao Qi2-0/+25
* breakpoint.c: Declare set_tracepoint_count. (install_breakpoint): Call set_tracepoint_count if B is a tracepoint. (trace_command): Don't call set_tracepoint_count. Re-indent. (strace_command, ftrace_command): (create_tracepoint_from_upload): Likewise. gdb/testsuite: 2012-11-09 Yao Qi <yao@codesourcery.com> * gdb.mi/mi-break.exp (test_abreak_creation): New procedure. (top level): Call it
2012-11-09gdb/testsuite:Yao Qi2-2/+7
* gdb.mi/mi-watch.exp (test_rwatch_creation_and_listing): Fix typo.
2012-11-09gdb/Pedro Alves2-0/+80
2012-11-09 Pedro Alves <palves@redhat.com> * gdbarch.sh (target_gdbarch) <gdbarch.h>: Reimplement as macro. (get_target_gdbarch) <gdbarch.h>: New function. (startup_gdbarch) <gdbarch.h>: Declare. <gdbarch.c> (target_gdbarch): Delete. <gdbarch.c> (deprecated_target_gdbarch_select_hack): Set the current inferior's gdbarch. <gdbarch.c> (get_target_gdbarch): New function. * inferior.c: Include target-descriptions.h. (free_inferior): Free target description info. (add_inferior_with_spaces): Set the inferior's initial architecture. (clone_inferior_command): Copy the original inferior's target description if it was user specified. (initialize_inferiors): Add comment. * inferior.h (struct target_desc_info): Forward declare. (struct inferior) <gdbarch>: New field. * linux-nat.c: Include target-descriptions.h. (linux_child_follow_fork): Copy the parent's architecture and target description to the child. * target-descriptions.c: Include inferior.h. (struct target_desc_info): New structure, holding the equivalents of ... (target_desc_fetched, current_target_desc) (target_description_filename): ... these removed globals. (get_tdesc_info, target_desc_info_from_user_p) (copy_inferior_target_desc_info, target_desc_info_free): New. (target_desc_fetched, current_target_desc) (target_description_filename): Reimplemented as convenience macros. (tdesc_filename_cmd_string): New global. (set_tdesc_filename_cmd): Copy the string manipulated by the "set tdescs filename ..." commands to the per-inferior equivalent. (show_tdesc_filename_cmd): Get the value to show from the per-inferior description filename. (_initilize_target_descriptions): Change the "set/show tdesc filename" commands' variable. * target-descriptions.h (struct target_desc, struct target_desc_info) (struct inferior): Forward declare. (target_find_description, target_clear_description) (target_current_description): Adjust comments. (copy_inferior_target_desc_info, target_desc_info_free) (target_desc_info_from_user_p). Declare. gdb/testsuite/ 2012-11-09 Pedro Alves <palves@redhat.com> * gdb.multi/multi-arch.exp: New.
2012-11-08gdbTom Tromey4-0/+240
* linux-tdep.c (linux_make_siginfo_note): New function. (linux_make_corefile_notes): Use it. * corelow.c (get_core_siginfo): New function. (core_xfer_partial) <TARGET_OBJECT_SIGNAL_INFO>: New case. gdb/testsuite * gdb.base/siginfo-obj.exp: Create core file. Test siginfo from core files, if possible. * gdb.base/siginfo-thread.c: New file * gdb.base/siginfo-thread.exp: New file bfd * elf.c (elfcore_grok_note) <NT_SIGINFO>: New case; make pseudosection.
2012-11-08 PR gdb/14704:Tom Tromey2-0/+50
* gdb_bfd.c (gdb_bfd_ref): Set BFD_DECOMPRESS. (zlib_decompress_section): Remove. (gdb_bfd_map_section): Only check for compressed section in mmap case. Use bfd_get_full_section_contents. * osabi.c (check_note): Add 'sectsize' argument. Read section data. (generic_elf_osabi_sniff_abi_tag_sections): Don't read section data. Update for check_note change. * xcoffread.c (xcoff_initial_scan): Use bfd_get_full_section_contents. * py-auto-load.c (auto_load_section_scripts): Use bfd_get_full_section_contents. * contrib/cc-with-tweaks.sh: Add -Z option. testsuite * gdb.base/comprdebug.exp: New file.
2012-11-06gdb/Pedro Alves3-0/+77
2012-11-06 Pedro Alves <palves@redhat.com> PR gdb/14810 * breakpoint.c (bpstat_stop_status): Skip disabled locations. gdb/testsuite/ 2012-11-06 Pedro Alves <palves@redhat.com> PR gdb/14810 * gdb.base/disabled-location.c: New file. * gdb.base/disabled-location.exp: New file.
2012-11-06 * gdb.threads/gcore-thread.exp: Use gdb_gcore_cmd.Tom Tromey12-149/+63
* gdb.python/py-strfns.exp (test_strfns_core_file): Use gdb_gcore_cmd. * gdb.cell/gcore.exp: Use gdb_gcore_cmd. * gdb.base/gcore.exp: Use gdb_gcore_cmd. * gdb.base/gcore-relro.exp: Use gdb_gcore_cmd. * gdb.base/gcore-buffer-overflow.exp: Use gdb_gcore_cmd. * gdb.base/auxv.exp: Use gdb_gcore_cmd. * gdb.arch/vsx-regs.exp: Use gdb_gcore_cmd. * gdb.arch/system-gcore.exp: Use gdb_gcore_cmd. * gdb.arch/pa-nullify.exp (test_core_bt): Use gdb_gcore_cmd. * lib/gdb.exp (gdb_gcore_cmd): New proc.
2012-11-05gdb/Pedro Alves2-0/+73
2012-11-05 Pedro Alves <palves@redhat.com> * inferior.c (exit_inferior_1): Clear 'vfork_parent' in the vfork child. Clear 'pending_detach'. * infrun.c (handle_vfork_child_exec_or_exit): Clear 'pending_detach' in the vfork parent. gdb/testsuite/ 2012-11-05 Pedro Alves <palves@redhat.com> * gdb.base/foll-vfork.exp (vfork_relations_in_info_inferiors): New procedure. (do_vfork_and_follow_child_tests_exec) (do_vfork_and_follow_child_tests_exit): Call it.
2012-11-052012-11-05 Pedro Alves <palves@redhat.com>Pedro Alves2-0/+7
* gdb.base/foll-vfork.c (main): Call perror and _exit if execlp() fails.
2012-11-03gdb:Yao Qi2-2/+7
Fix PR gdb/14617. * breakpoint.c (trace_pass_set_count): Call observer_notify_breakpoint_modified instead of observer_notify_tracepoint_modified. * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise. gdb/doc: * observer.texi (GDB Observers): Remove observer 'tracepoint_modified', 'tracepoint_created' and 'tracepoint_deleted'. gdb/testsuite: Fix PR gdb/14617. * gdb.mi/mi-breakpoint-changed.exp (test_insert_delete_modify): Remove setup_kfail, and update test.
2012-11-02 * breakpoint.c (catch_syscall_completer): Pass 'word' as secondTom Tromey2-0/+10
argument to complete_on_enum. testsuite * gdb.base/catch-syscall.exp (do_syscall_tests): Add completion test.
2012-11-02gdb/Pedro Alves2-5/+10
2012-11-02 Pedro Alves <palves@redhat.com> PR gdb/14766 * infrun.c (handle_inferior_event) <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Switch to null_ptid before handling a vfork child exec or exit. Switch to the event ptid afterwards. gdb/testsuite/ 2012-11-02 Pedro Alves <palves@redhat.com> PR gdb/14766 * gdb.base/foll-vfork.exp (vfork_child_follow_to_exit): Remove setup_kfail. (tcatch_vfork_then_child_follow_exit): No longer expect "Couldn't get registers".
2012-11-022012-11-02 Pedro Alves <palves@redhat.com>Pedro Alves3-15/+195
* gdb.base/foll-vfork-exit.c: New file. * gdb.base/foll-vfork.exp (top level): New file-describing comment. (vfork_child_follow_to_exit): New procedure. (tcatch_vfork_then_child_follow): Rename as ... (tcatch_vfork_then_child_follow_exec): ... this. (tcatch_vfork_then_child_follow_exit): New procedure. (do_vfork_and_follow_parent_tests): New procedure, factored out from do_vfork_and_exec_tests. (do_vfork_and_follow_child_tests_exec): Ditto. (do_vfork_and_exec_tests): Delete. (do_vfork_and_follow_child_tests_exit): New procedure. (top level): Run tests with both the program that has the vfork child execing, and the program has the vfork child exiting.
2012-11-02Move entries to correct ChangeLog file...Pedro Alves1-0/+66
gdb/ChangeLog -> gdb/testsuite/ChangeLog
2012-11-022012-11-02 Pedro Alves <palves@redhat.com>Pedro Alves1-49/+38
* gdb.base/foll-vfork.exp (setup_gdb): New procedure. (check_vfork_catchpoints, vfork_parent_follow_through_step) (vfork_parent_follow_to_bp): Call it. (kill_child): Delete. (vfork_and_exec_child_follow_to_main_bp) (vfork_and_exec_child_follow_through_step): Call setup_gdb. No longer call kill_child. (tcatch_vfork_then_parent_follow): Call setup_gdb. (do_vfork_and_exec_tests): Don't runto_main before calling each test procedure. (top level): Don't clean restart and set verbose before running each test procedure.
2012-11-022012-11-02 Pedro Alves <palves@redhat.com>Pedro Alves1-37/+29
* gdb.base/foll-vfork.exp (vfork_parent_follow_through_step) (vfork_parent_follow_to_bp) (vfork_and_exec_child_follow_to_main_bp) (vfork_and_exec_child_follow_through_step) (tcatch_vfork_then_parent_follow) (tcatch_vfork_then_parent_follow, tcatch_vfork_then_child_follow): Use with_test_prefix.
2012-11-022012-11-02 Pedro Alves <palves@redhat.com>Pedro Alves2-0/+34
* gdb.base/foll-vfork.c: Add copyright header. * gdb.base/vforked-prog.c: Add copyright header.
2012-11-022012-11-02 Pedro Alves <palves@redhat.com>Pedro Alves1-14/+33
* gdb.base/foll-vfork.exp (vfork_and_exec_child_follow_through_step): Don't skip on non-HP/UX targets. Expect the next to only step one line on non-HP/UX targets, rather than stopping only after the exec.
2012-11-022012-11-02 Pedro Alves <palves@redhat.com>Pedro Alves1-8/+18
Don't hard code line numbers. * gdb.base/foll-vfork.exp (vfork_parent_follow_through_step): Expect text from the sources instead of a line number. (vfork_parent_follow_to_bp) (vfork_and_exec_child_follow_to_main_bp) (vfork_and_exec_child_follow_through_step) (tcatch_vfork_then_parent_follow, tcatch_vfork_then_child_follow): Use gdb_get_line_number.
2012-11-022012-11-02 Pedro Alves <palves@redhat.com>Pedro Alves1-167/+127
Modernize. * gdb.base/foll-vfork.exp: Use standard_testfile and build_executable. Pass descriptive string to untested. (vfork_parent_follow_through_step, vfork_parent_follow_to_bp) (vfork_and_exec_child_follow_to_main_bp) (vfork_and_exec_child_follow_through_step) (tcatch_vfork_then_parent_follow, tcatch_vfork_then_child_follow) (do_vfork_and_exec_tests): Use gdb_test/gdb_test_multiple instead of send_gdb/gdb_expect. (kill_child): New procedure. (vfork_and_exec_child_follow_to_main_bp) (vfork_and_exec_child_follow_through_step): Use it.
2012-11-02gdb:Yao Qi3-0/+20
2012-11-02 Yao Qi <yao@codesourcery.com> * std-operator.def: Remove OP_LABELED. * eval.c: Remove the declaration of 'get_label'. (get_label): Remove. (evaluate_struct_tuple): Remove code handling OP_LABELED. Update comment. Remove local variable 'variantno' and related code. Replace 'substruct_type' with 'struct_type'. Replace 'subfieldno' with 'fieldno'. * expprint.c (print_subexp_standard): Likewise. (dump_subexp_body_standard): Likewise. * parse.c (operator_length_standard): Likewise. gdb/testsuite: 2012-11-02 Yao Qi <yao@codesourcery.com> * gdb.base/setvar.exp: Test setting nested struct. * gdb.base/setvar.c (v_struct3): New.
2012-11-01 * gdb.arch/amd64-pseudo.c (main): Mark registers that the testsuiteDoug Evans2-0/+22
changes as clobbered (e.g., amd64-dword.exp) so gcc doesn't try to use them.
2012-10-31http://sourceware.org/ml/gdb-patches/2012-10/msg00525.htmlAndrew Burgess3-0/+32
gdb/ChangeLog PR cli/14772 * c-typeprint.c (c_print_type): Don't print a space for vector types, this is handled within the suffix. (c_type_print_varspec_suffix): Add a space to vector suffix gdb/testsuite/ChangeLog PR cli/14772 * gdb.base/gnu_vector.c (union_with_vector_1) (struct_with_vector_1): Add new struct and union for testing ptype. * gdb.base/gnu_vector.exp: Add testing of ptype on vectors, and structs / unions containing vectors.
2012-10-25gdb/testsuite:Yao Qi4-13/+12
* gdb.trace/ftrace.exp (test_fast_tracepoints): Use 'setup_kfail' instead of 'setup_kfail_for_target'. * gdb.base/varargs.exp: Likewise. * lib/gdb.exp (setup_kfail_for_target): Remove.
2012-10-25gdb.base/ldbl_e308.exp: Do not allow "inf" in value output.Joel Brobecker1-1/+1
That was an attempt at handling the targets where sizeof(long double) is less than 8, but the way it was implement allows the bug that this testcase verifies to come back without being noticed. gdb/testsuite/ChangeLog: * gdb.base/ldbl_e308.exp: Remove "inf" from possible expected output for "print inp" test.
2012-10-25* gdb.base/varargs.exp: PR gdb/12790 is now fixed.Mark Kettenis2-3/+4
2012-10-25* gdb.base/callfuncs.exp: PR gdb/12783 is now fixed.Mark Kettenis2-2/+4
2012-10-24[Ada] Allow assignment to wide string.Joel Brobecker5-0/+144
Given the following variable declaration... Www : Wide_String := "12345"; ... this patch allows the following assignment to work: (gdb) set variable www := "qwert" Without this patch, the debugger rejects the assignment because the size of the array elements are different: (gdb) set www := "asdfg" Incompatible types in assignment (on the lhs, we have an array of 2-bytes elements, and on the rhs, we have a standard 1-byte string). gdb/ChangeLog: * ada-lang.c (ada_same_array_size_p): New function. (ada_promote_array_of_integrals): New function. (coerce_for_assign): Add handling of arrays where the elements are integrals of a smaller size than the size of the target array element type. gdb/testsuite/ChangeLog: * gdb.ada/set_wstr: New testcase.
2012-10-24off-by-one max exponent computation in convert_doublest_to_floatformatJoel Brobecker3-0/+61
Assuming the following variable definition: long double inp = 2.0; On platforms where "long double" is a double precision IEEE flaoting point, GDB currently behaves as follow: (gdb) set variable inp = 1.6e+308l (gdb) p inp $2 = inf <<<<---- !!!! Instead, the value of "inp" should be printed as: (gdb) p inp $1 = 1.6e+308 The problem is due to a small error in the comparison of the exponent versus the maximum value this exponent can take, causing us to think that the value was too big to fit. But it isn't. gdb/ChangeLog: * doublest.c (convert_doublest_to_floatformat): Fix comparison against maximum exponent value. gdb/testsuite/ChangeLog: * gdb.base/ldbl_e308.c, gdb.base/ldbl_e308.exp: New files.
2012-10-24[Ada] Pointers to unconstrained arrays inside variant record.Joel Brobecker5-0/+179
gdb/ChangeLog: * ada-lang.c (ada_template_to_fixed_record_type_1): Do not strip typedef layer when computing the fixed type's field type, only when computing its size. gdb/testsuite/ChangeLog: * gdb.ada/unc_arr_ptr_in_var_rec: New testcase.
2012-10-24* gdb.base/callfuncs.exp: PR gdb/12783 is now fixed.Mark Kettenis2-6/+4
2012-10-24gdb/testsuite/Jan Kratochvil2-2/+11
* gdb.base/callfuncs.exp (do_function_calls): Fix setup_kfail_for_target for -m32 mode.
2012-10-23* gdb.base/callfuncs.exp: PR gdb/12796, gdb/12798 and gdb/12800Mark Kettenis2-7/+5
are now fixed.
2012-10-23gdb/testsuite:Yao Qi2-1/+5
* gdb.base/info-os.exp: Resume the inferior until it exits.
2012-10-19Correct my ChangeLog entryxuepeng guo1-3/+3
2012-10-19 * gdb.base/ctxobj.exp: Skip if skip_shlib_tests returns true.xuepeng guo4-0/+18
* gdb.base/print-file-var.exp: Likewise. * gdb.base/type-opaque.exp: Likewise.
2012-10-17gdb:Yao Qi2-0/+85
* breakpoint.c (invalidate_bp_value_on_memory_change): Add one more parameter 'inferior'. * corefile.c (write_memory_with_notification): Caller update. * mi/mi-cmd-var.c: Include "mi-main.h". (mi_cmd_var_assign): Set mi_suppress_notification.data_write_memory to 1 and restore it later. * mi/mi-cmds.c (mi_cmd mi_cmds): Update for "data-write-memory" and "data-write-memory-bytes. * mi/mi-interp.c: Include objfiles.h. (mi_interpreter_init): Call observer_attach_memory_changed. (mi_memory_changed): New. * mi/mi-main.h (struct mi_suppress_notification) <memory>: New field. * NEWS: Mention new MI notification "memory-changed". gdb/doc: * observer.texi (GDB Observers): Update observer 'memory_changed'. * gdb.texinfo (GDB/MI Async Records): Document for "memory-changed" notification. gdb/testsuite: * gdb.mi/mi-memory-changed.exp: New.
2012-10-16gdb/testsuite/Yao Qi3-2/+15
* gdb.reverse/solib-precsave.exp: Skip if skip_shlib_test returns true. Call gdb_load_shlibs. * gdb.reverse/solib-reverse.exp: Likewise.
2012-10-15 * lib/cp-support.exp (cp_test_ptype_class): Add supportKeith Seitz3-0/+51
for class typedefs. * gdb.cp/derivation.exp: Add tests for g_instance.
2012-10-15gdb/Jan Kratochvil4-0/+769
Fix entry values resolving in inlined frames. * dwarf2loc.c (dwarf_expr_reg_to_entry_parameter): Move func_addr, gdbarch and caller_frame initialization later. Skip INLINE_FRAME entries of FRAME. gdb/testsuite/ Fix entry values resolving in inlined frames. * gdb.arch/amd64-entry-value-inline.S: New file. * gdb.arch/amd64-entry-value-inline.c: New file. * gdb.arch/amd64-entry-value-inline.exp: New file.
2012-10-15gdb/testsuite/Jan Kratochvil3-4/+12
Fix recent gdb_breakpoint regression. * gdb.java/jmisc.exp: gdb_breakpoint for $function - remove curly braces from the parameter. * gdb.java/jprint.exp: Likewise.
2012-10-15 * lib/gdb.exp (runto): Fix call to gdb_breakpoint.Doug Evans2-1/+8
2012-10-15Remove trailing '#' in gdb.dwarf2/dw2-icc-opaque.SJoel Brobecker2-1/+5
gdb/testsuite/ChangeLog: * gdb.dwarf2/dw2-icc-opaque.S: Remove '#'.
2012-10-15 PR python/14635:Tom Tromey2-0/+7
* python/py-symtab.c (del_objfile_sal): Set 'symtab' field to Py_None. testsuite * gdb.python/py-symtab.exp: Test sal and symtab destructors.
2012-10-15 PR python/14634:Tom Tromey2-0/+5
* python/py-symbol.c (sympy_dealloc): Check for NULL symbol. testsuite * gdb.python/py-symbol.exp: Test symbol destructor.
2012-10-14gdb/testsuite/Yao Qi22-3395/+29
* gdb.mi/mi2-cli.exp: Move to mi-cli.exp. * gdb.mi/mi-cli.exp: New. * gdb.mi/mi2-basics.exp: Remove. * gdb.mi/mi2-break.exp: Remove. * gdb.mi/mi2-console.exp: Remove. * gdb.mi/mi2-disassemble.exp: Remove. * gdb.mi/mi2-eval.exp: Remove. * gdb.mi/mi2-file.exp: Remove. * gdb.mi/mi2-hack-cli.exp: Remove. * gdb.mi/mi2-pthreads.exp: Remove. * gdb.mi/mi2-read-memory.exp: Remove. * gdb.mi/mi2-regs.exp: Remove. * gdb.mi/mi2-return.exp: Remove. * gdb.mi/mi2-simplerun.exp: Remove. * gdb.mi/mi2-stack.exp: Remove. * gdb.mi/mi2-stepi.exp: Remove. * gdb.mi/mi2-syn-frame.exp: Remove. * gdb.mi/mi2-until.exp: Remove. * gdb.mi/mi2-watch.exp: Remove. * gdb.mi/mi2-var-block.exp: Remove. * gdb.mi/mi2-var-cmd.exp: Remove. * gdb.mi/mi2-var-display.exp: Remove.
2012-10-12gdb/testsuite/Yao Qi2-3/+8
* gdb.mi/mi-breakpoint-changed.exp (test_pending_resolved): Remove trail '.*' on matching patterns.
2012-10-11Use is_x86_like_target to check x86 targetsH.J. Lu9-8/+19
* gdb.arch/i386-bp_permanent.exp: Skip if not is_x86_like_target. * gdb.arch/i386-cfi-notcurrent.exp: Likewise. * gdb.arch/i386-disp-step.exp: Likewise. * gdb.arch/i386-gnu-cfi.exp: Likewise. * gdb.arch/i386-prologue.exp: Likewise. * gdb.arch/i386-size-overlap.exp: Likewise. * gdb.arch/i386-size.exp: Likewise. * gdb.arch/i386-unwind.exp: Likewise.
2012-10-11Check byte/word registers on x86_64H.J. Lu3-2/+7
* gdb.arch/i386-byte.exp: Remove is_ilp32_target check. * gdb.arch/i386-word.exp: Likewise.