aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-09-23daily updateAlan Modra1-1/+1
2013-09-22daily updateAlan Modra1-1/+1
2013-09-212013-09-21 Jan-Benedict Glaw <jbglaw@lug-owl.de>Jan-Benedict Glaw3-0/+57
* configure.ac: Update from GCC. * configure: Regenerate.
2013-09-21daily updateAlan Modra1-1/+1
2013-09-20 * lib/dwarf.exp (build_executable_from_fission_assembler): New proc.Doug Evans8-105/+198
* gdb.dwarf2/fission-base.S: Update. Split out .dwo into separate file. * gdb.dwarf2/fission-loclists.S: Ditto. * gdb.dwarf2/fission-reread.S: Ditto. * gdb.dwarf2/fission-base.exp: Skip of remote host. Compile with build_executable_from_fission_assembler. * gdb.dwarf2/fission-loclists.exp: Ditto. * gdb.dwarf2/fission-reread.exp: Ditto.
2013-09-20 * lib/future.exp (gdb_find_objcopy, gdb_find_readelf): New procs.Doug Evans13-16/+54
* lib/gdb.exp (build_id_debug_filename_get): Update to use them. (gdb_gnu_strip_debug): Ditto. * lib/prelink-support.exp (section_get, prelink_no): Ditto. * gdb.arch/altivec-abi.exp: Ditto. * gdb.base/attach-pie-misread.exp: Ditto. * gdb.base/comprdebug.exp: Ditto. * gdb.base/dup-sect.exp: Ditto. * gdb.base/gnu-debugdata.exp: Ditto. * gdb.base/step-symless.exp: Ditto. * gdb.dwarf2/dw2-inline-param.exp: Ditto. * gdb.dwarf2/dw2-skip-prologue.exp: Ditto. * gdb.dwarf2/gdb-index.exp: Ditto.
2013-09-202013-09-20 Chung-Lin Tang <cltang@codesourcery.com>Chung-Lin Tang3-2/+7
* Makefile.am (enios2elf.c): Change tdir_nios2 to tdir_nios2elf. * Makefile.in: Regenerate.
2013-09-20 * libtool.m4 (_LT_ENABLE_LOCK <ld -m flags>): Remove non-canonicalAlan Modra14-33/+104
ppc host match. Support little-endian powerpc linux hosts. Regenerate binutils configure files.
2013-09-20daily updateAlan Modra1-1/+1
2013-09-19Fix regressions caused by thread-specific breakpoint deletion.Pedro Alves2-1/+6
The recent change to make GDB auto-delete thread-specific breakpoints when the corresponding thread is deleted (https://sourceware.org/ml/gdb-patches/2013-09/msg00038.html) caused gdb.base/nextoverexit.exp to regress. Breakpoint 1, main () at .../gdb/testsuite/gdb.base/nextoverexit.c:21 21 exit (0); (gdb) next [Inferior 1 (process 25208) exited normally] Thread-specific breakpoint -5 deleted - thread 1 is gone. Thread-specific breakpoint -6 deleted - thread 1 is gone. Thread-specific breakpoint -7 deleted - thread 1 is gone. Thread-specific breakpoint 0 deleted - thread 1 is gone. (gdb) FAIL: gdb.base/nextoverexit.exp: next over exit (the program exited) We shouldn't be seeing this for internal or momentary breakpoints. In fact, we shouldn't even be trying to delete them, as whatever created them will take care or it, and therefore it's dangerous to delete them behind the creator's back. I thought it'd still be good to tag thread-specific internal/momentary breakpoints such that we'll no longer try to keep them insert in the target, as they'll cause stops and thread hops in other threads, so I tried disabling them instead. That caused a problem when following a child fork, and detaching from the parent, as we try to reset the step-resume etc. breakpoints to the new child's thread (breakpoint_re_set_thread), after the parent thread is already gone (and the breakpoints are marked disabled). I fixed that by re-enabling internal/momentary breakpoints there, but, that didn't feel super safe either (maybe we'd need a new flag in struct breakpoint instead, to tag the thread-specific breakpoint as "not to be inserted"). It felt like I was heading down a design rat hole, and, other things will usually delete internal/momentary breakpoints soon enough, so I left that little optimization for some other day. So, internal/momentary breakpoints are no longer deleted/disabled at all, and we end up with a one-liner fix. Tested on x86_64 Fedora 17. gdb/ 2013-09-19 Pedro Alves <palves@redhat.com> * breakpoint.c (remove_threaded_breakpoints): Skip non-user breakpoints.
2013-09-19gnu-nat.c: Don't install a deprecated_xfer_memory method.Thomas Schwinge2-20/+59
This removes another instance of a deprecated_xfer_memory user. gdb/ 2013-09-19 Pedro Alves <palves@redhat.com> Thomas Schwinge <thomas@codesourcery.com> Yue Lu <hacklu.newborn@gmail.com> * gnu-nat.c (gnu_read_inferior, gnu_write_inferior): Make static. Take a gdb_byte pointer instead of a char pointer. * gnu-nat.c (gnu_xfer_memory): Adjust interface as gnu_xfer_partial helper. (gnu_xfer_partial): New function. (gnu_target): Don't install a deprecated_xfer_memory hook. Install a to_xfer_partial hook.
2013-09-19Mostly code cleanup: Constification.Jan Kratochvil4-19/+33
gdb/ 2013-09-19 Jan Kratochvil <jan.kratochvil@redhat.com> Constification. * main.c (captured_main): Replace catch_command_errors by catch_command_errors_const. Twice. * symfile.c (symbol_file_add_main_1): Make args parameter const. (symbol_file_add): Make name parameter const. (symbol_file_add_main, symbol_file_add_main_1): Make args parameter const. (symfile_bfd_open): Make name parameter const, rename it to cname. Add variable name. Change their usage accordingly. * symfile.h (symbol_file_add, symfile_bfd_open): Make first parameter const. (symbol_file_add_main): Make args parameter const.
2013-09-19daily updateAlan Modra1-1/+1
2013-09-182013-09-18 Raunaq Bathija <raunaq12@in.ibm.com>Ulrich Weigand2-2/+9
Ulrich Weigand <uweigand@de.ibm.com> * xcoffread.c (struct coff_symbol): Use CORE_ADDR as type of c_value member. (read_xcoff_symtab): Use CORE_ADDR as type of fcn_start_addr.
2013-09-18Also mention Yue Lu in previous commit's entry.Pedro Alves1-0/+1
2013-09-18 Pedro Alves <palves@redhat.com> Yue Lu <hacklu.newborn@gmail.com> * gnu-nat.c (inf_validate_procs, gnu_wait, gnu_resume) (gnu_create_inferior) (gnu_attach, gnu_thread_alive, gnu_pid_to_str, cur_thread) (set_sig_thread_cmd): Use the lwpid field of ptids to store/extract thread ids instead of the tid field. * i386gnu-nat.c (gnu_fetch_registers): Adjust.
2013-09-18Subject: [PATCH] [Hurd/gnu-nat.c] Use ptid_t.lwpid to store thread idsPedro Alves3-14/+23
instead of ptid_t.tid. In preparation for reusing gnu-nat.c in gdbserver, switch to storing thread ids in the lwpid field of ptid_t rather than in the tid field. The Hurd's thread model is 1:1, so it doesn't feel wrong anyway. gdb/ 2013-09-18 Pedro Alves <palves@redhat.com> * gnu-nat.c (inf_validate_procs, gnu_wait, gnu_resume) (gnu_create_inferior) (gnu_attach, gnu_thread_alive, gnu_pid_to_str, cur_thread) (set_sig_thread_cmd): Use the lwpid field of ptids to store/extract thread ids instead of the tid field. * i386gnu-nat.c (gnu_fetch_registers): Adjust.
2013-09-18Consistent display of "<optimized out>" for register values.Andrew Burgess4-19/+39
https://sourceware.org/ml/gdb-patches/2013-08/msg00170.html gdb/ChangeLog * infcmd.c (default_print_one_register_info): Add detection of optimized out values. (default_print_registers_info): Switch to using get_frame_register_value. gdb/testsuite/ChangeLog * gdb.dwarf2/dw2-reg-undefined.exp: Change pattern for info register to "<optimized out>", and also print the registers.
2013-09-182013-09-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>Kyrylo Tkachov2-4/+9
* ld-aarch64/eh-frame.d: Update expected output to allow for 64-bit addresses.
2013-09-18gdbserver --wrapper also doesn't work on Cygwin.Pedro Alves2-2/+9
Skip the test on Cygwin too. 2013-09-18 Pedro Alves <palves@redhat.com> PR server/15967 * gdb.server/wrapper.exp: Also return unsupported for Cygwin, and change text.
2013-09-18When reverse-stepping, only insert a resume breakpoint at ecs->stop_func_startMarkus Metzger2-1/+6
if the function start is known. Otherwise, keep single-stepping.
2013-09-18[Hurd/gnu-nat] Fix old "signal-thread" command regression.Pedro Alves2-3/+9
By inspection, I noticed that when I made the gnu-nat use ptid(pid,0,tid) to represent a thread, instead of using ptid(tid,0,0), in <https://sourceware.org/ml/gdb-patches/2008-08/msg00175.html>, I introduced a bug. The change was: else { - int tid = PIDGET (thread_id_to_pid (atoi (args))); + int tid = ptid_get_tid (thread_id_to_pid (atoi (args))); if (tid < 0) error (_("Thread ID %s not known. Use the \"info threads\" command to\n" "see the IDs of currently known threads."), args); and thread_id_to_pid does: ptid_t thread_id_to_pid (int num) { struct thread_info *thread = find_thread_id (num); if (thread) return thread->ptid; else return pid_to_ptid (-1); } (pid_to_ptid (-1) is the same as minus_one_ptid.) So before, we were really looking at the pid, where thread_id_to_pid stores the -1. The right fix is to compare the whole ptid to minus_one_ptid, of course. Completely untested, but I think it's obvious enough, so I went ahead and put it in. gdb/ 2013-09-18 Pedro Alves <palves@redhat.com> * gnu-nat.c (set_sig_thread_cmd): Compare the thread's ptid to minus_one_ptid instead of looking at the ptid's tid field and comparing that to -1.
2013-09-18Fix whitespace error in previous commit.Andrew Burgess2-1/+5
https://sourceware.org/ml/gdb-cvs/2013-09/msg00108.html https://sourceware.org/ml/gdb-patches/2013-09/msg00225.html gdb/ChangeLog * main.h (get_gdb_program_name): Remove extra whitespace.
2013-09-18Add new function to access gdb_program_name.Andrew Burgess3-0/+18
https://sourceware.org/ml/gdb-patches/2013-09/msg00225.html gdb/ChangeLog * main.h (get_gdb_program_name): Add declaration. * main.c (get_gdb_program_name): Add definition.
2013-09-18bfd/Tristan Gingold3-11/+16
2013-09-18 Tristan Gingold <gingold@adacore.com> * configure.in: Bump version to 2.24.51 * configure: Regenerate.
2013-09-18binutils/Tristan Gingold7-0/+19
2013-09-18 Tristan Gingold <gingold@adacore.com> * NEWS: Add marker for 2.24. gas/ 2013-09-18 Tristan Gingold <gingold@adacore.com> * NEWS: Add marker for 2.24. ld/ 2013-09-18 Tristan Gingold <gingold@adacore.com> * NEWS: Add marker for 2.24.
2013-09-182013-09-18 Tristan Gingold <gingold@adacore.com>Tristan Gingold3-10/+17
* Makefile.am (LEXLIB): Define. Replase references to @LEXLIB@ by $(LEXLIB). * Makefile.in: Regenerate.
2013-09-18 * config/tc-msp430.c (OPTION_MOVE_DATA): Define.Nick Clifton3-1/+59
(move_data): New variable. (md_parse_option): Parse -md. (msp430_section): New function. Catch references to the .bss or .data sections and generate a special symbol for use by the libcrt library. (md_pseudo_table): Intercept .section directives. (md_longopt): Add -md (md_show_usage): Likewise. (msp430_operands): Generate a warning message if a NOP is inserted into the instruction stream. * doc/c-msp430.texi (node MSP430 Options): Document -md option.
2013-09-18gdb/gdbserver/Yao Qi5-0/+98
2013-09-18 Yao Qi <yao@codesourcery.com> PR server/15959 * server.c (start_inferior): Clear 'resume_info'. gdb/testsuite/ 2013-09-18 Yao Qi <yao@codesourcery.com> * gdb.server/wrapper.c: New. * gdb.server/wrapper.exp: New.
2013-09-18gdb/gdbserver/Yao Qi1-0/+2
Fix ChangeLog format issue.
2013-09-18daily updateAlan Modra1-1/+1
2013-09-17 * dwarf2read.c: Move definitions of complaint functions to afterDoug Evans2-68/+72
forward declarations of local functions.
2013-09-172013-09-17 Doug Gilmore <Doug.Gilmore@imgtec.com>Steve Ellcey2-0/+7
* readelf.c (get_machine_flags): Handle EF_MIPS_FP64.
2013-09-172013-09-17 Doug Gilmore <Doug.Gilmore@imgtec.com>Steve Ellcey2-3/+6
* config/tc-mips.c (mips_elf_final_processing): Set EF_MIPS_FP64 for -mgp32 -mfp64, removing old FIXME.
2013-09-172013-09-17 Doug Gilmore <Doug.Gilmore@imgtec.com>Steve Ellcey2-0/+8
* elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): Handle EF_MIPS_FP64.
2013-09-172013-09-17 Doug Gilmore <Doug.Gilmore@imgtec.com>Steve Ellcey2-0/+7
* mips.h (EF_MIPS_FP64): New e_flags bit.
2013-09-17PR gdb/11568 - delete thread-specific breakpoints on thread exitPedro Alves5-0/+208
PR gdb/11568 is about thread-specific breakpoints being left behind when the corresponding thread exits. Currently: (gdb) b start thread 2 Breakpoint 3 at 0x400614: file thread-specific-bp.c, line 23. (gdb) b end Breakpoint 4 at 0x40061f: file thread-specific-bp.c, line 29. (gdb) c Continuing. [Thread 0x7ffff7fcb700 (LWP 14925) exited] [Switching to Thread 0x7ffff7fcc740 (LWP 14921)] Breakpoint 4, end () at thread-specific-bp.c:29 29 } (gdb) info threads Id Target Id Frame * 1 Thread 0x7ffff7fcc740 (LWP 14921) "thread-specific" end () at thread-specific-bp.c:29 (gdb) info breakpoints Num Type Disp Enb Address What 2 breakpoint keep y 0x0000000000400614 in start at thread-specific-bp.c:23 breakpoint already hit 1 time 3 breakpoint keep y 0x0000000000400614 in start at thread-specific-bp.c:23 thread 2 stop only in thread 2 4 breakpoint keep y 0x000000000040061f in end at thread-specific-bp.c:29 breakpoint already hit 1 time Note that the thread-specific breakpoint 3 stayed around, even though thread 2 is gone. There's no way that breakpoint can trigger again (*), so the PR argues that the breakpoint should just be removed, like local watchpoints. I'm ambivalent on this -- it could be reasonable to disable the breakpoint (kind of like breakpoint in shared library code when the DSO is unloaded), so the user could still use it as visual template for creating other breakpoints (copy/paste command lists, etc.), or we could have a way to change to which thread a breakpoint applies. But, several people pushed this direction, and I don't plan on arguing... (*) - actually, there is ... thread numbers are reset on "run", so the user could do "break foo thread 2", "run", and expect the breakpoint to hit again on the second thread. But given gdb's thread numbering can't really be stable, that'd only work sufficiently well for thread 1, so we'd better call it unsupported. So with the patch, whenever a thread is deleted from GDB's list, GDB goes through the thread-specific breakpoints and deletes corresponding breakpoints. Since this is user-visible, GDB prints out: Thread-specific breakpoint 3 deleted - thread 2 is gone. And of course, we end up with: (gdb) info breakpoints Num Type Disp Enb Address What 2 breakpoint keep y 0x0000000000400614 in start at thread-specific-bp.c:23 breakpoint already hit 1 time 4 breakpoint keep y 0x000000000040061f in end at thread-specific-bp.c:29 breakpoint already hit 1 time 2013-09-17 Muhammad Waqas <mwaqas@codesourcery.com> Pedro Alves <palves@redhat.com> PR gdb/11568 * breakpoint.c (remove_threaded_breakpoints): New function. (_initialize_breakpoint): Attach remove_threaded_breakpoints as thread_exit observer. 2013-09-17 Muhammad Waqas <mwaqas@codesourccery.com> Jan Kratochvil <jan.kartochvil@redhat.com> Pedro Alves <palves@redhat.com> PR gdb/11568 * gdb.thread/thread-specific-bp.c: New file. * gdb.thread/thread-specific-bp.exp: New file.
2013-09-17This commit fixes a regression introduced by the new $_isvoid convenienceSergio Durigan Junior2-0/+6
function. It adds a check for $_isvoid during the test of "show convenience" output. gdb/testsuite/ 2013-09-17 Sergio Durigan Junior <sergiodj@redhat.com> * gdb.base/defaults.exp (<show_conv_list>): Add check for $_isvoid convenience function.
2013-09-17PR gdb/15911: "info threads" changes the default source and line (for ↵Pedro Alves21-36/+194
"break", "list") "info threads" changes the default source for "break" and "list", to whatever the location of the first/bottom thread in the thread list is... (gdb) b start (gdb) c ... (gdb) list *lists "start"* (gdb) b 23 Breakpoint 3 at 0x400614: file test.c, line 23. (gdb) info threads Id Target Id Frame * 2 Thread 0x7ffff7fcb700 (LWP 1760) "test" start (arg=0x0) at test.c:23 1 Thread 0x7ffff7fcc740 (LWP 1748) "test" 0x000000323dc08e60 in pthread_join (threadid=140737353922304, thread_return=0x0) at pthread_join.c:93 (gdb) b 23 Breakpoint 4 at 0x323dc08d90: file pthread_join.c, line 23. ^^^^^^^^^^^^^^^ (gdb) list 93 lll_wait_tid (pd->tid); 94 95 96 /* Restore cancellation mode. */ 97 CANCEL_RESET (oldtype); 98 99 /* Remove the handler. */ 100 pthread_cleanup_pop (0); 101 102 The issue is that print_stack_frame always sets the current sal to the frame's sal. print_frame_info (which print_stack_frame calls to do most of the work) also sets the last displayed sal, but only if print_what isn't LOCATION. Now the call in question, from within thread.c:print_thread_info, does pass in LOCATION as print_what, but print_stack_frame doesn't have the same check print_frame_info has. We could consider adding it, but setting these globals depending on print_what isn't very clean, IMO. What we have is two logically distinct operations mixed in the same function(s): #1 - print frame, in the format specified by {print_what, print_level and print_args}. #2 - We're displaying a frame to the user, and I want the default sal to point here, because the program stopped here, or the user did some context-changing command (up, down, etc.). So I added a new parameter to print_stack_frame & friends for point #2, and went through all calls in the tree adjusting as necessary. Tested on x86_64 Fedora 17. gdb/ 2013-09-17 Pedro Alves <palves@redhat.com> PR gdb/15911 * ada-tasks.c (task_command_1): Adjust call to print_stack_frame. * bsd-kvm.c (bsd_kvm_open, bsd_kvm_proc_cmd, bsd_kvm_pcb_cmd): * corelow.c (core_open): * frame.h (print_stack_frame, print_frame_info): New 'set_current_sal' parameter. * infcmd.c (finish_command, kill_command): Adjust call to print_stack_frame. * inferior.c (inferior_command): Likewise. * infrun.c (normal_stop): Likewise. * linux-fork.c (linux_fork_context): Likewise. * record-full.c (record_full_goto_entry, record_full_restore): Likewise. * remote-mips.c (common_open): Likewise. * stack.c (print_stack_frame): New 'set_current_sal' parameter. Use it. (print_frame_info): New 'set_current_sal' parameter. Set the last displayed sal depending on the new paremeter instead of looking at print_what. (backtrace_command_1, select_and_print_frame, frame_command) (current_frame_command, up_command, down_command): Adjust call to print_stack_frame. * thread.c (print_thread_info, restore_selected_frame) (do_captured_thread_select): Adjust call to print_stack_frame. * tracepoint.c (tfind_1): Likewise. * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames) (mi_cmd_stack_info_frame): Likewise. * mi/mi-interp.c (mi_on_normal_stop): Likewise. * mi/mi-main.c (mi_cmd_exec_return, mi_cmd_trace_find): Likewise. gdb/testsuite/ * gdb.threads/info-threads-cur-sal-2.c: New file. * gdb.threads/info-threads-cur-sal.c: New file. * gdb.threads/info-threads-cur-sal.exp: New file.
2013-09-17 Fix ChangeLog entry missing a ':' char.Luis Machado1-1/+1
2013-09-17 gdbserver/ChangeLogJiong Wang2-1/+5
* linux-tile-low.c (tile_regsets): Modify the size field to 64-bit for each register.
2013-09-17 PR ld/15957Nick Clifton2-6/+19
* deffilep.y (def_file_add_directive): Avoid readin past end of buffer.
2013-09-172013-09-16 Jiong Wang <jiwang@tilera.com>Jiong Wang2-1/+5
gdbserver/ChangeLog * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add linux-tile-low.o to srv_tgtobj.
2013-09-17opcodes/Richard Sandiford5-1/+13
* s390-opc.txt (clih): Make the immediate unsigned. gas/testsuite/ * gas/s390/zarch-z196.s, gas/s390/zarch-z196.d: Test CLIH with 4000000000.
2013-09-17gdb/testsuite/Yao Qi3-2/+18
* gdb.base/catch-load.c: Remove the include of "dlfcn.h". [__WIN32__]: Include "windows.h" and define macro dlopen and dlclose. [!__WIN32__]: Include "dlfcn.h". * gdb.base/catch-load.exp (one_catch_load_test): Match directory separator.
2013-09-17daily updateAlan Modra1-1/+1
2013-09-16 * lib/gdb.exp (using_fission): New proc.Doug Evans3-0/+19
* gdb.base/info-macros.exp: Skip test if using Fission.
2013-09-16 * gdb.base/break-interp.exp: Fix indentation.Doug Evans2-1/+5
2013-09-16The error message in the function was sayingSergio Durigan Junior2-1/+6
"You should provide one parameter..." while it should be saying "... one argument...". Replaced. 2013-09-16 Sergio Durigan Junior <sergiodj@redhat.com> * value.c (isvoid_internal_fn): Replace "parameter" with "argument".
2013-09-16 * README: Update references to writing code for GDB.Stan Shebs11-8363/+39
* configure.ac (build_warnings): Remove obsolete comment. * configure: Regenerate. * gdbarch.sh: Remove references to gdbint.texinfo. * gdbarch.h: Regenerate. * gdbtypes.c (objfile_type): Remove comments referencing internals manual and D10V. [gdb/doc] Remove the internals manual gdbint.texinfo. * Makefile.in (INFO_DEPS): Remove gdbint.info. (PDFFILES): Remove gdbint.pdf. (HTMLFILES): Remove gdbint/index.html. (HTMLFILES_INSTALL): Remove gdbint. (GDBINT_DOC_FILES): Remove. (dvi): Remove gdbint.dvi. (ps): Remove gdbint.ps. * gdbint.texinfo: Remove file. * gdb.texinfo (Maintenance Commands): Remove reference to gdbint.
2013-09-16Based on the discussion at:Sergio Durigan Junior8-0/+152
<https://sourceware.org/ml/gdb-patches/2013-09/msg00301.html> <https://sourceware.org/ml/gdb-patches/2013-09/msg00383.html> This patch adds a new convenience function called $_isvoid, whose only purpose is to check whether an expression is void or not. This became necessary because the new convenience variable $_exitsignal (not yet approved) has a mutual exclusive behavior with $_exitcode, i.e., when one is "defined" (i.e., non-void), the other is cleared (i.e., becomes void). Doug wanted a way to identify which variable to use, and checking for voidness is the obvious solution. It is worth mentioning that my first attempt, after a conversation with Doug, was to actually implement a new $_isdefined() convenience function. I would do that (for convenience variables) by calling lookup_only_internalvar. However, I found a few problems: - Whenever I called $_isdefined ($variable), $variable became defined (with a void value), and $_isdefined always returned true. - Then, I tried to implement $_isdefined ("variable"), and do the "$" + "variable" inside GDB, thus making it impossible for GDB to create the convenience variable. However, it was hard to extract the string without having to mess with values and their idiossincrasies. Therefore, I decided to abandon this attempt (specially because I didn't want to spend too much time struggling with it). Anyway, after talking to Doug again we decided that it would be easier to implement $_isvoid, and this will probably help in cases like <http://stackoverflow.com/questions/3744554/testing-if-a-gdb-convenience-variable-is-defined>. I wrote a NEWS entry for it, and some new lines on the documentation. gdb/ 2013-09-16 Sergio Durigan Junior <sergiodj@redhat.com> * NEWS: Mention new convenience function $_isvoid. * value.c (isvoid_internal_fn): New function. (_initialize_values): Add new convenience function $_isvoid. gdb/doc/ 2013-09-16 Sergio Durigan Junior <sergiodj@redhat.com> * gdb.texinfo (Convenience Functions): Mention new convenience function $_isvoid. gdb/testsuite/ 2013-09-16 Sergio Durigan Junior <sergiodj@redhat.com> * gdb.base/gdbvars.c (foo_void): New function. (foo_int): Likewise. * gdb.base/gdbvars.exp (test_convenience_functions): New function. Call it.