]> sourceware.org Git - insight.git/log
insight.git
5 years agoUpgrade submodule, sync patches and code.
Patrick Monnerat [Wed, 7 Aug 2019 15:19:47 +0000 (17:19 +0200)]
Upgrade submodule, sync patches and code.

Access to the source line information has been moved from struct symtab
to source cache. Adapt code to this new situation.

* gdbtk/generic/gdbtk-cmds.c (gdbtk_load_source): Get line offsets from
  source cache. Use normal open_source_file() since there are no offsets
  loading anymore at this stage.

5 years agoUpgrade submodule.
Patrick Monnerat [Fri, 2 Aug 2019 11:06:43 +0000 (13:06 +0200)]
Upgrade submodule.

5 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 26 Jul 2019 08:34:01 +0000 (10:34 +0200)]
Upgrade submodule, sync patch.

5 years agoUpgrade submodule, sync patches
Patrick Monnerat [Fri, 19 Jul 2019 10:35:42 +0000 (12:35 +0200)]
Upgrade submodule, sync patches

5 years agoUpgrade submodule, sync patches and code.
Patrick Monnerat [Fri, 12 Jul 2019 09:52:32 +0000 (11:52 +0200)]
Upgrade submodule, sync patches and code.

* gdbtk/generic/gdbtk-bp.c (get_point_list): first arg is now a bool function.
* gdbtk/generic/gdbtk-cmds.c: change resolution of STRINGIFY macro conflict.
* gdbtk/generic/gdbtk-hooks.c: likewise.
* gdbtk/generic/gdbtk.c: likewise.
  gdb/common has been renamed: include version.h from gdb/gdbsupport.

5 years agoUpgrade submodule, sync patch
Patrick Monnerat [Fri, 5 Jul 2019 10:22:30 +0000 (12:22 +0200)]
Upgrade submodule, sync patch

5 years agoUpgrade submodule.
Patrick Monnerat [Fri, 28 Jun 2019 07:58:55 +0000 (09:58 +0200)]
Upgrade submodule.

5 years agoUpgrade submodule, sync code.
Patrick Monnerat [Thu, 20 Jun 2019 12:58:09 +0000 (14:58 +0200)]
Upgrade submodule, sync code.

deprecated_interactive hook has disappeared: remove its (noop) use.

* gdbtk/generic/gdbtk-hooks.c (gdbtk_add_hooks): remove setting of
  deprecated_interactive_hook.
* gdbtk/generic/gdbtk.[ch] (gdbtk_interactive): remove.

5 years agoUpgrade submodule, sync patches and code.
Patrick Monnerat [Sun, 16 Jun 2019 04:01:43 +0000 (06:01 +0200)]
Upgrade submodule, sync patches and code.

* configure.ac: binutils-gdb/gdb/gnulib has moved up one level, so regenerate
  at its new location.
* gdbtk/generic/gdbtk-cmds.c (gdbtk_load_source): find_source_lines() is not
  exported anymore, but open_source_file_with_line_charpos() does it for you:
  use the later instead of open_source_file().

5 years agoUpgrade submodule, sync patches.
Patrick Monnerat [Fri, 14 Jun 2019 09:57:08 +0000 (11:57 +0200)]
Upgrade submodule, sync patches.

5 years agoUpgrade submodule, sync patches
Patrick Monnerat [Fri, 7 Jun 2019 11:10:17 +0000 (13:10 +0200)]
Upgrade submodule, sync patches

5 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 31 May 2019 04:25:55 +0000 (06:25 +0200)]
Upgrade submodule, sync patch.

5 years agoUpgrade submodule.
Patrick Monnerat [Fri, 24 May 2019 12:58:41 +0000 (14:58 +0200)]
Upgrade submodule.

5 years agoUpgrade submodule, sync code.
Patrick Monnerat [Fri, 17 May 2019 15:30:17 +0000 (17:30 +0200)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-interp.[ch] (set_logging): add new debug_redirect
  parameter.

5 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 10 May 2019 13:22:06 +0000 (15:22 +0200)]
Upgrade submodule, sync patch.

5 years agoUpgrade submodule.
Patrick Monnerat [Fri, 3 May 2019 10:33:19 +0000 (12:33 +0200)]
Upgrade submodule.

5 years agoUpgrade submodule, sync patches and code.
Patrick Monnerat [Mon, 29 Apr 2019 23:07:42 +0000 (01:07 +0200)]
Upgrade submodule, sync patches and code.

* gdbtk/generic/gdbtk-interp.c (gdbtk_interp::suspend): exception_none has
  disappeared: return an empty gdb_exception.

5 years agoUpgrade submodule, sync patch and code.
Patrick Monnerat [Thu, 11 Apr 2019 15:34:08 +0000 (17:34 +0200)]
Upgrade submodule, sync patch and code.

The internal gdb exception TRY/CATCH support has been replaced by
C++ exceptions: adapt the code to this new situation.

* gdbtk/generic/gdbtk-bp.c (gdb_set_bp): use try/catch.
* gdbtk/generic/gdbtk-cmds.c (gdbtk_call_wrapper): use try/catch.
  (gdbtk_load_asm): use try/catch/throw.
  (gdb_loadfile): use try/catch.
