public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
* [SCM]  gbenson/pr14963: Strip the extra debug code I added
@ 2013-09-04 13:22 gary
  0 siblings, 0 replies; only message in thread
From: gary @ 2013-09-04 13:22 UTC (permalink / raw)
  To: archer-commits

The branch, gbenson/pr14963 has been updated
       via  1bd6e9d17a836b0b1e66090bd505ba094e93e91f (commit)
      from  a2511b1121c3e656e2a0c06b707442af2fa7ac73 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit 1bd6e9d17a836b0b1e66090bd505ba094e93e91f
Author: Gary Benson <gbenson@redhat.com>
Date:   Wed Sep 4 14:22:38 2013 +0100

    Strip the extra debug code I added

-----------------------------------------------------------------------

Summary of changes:
 libiberty/cp-demangle.c |   75 -----------------------------------------------
 1 files changed, 0 insertions(+), 75 deletions(-)

First 500 lines of diff:
diff --git a/libiberty/cp-demangle.c b/libiberty/cp-demangle.c
index d05dccd..559406d 100644
--- a/libiberty/cp-demangle.c
+++ b/libiberty/cp-demangle.c
@@ -276,18 +276,6 @@ struct d_growable_string
   int allocation_failure;
 };
 
-#define CP_DEMANGLE_DEBUG
-
-#ifdef CP_DEMANGLE_DEBUG
-struct d_check_stack_element
-{
-  /* XXX.  */
-  struct d_check_stack_element *next;
-  /* XXX.  */
-  const struct demangle_component *dc;
-};
-#endif
-
 enum { D_PRINT_BUFFER_LENGTH = 256 };
 struct d_print_info
 {
@@ -317,10 +305,6 @@ struct d_print_info
   unsigned long int flush_count;
   /* XXX.  */
   htab_t saved_scopes;
-#ifdef CP_DEMANGLE_DEBUG
-  /* XXX.  */
-  struct d_check_stack_element *check_stack;
-#endif
 };
 
 #ifdef CP_DEMANGLE_DEBUG
@@ -479,12 +463,6 @@ static inline char d_last_char (struct d_print_info *);
 static void
 d_print_comp (struct d_print_info *, int, const struct demangle_component *);
 
-#ifdef CP_DEMANGLE_DEBUG
-static void
-d_print_comp_inner (struct d_print_info *, int,
-		    const struct demangle_component *);
-#endif
-
 static void
 d_print_java_identifier (struct d_print_info *, const char *, int);
 
@@ -528,8 +506,6 @@ d_dump (struct demangle_component *dc, int indent)
       return;
     }
 
-  printf ("%p  ", dc);
-
   for (i = 0; i < indent; ++i)
     putchar (' ');
 
@@ -3460,9 +3436,6 @@ d_add_substitution (struct d_info *di, struct demangle_component *dc)
     return 0;
   if (di->next_sub >= di->num_subs)
     return 0;
-#ifdef CP_DEMANGLE_DEBUG
-  printf ("SUB %2d: %p\n", di->next_sub, dc);
-#endif
   di->subs[di->next_sub] = dc;
   ++di->next_sub;
   return 1;
@@ -3697,10 +3670,6 @@ d_print_init (struct d_print_info *dpi, demangle_callbackref callback,
   dpi->demangle_failure = 0;
 
   dpi->saved_scopes = NULL;
-
-#ifdef CP_DEMANGLE_DEBUG
-  dpi->check_stack = NULL;
-#endif
 }
 
 /* Free a print information structure.  */
@@ -3961,21 +3930,6 @@ d_print_subexpr (struct d_print_info *dpi, int options,
     d_append_char (dpi, ')');
 }
 
-#ifdef CP_DEMANGLE_DEBUG
-static void
-d_dump_check_stack (struct d_check_stack_element *elem,
-		    const struct demangle_component *highlight)
-{
-  if (elem->next != NULL)
-    d_dump_check_stack (elem->next, highlight);
-
-  printf ("%p", elem->dc);
-  if (elem->dc == highlight)
-    printf (" ***");
-  putchar ('\n');
-}
-#endif
-
 /* XXX.  */
 
 struct d_saved_scope
@@ -4076,34 +4030,6 @@ d_equal_saved_scope (const void *p1, const void *p2)
 static void
 d_print_comp (struct d_print_info *dpi, int options,
               const struct demangle_component *dc)
-#ifdef CP_DEMANGLE_DEBUG
-{
-  struct d_check_stack_element self, *check;
-
-  for (check = dpi->check_stack; check != NULL; check = check->next)
-    if (dc == check->dc)
-      {
-	puts ("\nINFINITE LOOP:");
-	d_dump_check_stack (dpi->check_stack, dc);
-	printf ("%p ***\n\n", dc);
-
-	d_print_error (dpi);
-	return;
-      }
-
-  self.next = dpi->check_stack;
-  dpi->check_stack = &self;
-  self.dc = dc;
-
-  d_print_comp_inner (dpi, options, dc);
-
-  dpi->check_stack = self.next;
-}
-
-static void
-d_print_comp_inner (struct d_print_info *dpi, int options,
-		    const struct demangle_component *dc)
-#endif /* CP_DEMANGLE_DEBUG */
 {
   /* Magic variable to let reference smashing skip over the next modifier
      without needing to modify *dc.  */
@@ -5658,7 +5584,6 @@ d_demangle_callback (const char *mangled, int options,
       dc = NULL;
 
 #ifdef CP_DEMANGLE_DEBUG
-    putchar ('\n');
     d_dump (dc, 0);
 #endif
 


hooks/post-receive
--
Repository for Project Archer.


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2013-09-04 13:22 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-04 13:22 [SCM] gbenson/pr14963: Strip the extra debug code I added 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).