public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
* [SCM] archer-gbenson-stap-rtld-mainline: Recover from bad push
@ 2013-02-07 12:10 gary
0 siblings, 0 replies; only message in thread
From: gary @ 2013-02-07 12:10 UTC (permalink / raw)
To: archer-commits
The branch, archer-gbenson-stap-rtld-mainline has been updated
via 7230d07de7987c95ac47cd808f0ae9cee9c4dbf7 (commit)
from 51102a7374742ccea7c69171d2c8eaf63e1273a0 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email.
- Log -----------------------------------------------------------------
commit 7230d07de7987c95ac47cd808f0ae9cee9c4dbf7
Author: Gary Benson <gbenson@redhat.com>
Date: Thu Feb 7 12:07:35 2013 +0000
Recover from bad push
-----------------------------------------------------------------------
Summary of changes:
gdb/breakpoint.h | 2 -
gdb/solib-svr4.c | 33 +++++++++++++-----------
gdb/solib.c | 71 +++++++++++++++++++++++++++--------------------------
3 files changed, 54 insertions(+), 52 deletions(-)
First 500 lines of diff:
diff --git a/gdb/breakpoint.h b/gdb/breakpoint.h
index 7a2c629..946f57a 100644
--- a/gdb/breakpoint.h
+++ b/gdb/breakpoint.h
@@ -1552,8 +1552,6 @@ extern int user_breakpoint_p (struct breakpoint *);
/* Attempt to determine architecture of location identified by SAL. */
extern struct gdbarch *get_sal_arch (struct symtab_and_line sal);
-extern void handle_solib_event (void);
-
extern void breakpoint_free_objfile (struct objfile *objfile);
#endif /* !defined (BREAKPOINT_H) */
diff --git a/gdb/solib-svr4.c b/gdb/solib-svr4.c
index 1706bfc..07670b0 100644
--- a/gdb/solib-svr4.c
+++ b/gdb/solib-svr4.c
@@ -119,23 +119,23 @@ static const char * const main_name_list[] =
NULL
};
-/* Actions to take at solib event breakpoint stops. */
+/* What to do with the namespace table when a probe stop occurs. */
enum probe_action
{
/* Something went seriously wrong. Stop using probes and
- revert to the older interface. */
+ revert to using the older interface. */
NAMESPACE_TABLE_INVALIDATE,
- /* No action is required at this stop. */
+ /* No action is required. This namespace is still valid. */
NAMESPACE_NO_ACTION,
- /* The specified namespace should be reloaded entirely. */
+ /* This namespace should be reloaded entirely. */
NAMESPACE_RELOAD,
- /* Attempt to incrementally update the specified namespace.
- If the update fails or is not possible, fall back to
- reloading the namespace in full. */
+ /* Attempt to incrementally update this namespace. If the
+ update fails or is not possible, fall back to reloading
+ the namespace in full. */
NAMESPACE_UPDATE_OR_RELOAD,
};
@@ -174,7 +174,7 @@ struct svr4_info
CORE_ADDR debug_base; /* Base of dynamic linker structures. */
/* Validity flag for debug_loader_offset. */
- unsigned int debug_loader_offset_p : 1;
+ int debug_loader_offset_p;
/* Load address for the dynamic linker, inferred. */
CORE_ADDR debug_loader_offset;
@@ -1422,14 +1422,10 @@ svr4_current_sos_from_debug_base (void)
static struct so_list *
svr4_current_sos (void)
{
- struct svr4_info *info = get_svr4_info ();
+ struct svr4_info *info;
struct svr4_library_list library_list;
struct so_list *result;
- /* If we have a namespace table then return a flattened copy. */
- if (info->namespace_table != NULL)
- return namespace_table_flatten (info->namespace_table);
-
/* Fall back to manual examination of the target if the packet is not
supported or gdbserver failed to find DT_DEBUG. gdb.server/solib-list.exp
tests a case where gdbserver cannot find the shared libraries list while
@@ -1449,6 +1445,12 @@ svr4_current_sos (void)
return library_list.head ? library_list.head : svr4_default_sos ();
}
+ info = get_svr4_info ();
+
+ /* If we have a namespace table then return a flattened copy. */
+ if (info->namespace_table != NULL)
+ return namespace_table_flatten (info->namespace_table);
+
/* Always locate the debug struct, in case it has moved. */
info->debug_base = 0;
locate_base (info);
@@ -1581,7 +1583,8 @@ equal_probe_and_action (const void *p1, const void *p2)
return pa1->probe->address == pa2->probe->address;
}
-/* XXX. */
+/* Register a solib event probe and its associated action in the
+ probes table. */
static void
register_solib_event_probe (struct probe *probe, enum probe_action action)
@@ -2038,7 +2041,7 @@ svr4_update_solib_event_breakpoints (void)
iterate_over_breakpoints (svr4_update_solib_event_breakpoint, NULL);
}
-/* XXX. */
+/* Create and register solib event breakpoints. */
static void
svr4_create_probe_breakpoints (struct gdbarch *gdbarch,
diff --git a/gdb/solib.c b/gdb/solib.c
index 08e710d..39eb38b 100644
--- a/gdb/solib.c
+++ b/gdb/solib.c
@@ -1206,6 +1206,42 @@ no_shared_libraries (char *ignored, int from_tty)
objfile_purge_solibs ();
}
+/* See solib.h. */
+
+void
+update_solib_breakpoints (void)
+{
+ struct target_so_ops *ops = solib_ops (target_gdbarch ());
+
+ if (ops->update_breakpoints != NULL)
+ ops->update_breakpoints ();
+}
+
+/* See solib.h. */
+
+void
+handle_solib_event (void)
+{
+ struct target_so_ops *ops = solib_ops (target_gdbarch ());
+
+ if (ops->handle_event != NULL)
+ ops->handle_event ();
+
+ clear_program_space_solib_cache (current_inferior ()->pspace);
+
+ /* Check for any newly added shared libraries if we're supposed to
+ be adding them automatically. Switch terminal for any messages
+ produced by breakpoint_re_set. */
+ target_terminal_ours_for_output ();
+#ifdef SOLIB_ADD
+ SOLIB_ADD (NULL, 0, ¤t_target, auto_solib_add);
+#else
+ solib_add (NULL, 0, ¤t_target, auto_solib_add);
+#endif
+ target_terminal_inferior ();
+}
+
+
/* Reload shared libraries, but avoid reloading the same symbol file
we already have loaded. */
@@ -1448,41 +1484,6 @@ gdb_bfd_lookup_symbol (bfd *abfd,
return symaddr;
}
-/* See solib.h. */
-
-void
-update_solib_breakpoints (void)
-{
- struct target_so_ops *ops = solib_ops (target_gdbarch ());
-
- if (ops->update_breakpoints != NULL)
- ops->update_breakpoints ();
-}
-
-/* See solib.h. */
-
-void
-handle_solib_event (void)
-{
- struct target_so_ops *ops = solib_ops (target_gdbarch ());
-
- if (ops->handle_event != NULL)
- ops->handle_event ();
-
- clear_program_space_solib_cache (current_inferior ()->pspace);
-
- /* Check for any newly added shared libraries if we're supposed to
- be adding them automatically. Switch terminal for any messages
- produced by breakpoint_re_set. */
- target_terminal_ours_for_output ();
-#ifdef SOLIB_ADD
- SOLIB_ADD (NULL, 0, ¤t_target, auto_solib_add);
-#else
- solib_add (NULL, 0, ¤t_target, auto_solib_add);
-#endif
- target_terminal_inferior ();
-}
-
extern initialize_file_ftype _initialize_solib; /* -Wmissing-prototypes */
void
hooks/post-receive
--
Repository for Project Archer.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2013-02-07 12:10 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-07 12:10 [SCM] archer-gbenson-stap-rtld-mainline: Recover from bad push gary
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).