* gdbtk/generic/gdbtk-varobj.c (variable_value): use try/catch.
  (variable_print): use try/catch.
* gdbtk/generic/gdbtk-wrapper.c (GDBTK_CATCH_ERRORS): use try/catch.
* gdbtk/generic/gdbtk.c (gdbtk_source_start_file): use throw_error().

5 years agoUpgrade submodule, sync patches.
Patrick Monnerat [Fri, 5 Apr 2019 11:10:55 +0000 (13:10 +0200)]
Upgrade submodule, sync patches.

5 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 29 Mar 2019 11:14:08 +0000 (12:14 +0100)]
Upgrade submodule, sync patch.

5 years agoUpgrade submodule.
Patrick Monnerat [Fri, 22 Mar 2019 08:37:24 +0000 (09:37 +0100)]
Upgrade submodule.

5 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Sat, 16 Mar 2019 10:57:40 +0000 (11:57 +0100)]
Upgrade submodule, sync patch.

5 years agoUpgrade submodule, sync code.
Patrick Monnerat [Fri, 8 Mar 2019 17:19:39 +0000 (18:19 +0100)]
Upgrade submodule, sync code.

Function make_cleanup() has been removed: do not use it anymore. Instead,
use try/catch blocks and object destructors.

Move the global tcl interpreter pointer into the gdbtk_interp class. New
function gdbtk_get_interp() returns the current gdb interpreter, throwing
an exception if it is not a gdbtk_interp.

New header file gdbtk_interp.h holds the specific gdb interpreter's definitions.

* gdbtk/generic/gdbtk-bp.c (breakpoint_notify): get tcl interpreter from
  gdbtk interpreter object.
* gdbtk/generic/gdbtk-cmds.c (Gdbtk_Init): use tcl interpreter parameter.
  (gdbtk_load_asm): restore result pointer using a try/catch block.
* gdbtk/generic/gdbtk-hooks.c (gdbtk_two_elem_cmd, gdbtk_file::read,
  gdbtk_getpid, report_error, gdbtk_ignorable_warning, gdbtk_register_changed,
  gdbtk_memory_changed, x_event, gdbtk_readline, gdbtk_readline_end,
  gdbtk_call_command, gdbtk_param_changed, gdbtk_load_hash,
  gdbtk_post_add_symbol, gdbtk_query, gdbtk_trace_find, gdbtk_trace_start_stop,
  gdbtk_annotate_signal, gdbtk_attach, gdbtk_detach,
  gdbtk_architecture_changed): get tcl interpreter from current gdbtk
  interpreter.
* gdbtk/generic/gdbtk-interp.c: Move class and global definitions to new
  header file.
  (gdbtk_interp::gdbtk_interp): New constructor.
  (gdbtk_interp::~gdbtk_interp): New destructor.
  (gdbtk_interp::init): Call gdbtk_init() with parameter.
  (gdbtk_interp::resume): Call gdbtk_source_start_file() with parameter.
  (gdbtk_interp::pre_command_loop): Use tcl interpreter from object.
  (gdbtk_get_interp): New function.
* gdbtk/generic/gdbtk-register.c (get_register_size, get_register_collectable,
  get_register_types): get tcl interpreter from current gdbtk interpreter.
* gdbtk/generic/gdbtk.c (TclDebug, gdbtk_cleanup, tk_command, view_command):
  Use tcl interpreter from current gdbtk interpreter.
  (gdbtk_uninstall_notifier): not static anymore.
  (cleanup_init): Deleted since the tcl interpreter is deleted in the
  gdbtk interpreter destructor.
  (gdbtk_init): store the tcl interpreter in the gdbtk interpreter. Drop
  cleanup chain.
  (gdbtk_source_start_file): use tcl interpreter from new parameter.
* gdbtk/generic/gdbtk.h (gdbtk_tcl_interp): Deleted.
  (gdbtk_init, gdbtk_source_start_file): New parameter gdbtk_interp *.
  (gdbtk_uninstall_notifier): extern.
* gdbtk/generic/gdbtk-interp.h: New header file.

5 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 1 Mar 2019 15:00:31 +0000 (16:00 +0100)]
Upgrade submodule, sync patch.

5 years agoUpgrade submodule.
Patrick Monnerat [Fri, 22 Feb 2019 13:14:19 +0000 (14:14 +0100)]
Upgrade submodule.

5 years agotkTable: include ctype.h for isdigit definition.
Patrick Monnerat [Wed, 20 Feb 2019 14:26:34 +0000 (15:26 +0100)]
tkTable: include ctype.h for isdigit definition.

* libgui/src/tkTable.h: include ctype.h.

5 years agoUpgrade submodule, sync patches.
Patrick Monnerat [Fri, 15 Feb 2019 02:02:23 +0000 (03:02 +0100)]
Upgrade submodule, sync patches.

5 years agoUpgrade submodule, sync patches.
Patrick Monnerat [Thu, 7 Feb 2019 16:27:55 +0000 (17:27 +0100)]
Upgrade submodule, sync patches.

5 years agoUpgrade submodule.
Patrick Monnerat [Fri, 1 Feb 2019 11:53:21 +0000 (12:53 +0100)]
Upgrade submodule.

5 years agoUpgrade submodule, sync sources.
Patrick Monnerat [Mon, 28 Jan 2019 02:52:24 +0000 (03:52 +0100)]
Upgrade submodule, sync sources.

Gdb makefile does not provide -I for common subdirectory anymore.

* gdbtk/generic/gdbtk.c: include common/version.h.

5 years agoUpgrade submodule, sync sources.
Patrick Monnerat [Thu, 24 Jan 2019 11:58:28 +0000 (12:58 +0100)]
Upgrade submodule, sync sources.

Since the recent introduction of scope_exit in gdb, there is a preprocessor
definition conflict on symbol STRINGIFY between tcl and gdb's inferior.h.

* gdbtk/generic/gdbtk-cmds.c: undefine tcl's STRINGIFY.
* gdbtk/generic/gdbtk-hooks.c: Likewise.
* gdbtk/generic/gdbtk.c: Likewise.

5 years agoUpgrade submodule, sync code.
Patrick Monnerat [Fri, 18 Jan 2019 00:32:22 +0000 (01:32 +0100)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-cmds.c (gdb_listfiles): use a program space_method for
  objfiles.
  Use an objfile method for compunits.

5 years agoUpgrade submodule, sync patch and code.
Patrick Monnerat [Thu, 10 Jan 2019 12:33:19 +0000 (13:33 +0100)]
Upgrade submodule, sync patch and code.

* gdbtk/generic/gdbtk-cmds.c (gdb_listfiles): gdb macro ALL_FILETABS has been
  removed, replace its use with inline code.

5 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 4 Jan 2019 07:57:15 +0000 (08:57 +0100)]
Upgrade submodule, sync patch.

5 years agoconfigure.ac: remove an erroneous extra right parenthesis.
Patrick Monnerat [Tue, 1 Jan 2019 13:37:57 +0000 (14:37 +0100)]
configure.ac: remove an erroneous extra right parenthesis.

5 years agoUpgrade submodule, sync patches and create a new one.
Patrick Monnerat [Tue, 1 Jan 2019 13:10:37 +0000 (14:10 +0100)]
Upgrade submodule, sync patches and create a new one.

Recent changes to gdb/Makefile break gdbtk compilation: the solution is
to keep gdbtk object files in their sources directory.
New patch gdbtk-obj-in-subdir implements this strategy.

5 years agoUpgrade submodule.
Patrick Monnerat [Sat, 22 Dec 2018 00:54:14 +0000 (01:54 +0100)]
Upgrade submodule.

5 years agoUpgrade submodule
Patrick Monnerat [Fri, 14 Dec 2018 12:45:52 +0000 (13:45 +0100)]
Upgrade submodule

5 years agoUpgrade submodule, sync code.
Patrick Monnerat [Wed, 5 Dec 2018 08:47:06 +0000 (09:47 +0100)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-cmds.c (gdb_entry_point): use stratum method.

5 years agoUpgrade submodule
Patrick Monnerat [Fri, 30 Nov 2018 14:39:59 +0000 (15:39 +0100)]
Upgrade submodule

5 years agoUpgrade submodule, sync patch and code.
Patrick Monnerat [Sun, 25 Nov 2018 00:18:24 +0000 (01:18 +0100)]
Upgrade submodule, sync patch and code.

gdb is_running() function has been removed.

* gdbtk/generic/gdbtk-hooks.c (gdbtk_call_command): replace call to is_running()
  by a thread state test.

5 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 16 Nov 2018 19:18:06 +0000 (20:18 +0100)]
Upgrade submodule, sync patch.

6 years agoUpgrade submodule, sync code.
Patrick Monnerat [Sat, 10 Nov 2018 01:34:52 +0000 (02:34 +0100)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-cmds.c (gdbtk_load_source): open_source_file now
  returns a scoped_fd: get the file descriptor and release scoped_fd.
  (symtab_to_filename): let scoped_fd be closed automatically.

6 years agoUpgrade submodule, sync patch and code.
Patrick Monnerat [Sun, 4 Nov 2018 17:37:30 +0000 (18:37 +0100)]
Upgrade submodule, sync patch and code.

* gdbtk/generic/gdbtk-cmds.c (gdb_search): search_symbols() requires a new
  t_regexp parameter that can be passed as NULL.

6 years agoUpgrade submodule.
Patrick Monnerat [Sat, 27 Oct 2018 10:54:23 +0000 (12:54 +0200)]
Upgrade submodule.

6 years agoUpgrade submodule.
Patrick Monnerat [Fri, 19 Oct 2018 09:03:03 +0000 (11:03 +0200)]
Upgrade submodule.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 12 Oct 2018 09:38:55 +0000 (11:38 +0200)]
Upgrade submodule, sync patch.

6 years agoUpgrade submodule, sync patches.
Patrick Monnerat [Fri, 5 Oct 2018 11:27:22 +0000 (13:27 +0200)]
Upgrade submodule, sync patches.

6 years agoRename variables hiding others defined on another scope.
Patrick Monnerat [Fri, 5 Oct 2018 11:14:42 +0000 (13:14 +0200)]
Rename variables hiding others defined on another scope.

* gdbtk/generic/gdbtk-cmds.c (gdb_find_file_command): rename struct stat st to
  sbuf.
* gdbtk/generic/gdbtk-varobj.c (variable_update): rename Tcl_Obj *var to v.
* gdbtk/generic/gdbtk.c: global gdbtk_source_filename is now an std::string.
  (gdbtk_source_start_file): drop const char *s, rephrase concatenation in C++.
  (gdbtk_test): xstrdup is not needed anymore.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Tue, 2 Oct 2018 13:49:46 +0000 (15:49 +0200)]
Upgrade submodule, sync patch.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Mon, 24 Sep 2018 10:32:05 +0000 (12:32 +0200)]
Upgrade submodule, sync patch.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 7 Sep 2018 10:53:38 +0000 (12:53 +0200)]
Upgrade submodule, sync patch.

6 years agoUpgrade submodules, sync patches.
Patrick Monnerat [Fri, 31 Aug 2018 18:10:22 +0000 (20:10 +0200)]
Upgrade submodules, sync patches.

6 years agoRegisters are target-dependent, not frame-dependant.
Patrick Monnerat [Fri, 31 Aug 2018 17:44:08 +0000 (19:44 +0200)]
Registers are target-dependent, not frame-dependant.

This fixes a bug occurring when starting a compatible, non-native architecture
program, like a 32-bit program on a 64-bit architecture.

Reported-By: Igor <astandet at gmail.com>
* gdbtk/generic/gdbtk-register.c (gdb_regformat): check registers architecture
  against target, not frame.

6 years agoTcl expects a return value: wrapped function cannot be typed void.
Patrick Monnerat [Fri, 31 Aug 2018 17:40:19 +0000 (19:40 +0200)]
Tcl expects a return value: wrapped function cannot be typed void.

* gdbtk/generic/gdbtk-register.c (setup_architecture_data): typed int and
  return Tcl status.

6 years agoUpgrade submodule.
Patrick Monnerat [Mon, 27 Aug 2018 16:45:09 +0000 (18:45 +0200)]
Upgrade submodule.

6 years agoFix a C++ translation sort bug.
Patrick Monnerat [Mon, 27 Aug 2018 16:38:09 +0000 (18:38 +0200)]
Fix a C++ translation sort bug.

Reported-by: Igor <astandet at gmail dot com>
* gdbtk/generic/gdbtk-cmds.c (gdb_listfiles): use a lambda compare function for
  sorting.

6 years agoUpgrade submodule.
Patrick Monnerat [Fri, 24 Aug 2018 10:39:21 +0000 (12:39 +0200)]
Upgrade submodule.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Sun, 19 Aug 2018 23:52:14 +0000 (01:52 +0200)]
Upgrade submodule, sync patch.

6 years agoUpgrade submodule.
Patrick Monnerat [Fri, 10 Aug 2018 07:12:09 +0000 (09:12 +0200)]
Upgrade submodule.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 27 Jul 2018 09:11:20 +0000 (11:11 +0200)]
Upgrade submodule, sync patch.

6 years agoRemove unused variables.
Patrick Monnerat [Fri, 27 Jul 2018 09:02:00 +0000 (11:02 +0200)]
Remove unused variables.

* gdbtk/generic/gdbtk-bp.c (gdb_get_breakpoint_info): remove new_obj.
  (gdb_set_bp): remove e.
* gdbtk/generic/gdbtk-cmds.c (gdb_listfiles): remove psymtab and pathname.
* gdbtk/generic/gdbtk-register.c (get_register): remove addr, lval and dummy.
  (setup_architecture_data): remove numregs.
  (gdb_reggrouplist): remove i.
* gdbtk/generic/gdbtk-varobj.c (variable_update): remove i.
  (variable_value): remove e.
  (variable_print): remove except.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 20 Jul 2018 07:56:37 +0000 (09:56 +0200)]
Upgrade submodule, sync patch.

6 years agoUpgrade submodule, sync patches and code.
Patrick Monnerat [Fri, 13 Jul 2018 09:27:46 +0000 (11:27 +0200)]
Upgrade submodule, sync patches and code.

Insight gdb interpreter is no longer automatically initialized by gdb.
Initalize it explicitly.

* gdbtk/generic/gdbtk-interp.c (_initialize_gdbtk_interp): rename
  as initialize_gdbtk_interp.
* gdbtk/generic/gdbtk-main.c (main): call initialize_gdbtk_interp ().

6 years agoRemove obsolete targets.
Patrick Monnerat [Fri, 6 Jul 2018 11:50:15 +0000 (13:50 +0200)]
Remove obsolete targets.

* gdbtk/library/targetselection.itb (TargetSelection::init_target_db):
  targets sds, rdi, rdp, m32r, mon2000, sparclite, ice, mips, pmon,
  ddb, picobug, cisco, vxworks removed.

6 years agoUpgrade submodule, sync code.
Patrick Monnerat [Thu, 5 Jul 2018 23:30:14 +0000 (01:30 +0200)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-bp.c (gdb_trace_status): tp_vec is now an
  std::vector<breakpoint *>.
* gdbtk/generic/gdbtk-cmds.c (gdb_clear_file): replace ptid_equal() call
  by the inequality operator.
  (gdb_target_has_execution_command): likewise.
  (gdb_loc): likewise.
* gdbtk/generic/gdbtk-hooks.c (gdbtk_call_command): replace ptid_equal() call
  by the inequality operator.
  (gdbtk_annotate_signal): replace ptid_equal() call by the equality operator.

6 years agoRemove redundant empty methods.
Patrick Monnerat [Sat, 30 Jun 2018 10:32:20 +0000 (12:32 +0200)]
Remove redundant empty methods.

* gdbtk/library/pointwin.it[hb] (PointWin::breakpoint): removed.
  (PointWin::tracepoint): removed.
  (PointWin::watchpoint): removed.
* gdbtk/library/srctextwin.it[hb] (SrcTextWin::watchpoint): removed.

6 years agoFix an error message.
Patrick Monnerat [Sat, 30 Jun 2018 10:24:37 +0000 (12:24 +0200)]
Fix an error message.

The usage text of an error message was erroneous.

* gdbtk/library/gdbevent.itb (UpdateEvent::get): fix error message.

6 years agoUpgrade submodule, sync patch and code.
Patrick Monnerat [Fri, 29 Jun 2018 09:49:43 +0000 (11:49 +0200)]
Upgrade submodule, sync patch and code.

* gdbtk/generic/gdbtk-cmds.c (gdb_loc): get stop_pc from inferior thread
  structure (gdb global stop_pc has been removed).

6 years agoUpgrade submodule.
Patrick Monnerat [Mon, 25 Jun 2018 12:46:07 +0000 (14:46 +0200)]
Upgrade submodule.

6 years agoAdd gdb patch to fix breakpoint auto-disable notification.
Patrick Monnerat [Mon, 25 Jun 2018 12:41:57 +0000 (14:41 +0200)]
Add gdb patch to fix breakpoint auto-disable notification.

6 years agoTpWin: get rid of obsolete tracepoint commands.
Patrick Monnerat [Mon, 25 Jun 2018 09:50:20 +0000 (11:50 +0200)]
TpWin: get rid of obsolete tracepoint commands.

This also allows to simplify PointWin methods.

* gdbtk/library/pointwin.it[hb] (PointWin::enable_disable): remove
  type parameter.
  (PointWin::remove): Likewise.
  (PointWin::forall): remove arg parameter.
* gdbtk/library/tpwin.it[hb] (TpWin::forall): deleted.
  (TpWin::enable_disable): deleted.
  (TpWin::remove): deleted.
* gdbtk/library/bpwin.itb (BpWin::enable_disable): chain without type parameter.

6 years agoFix "enable count" breakpoints handling in source window.
Patrick Monnerat [Mon, 25 Jun 2018 09:31:21 +0000 (11:31 +0200)]
Fix "enable count" breakpoints handling in source window.

Consider those as normal breakpoints.

* gdbtk/library/srctextwin.itb (SrcTextWin::do_bp): always define remove_type.
  Process type "disable".

6 years agoIntroduce watchpoints.
Patrick Monnerat [Sun, 24 Jun 2018 15:00:35 +0000 (17:00 +0200)]
Introduce watchpoints.

New watchpoint events, a watchpoint window (double-click shows the
expression in the watch window), menu entries and icons to open watchpoint
window and add a watchpoint for a variable.

* gdbtk/generic/gdbtk-bp.c (have_masked_watchpoints): new local procedure.
  (gdb_get_watchpoint_list): new tcl procedure.
  (gdb_get_watchpoint_info): new tcl procedure.
  (gdb_have_masked_watchpoints): new tcl procedure.
  (breakpoint_notify): handle watchpoints.
* gdbtk/library/ehandler.ith (GDBEventHandler::watchpoint): new method.
* gdbtk/library/gdbevent.ith (WatchpointEvent): new class.
* gdbtk/library/gdbevent.itb (WatchpointEvent::get): new method.
  (WatchpointEvent::_init): new method.
* gdbtk/library/interface.tcl (gdbtk_tcl_watchpoint): new procedure.
* gdbtk/library/pointwin.it[hb] (PointWin::watchpoint): new method.
* gdbtk/library/images/wp.gif: new icon image
* gdbtk/library/images2/wp.gif: new icon image
* gdbtk/library/prefs.tcl (pref_set_defaults): define watchpoints preferences.
* gdbtk/library/session.tcl (_serialize_bps): serialize watchpoints too.
* gdbtk/library/srcbar.itcl (SrcBar::create_view_menu): new Watchpoints entry.
  (SrcBar::create_window_buttons): new watchpoints button.
  (SrcBar::_load_images): load watchpoints icon image.
* gdbtk/library/srctextwin.it[hb] (SrcTextWin::config_win): bind watchpoints
  shortcut.
  (SrcTextWin::watchpoint): new method.
  (SrcTextWin::do_source_popup): add menu entry to set a watchpoint on variable.
  (SrcTextWin::do_key): handle watchpoint key binding.
* gdbtk/library/wpwin.it[hb] (WpWin) new class.
  (WpWin::constructor): new.
  (WpWin::watch_type): new variable.
  (WpWin::watch_entry): new variable.
  (WpWin::global_menu): new overloaded method.
  (WpWin::local_menu): new overloaded method.
  (WpWin::update_local_menu): new overloaded method.
  (WpWin::header): new overloaded method.
  (WpWin::change): new overloaded method.
  (WpWin::add): new overloaded method.
  (WpWin::store): new method.
  (WpWin::watchpoint): new overloaded method.
  (WpWin::toggle_threads): new method.
  (WpWin::set_type): new method.
  (WpWin::goto): new overloaded method.
  (WpWin::delete_point): new overloaded method.
  (WpWin::get_point_list): new overloaded method.

6 years agoFix error occurring upon watch window closing.
Patrick Monnerat [Sun, 24 Jun 2018 14:14:06 +0000 (16:14 +0200)]
Fix error occurring upon watch window closing.

Since some idle script can be pending for a VarTree, let tcl destroy it
when possible.

* gdbtk/library/watch.tcl (WatchTree::destructor): only delete variables
  and clear root list; do not act on parent VarTree.
  (WatchWin::destructor): do not explicitly delete tree, just unreference it.

6 years agoRestructure breakpoint/tracepoint window code.
Patrick Monnerat [Sun, 24 Jun 2018 12:18:45 +0000 (14:18 +0200)]
Restructure breakpoint/tracepoint window code.

BpWin and TpWin classes are now subclasses of a new PointWin class.
PointWin implements the window layout and its subclasses only provide
specific content-related code. See gdbtk/library/pointwin.ith for more
details.

Condition, ignore count and hits count columns are also added.

* gdbtk/library/pointwin.ith (PointWin): new class.
  (PointWin::PointKind): new variable.
  (PointWin::MenuBar): new variable.
  (PointWin::Menu): new variable.
  (PointWin::columns): new variable.
  (PointWin::twin): new variable.
  (PointWin::selected): new variable.
  (PointWin::next_row): new variable.
  (PointWin::bg1): new variable.
  (PointWin::index_to_num): new variable.
  (PointWin::enabled): new variable.
  (PointWin::hidden): new variable.
* gdbtk/library/pointwin.itb (PointWin::constructor): new method.
  (PointWin::create_event): new method.
  (PointWin)::select): new method.
  (PointWin::enable_disable): new method.
  (PointWin::remove): new method.
  (PointWin::delete_point): new method.
  (PointWin::breakpoint): new method.
  (PointWin::tracepoint): new method.
  (PointWin::forall): new method.
  (PointWin::hide_column): new method.
  (PointWin::show_column): new method.
  (PointWin::change): new method.
  (PointWin::add): new method.
  (PointWin::modify): new method.
  (PointWin::restore): new method.
  (PointWin::_select_and_popup): new method.
  (PointWin::basename): new method.
  (PointWin::header): new method.
  (PointWin::global_menu): new method.
  (PointWin::local_menu): new method.
  (PointWin::update_local_menu): new method.
  (PointWin::goto): new method.
  (PointWin::store_details): new method.
* gdbtk/library/bpwin.it[hb] (BpWin): subclass of PointWin.
  (BpWin::tracepoints): removed.
  (BpWin::twin): removed.
  (BpWin::next_row): removed.
  (BpWin::index_to_bpnum): removed.
  (BpWin::Index_to_bptype): renamed BpWin::disposition.
  (BpWin::selected): removed.
  (BpWin::mbar): removed.
  (BpWin::bg1): removed.
  (BpWin::Menu): removed.
  (BpWin::show_threads): removed.
  (BpWin::constructor): moved to bpwin.ith.
  (BpWin::destructor): removed.
  (BpWin::build_win): removed.
  (BpWin::bp_add): renamed BpWin::add. Uses parent method.
  (BpWin::bp_store): renamed BpWin::store.
  (BpWin::bp_restore): removed.
  (BpWin::bp_select): removed.
  (BpWin:: _select_and_popup): removed.
  (BpWin::bp_modify): removed.
  (BpWin::bp_able): renamed BpWin::enable_disable. Uses parent method.
  (BpWin::bp_remove): removed.
  (BpWin::bp_type): renamed BpWin::set_type.
  (BpWin::bp_delete): removed.
  (BpWin::tracepoint): removed.
  (BpWin::bp_all): renamed BpWin::forall. Uses parent method.
  (BpWin::get_actions): removed.
  (BpWin::toggle_threads): Use parent methods hide_column/show_column.
  (BpWin::reconfig): removed.
  (BpWin::goto_bp): renamed BpWin::goto.
  (BpWin::global_menu): new overloaded method.
  (BpWin::local_menu): new overloaded method.
  (BpWin::update_local_menu): new overloaded method.
  (BpWin::header): new overloaded method.
  (BpWin::change): new overloaded method.
  (BpWin::get_point_list): new overloaded method.
* gdbtk/library/tpwin.itcl: deleted.
* gdbtk/library/tpwin.it[hb] (TpWin): subclass of PointWin.
  (TpWin::constructor): uses parent method.
  (TpWin::local_menu): new overloaded method.
  (TpWin::update_local_menu): new overloaded method.
  (TpWin::header): new overloaded method.
  (TpWin::change): new overloaded method.
  (TpWin::add): new overloaded method.
  (TpWin::store): new method.
  (TpWin::forall): new overloaded method.
  (TpWin::enable_disable): new overloaded method.
  (TpWin::remove): new overloaded method.
  (TpWin::tracepoint): new overloaded method.
  (TpWin::get_actions): new method.
  (TpWin::goto): new overloaded method.
  (TpWin::get_point_list): new overloaded method.

6 years agoRemove redundant method body.
Patrick Monnerat [Sun, 24 Jun 2018 12:00:41 +0000 (14:00 +0200)]
Remove redundant method body.

* gdbtk/library/gdbevent.itb (TracepointEvent::get): remove 2nd body occurrence.

6 years agoBreakpoint events do no include other point events anymore.
Patrick Monnerat [Sun, 24 Jun 2018 10:14:47 +0000 (12:14 +0200)]
Breakpoint events do no include other point events anymore.

* gdbtk/generic/gdbtk-bp.c (get_point_list): new function.
  (gdb_get_breakpoint_info): do not return user_specification.
  (gdb_get_breakpoint_list): use get_point_list.
  (breakpoint_notify): suppress get_tracepoint call since it should
  always fail if get_breakpoint does.
  Dispatch by point type to check it and build tcl command.
  (gdb_get_tracepoint_info): return condition.
  (gdb_get_tracepoint_list): use get_point_list.
* gdbtk/library/bpwin.itb (BpWin::bp_store): do not handle user_spec.
  (BpWin::bp_type): likewise.
  (BpWin::get_actions): adjust to gdb_get_tracepoint_info additional list value.
* gdbtk/library/gdbevent.ith, gdbtk/library/gdbevent.itb:
  (BreakpointEvent): no more user_specification.
  (TracepointEvent): implement condition.
* gdbtk/library/session.tcl (Session::_serialize_bps): handle breakpoints
  only and drop user_specification.
* gdbtk/library/srctextwin.itb (SrcTextWin::showBPBalloon): drop
  user_specification.
  (SrcTextWin::showTPBalloon): lassign tracepoint condition.
* gdbtk/library/tracedlg.tcl (TraceDlg::build_win): comment new
  get_get_tracepoint_info condition list item.
* gdbtk/library/util.tcl (bp_exists): drop user_specification.

6 years agoWatch: Automatic gdb variable clean-up.
Patrick Monnerat [Sun, 24 Jun 2018 09:14:34 +0000 (11:14 +0200)]
Watch: Automatic gdb variable clean-up.

Also supports specifying the frame context for an expression, external
selection and checking if a variable is watched.

The overall is handled by a new WatchTree subclass of VarTree.

* gdbtk/library/vartree.ith (VarTree::rootlist): protected.
  (VarTree::setselection): public.
* gdbtk/library/watch.tcl (WatchTree): new class.
  (WatchTree::add): new overloaded method.
  (WatchTree::remove): new overloaded method.
  (WatchTree::in_tree): new method.
  (WatchWin::no_inferior): Delegate variable removal to tree methods.
  (WatchWin::build_win): tree is a WatchTree.
  (WatchWin::destructor): explicitly delete tree.
  (WatchWin::remove): delegate removal to tree.
  parameter.
  (WatchWin::select): new method.
  (WatchWin::watched): new method.
  (WatchWin::add): delegate addition to tree. Supports an optional frame
  (WatchWin::Watched): removed.

6 years agoAdd lmap command for tcl pre 8.6 versions.
Patrick Monnerat [Sun, 24 Jun 2018 08:59:37 +0000 (10:59 +0200)]
Add lmap command for tcl pre 8.6 versions.

* libgui/library/list.tcl (lmap): new procedure.

6 years agoUpgrade submodule, sync patches.
Patrick Monnerat [Fri, 22 Jun 2018 09:00:14 +0000 (11:00 +0200)]
Upgrade submodule, sync patches.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Tue, 19 Jun 2018 10:35:02 +0000 (12:35 +0200)]
Upgrade submodule, sync patch.

6 years agoSync bptypes string table with enum bptype.
Patrick Monnerat [Tue, 19 Jun 2018 09:58:47 +0000 (11:58 +0200)]
Sync bptypes string table with enum bptype.

* gdbtk/generic/gdbtk-bp.c (bptypes): Synced to match current enum definitions.

6 years agoUpgrade submodule, sync code.
Patrick Monnerat [Tue, 12 Jun 2018 15:00:58 +0000 (17:00 +0200)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-register.c (gdbtk_reg_buffer::changed_p): variable
  regstatus is now of type register_status.

6 years agoReplace most dynamic allocations by STL objects.
Patrick Monnerat [Tue, 12 Jun 2018 14:24:07 +0000 (16:24 +0200)]
Replace most dynamic allocations by STL objects.

This saves the need to explicitly deallocate storage when no longer used.

* gdbtk/generic/gdbtk-bp.c (breakpoint_notify): buf is now an std::string.
  (tracepoint_exists): file is now an std::string. Catch allocation errors.
* gdbtk/generic/gdbtk-cmds.c (listfiles_info): keep files in a std::vector.
  pathname is now a std::string. New method addfile ().
  (do_listfiles): Use updated listfiles_info structure.
  (gdb_listfiles): Variables files, file_size; numfiles and len deleted.
  Use updated listfiles_info structure. Use std::sort rather than qsort.
  (comp_files): deleted.
  (gdb_search): files is now a std::vector. Catch allocation errors.
  (gdbtk_load_asm): buffer is now a std::string.
  (gdb_update_mem): mbuf is now a std::vector.
  (gdbtk_set_result): buf is now a std::string.
* gdbtk/generic/gdbtk-register.c (gdbtk_reg_buffer): m_format and m_types are
  now of type std::vector. Destructor deleted.
  (get_register_types): buff deleted.
* gdbtk/generic/gdbtk.c (gdbtk_init): variable s deleted. Use string_printf
  instad of xstrprintf.
  (tk_command): result is now a std::string. Remove unneeded cleanup chain
  handling.
  (view_command): script is now a std::string. Remove unneeded cleanup chain
  handling.

6 years agoUpgrade submodule, sync code.
Patrick Monnerat [Fri, 8 Jun 2018 09:38:50 +0000 (11:38 +0200)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-cmds.c
  (gdb_entry_point): target_stack --> current_top_target().
  (gdb_update_mem): likewise.
* gdbtk/generic/gdbtk.c (gdbtk_start_timer): likewise.

6 years agoUpgrade submodule.
Patrick Monnerat [Thu, 31 May 2018 22:50:33 +0000 (00:50 +0200)]
Upgrade submodule.

6 years agoREADME: suggest disabling isl library in configure example.
Patrick Monnerat [Fri, 25 May 2018 13:30:54 +0000 (15:30 +0200)]
README: suggest disabling isl library in configure example.

6 years agoUpgrade submodule.
Patrick Monnerat [Fri, 25 May 2018 13:29:32 +0000 (15:29 +0200)]
Upgrade submodule.

6 years agoconfigure: use "--add-missing" on automake invocations.
Patrick Monnerat [Fri, 25 May 2018 13:21:00 +0000 (15:21 +0200)]
configure: use "--add-missing" on automake invocations.

This allows newer versions of automake to create files that were not
implemented in automake version use by binutils/gdb.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Fri, 18 May 2018 00:28:51 +0000 (02:28 +0200)]
Upgrade submodule, sync patch.

6 years agoBug fix: the flattened current_target is gone.
Patrick Monnerat [Tue, 15 May 2018 01:59:15 +0000 (03:59 +0200)]
Bug fix: the flattened current_target is gone.

Thus do not use beneath member to access target memory.

* gdbtk/generic/gdbtk-cmds.c (gdb_update_mem): read memory from target_stack.

6 years agoUpgrade submodule, sync code.
Patrick Monnerat [Thu, 10 May 2018 10:59:27 +0000 (12:59 +0200)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-bp.c (get_breakpoint_commands): use body_list_0.get()  and
  body_list_1.get() instead of body_list[0] and body_list[1].
  body_count does not exist anymore: check instead body_list_1 being null.
  (gdb_actions_command): replace type command_line_up by counted_command_line.
  Pass a lambda function to read_command_lines_1 instead of removed
  check_tracepoint_command function.
  (gdb_get_action_list): use body_list_0 instead of body_list[0].

6 years agoUpgrade submodule, sync patch and code.
Patrick Monnerat [Fri, 4 May 2018 14:50:54 +0000 (16:50 +0200)]
Upgrade submodule, sync patch and code.

* gdbtk/generic/gdbtk-cmds.c (gdb_clear_file): use exec_close () instead of
  exec_file_clear ().
  (gdb_stop): do not check to_stop in non null, since this is now handled by
  virtual methods.
  (gdb_entry_point): use *target_stack instead of current_target.
  (gdb_update_mem): likewise.
* gdbtk/generic/gdbtk.c (gdb_interactive): use *target_stack instead of
  current_target.
  (target_is_native): use method shortname () instead of member to_shortname.

6 years agoUpgrade submodule, sync code.
Patrick Monnerat [Mon, 30 Apr 2018 00:38:01 +0000 (02:38 +0200)]
Upgrade submodule, sync code.

* gdbtk/generic/gdbtk-hooks.c (gdbtk_file::read): declare as virtual override.
 (gdbtk_file::write): likewise.

6 years agoUpgrade submodule.
Patrick Monnerat [Sat, 21 Apr 2018 00:41:21 +0000 (02:41 +0200)]
Upgrade submodule.

6 years agoUpgrade submodule, sync patch.
Patrick Monnerat [Mon, 16 Apr 2018 22:39:23 +0000 (00:39 +0200)]
Upgrade submodule, sync patch.

6 years agoUpgrade submodule, adapt gdbtk code.
Patrick Monnerat [Sat, 7 Apr 2018 17:19:21 +0000 (19:19 +0200)]
Upgrade submodule, adapt gdbtk code.

* gdbtk/generic/gdbtk-varobj.c (variable_print): variable->value is now
  a value_ref_ptr, thus call get() method to obtain the struct value *.

6 years agoUpgrade submodule.
Patrick Monnerat [Fri, 30 Mar 2018 17:54:26 +0000 (19:54 +0200)]
Upgrade submodule.

6 years agoSimplify gdb patches.
Patrick Monnerat [Fri, 30 Mar 2018 17:43:35 +0000 (19:43 +0200)]
Simplify gdb patches.

Use C++ default parameter values for updated gdb functions to minimize
gdb code change.

* patches/binutils-gdb/006-add_file_handler_with_mode.patch: deleted.
* patches/binutils-gdb/006-add_file_handler_event_mask.patch: new.
* gdbtk/generic/gdbtk.c (gdbtk_notifier_create_file_handler): use
  add_file_handler instead of (deleted) add_file_handler_with_mode.

This page took 0.135347 seconds and 5 git commands to generate.