2010-05-06 Michael Snyder <msnyder@vmware.com>
authorMichael Snyder <msnyder@vmware.com>
Fri, 7 May 2010 02:09:55 +0000 (02:09 +0000)
committerMichael Snyder <msnyder@vmware.com>
Fri, 7 May 2010 02:09:55 +0000 (02:09 +0000)
* xml-support.c (xinclude_start_include): Delete unused variable.
(xml_process_xincludes): Delete unused variable.
* xml-syscall.c (syscall_parse_xml): Delete unused variable.
* target-descriptions.c (tdesc_gdb_type): Delete unused variable.
(tdesc_find_arch_register): Delete unused variable.
(tdesc_use_registers): Delete unused variable.
* xml-tdesc.c (tdesc_start_target): Delete unused variable.
* inferior.c (print_inferior): Delete unused variable.
* record.c (record_open_1): Delete unused variable.
(record_restore): Delete unused variable.
(cmd_record_save): Delete unused variable.
* gcore.c (derive_heap_segment): Delete unused variable.
(objfile_find_memory_regions): Use unused variable.
* jit.c (jit_inferior_init): Delete unused variable.
* progspace.c (clone_program_space): Delete unused variable.
(pspace_empty_p): Delete unused variable.

gdb/ChangeLog
gdb/gcore.c
gdb/inferior.c
gdb/jit.c
gdb/progspace.c
gdb/record.c
gdb/target-descriptions.c
gdb/xml-support.c
gdb/xml-syscall.c
gdb/xml-tdesc.c

index edfcd65a64ccf4e345547504b792e5fca64006c2..c3649a83fc303ae39bb01bef0e14a5063c9d46a0 100644 (file)
@@ -1,5 +1,22 @@
 2010-05-06  Michael Snyder  <msnyder@vmware.com>
 
+       * xml-support.c (xinclude_start_include): Delete unused variable.
+       (xml_process_xincludes): Delete unused variable.
+       * xml-syscall.c (syscall_parse_xml): Delete unused variable.
+       * target-descriptions.c (tdesc_gdb_type): Delete unused variable.
+       (tdesc_find_arch_register): Delete unused variable.
+       (tdesc_use_registers): Delete unused variable.
+       * xml-tdesc.c (tdesc_start_target): Delete unused variable.
+       * inferior.c (print_inferior): Delete unused variable.
+       * record.c (record_open_1): Delete unused variable.
+       (record_restore): Delete unused variable.
+       (cmd_record_save): Delete unused variable.
+       * gcore.c (derive_heap_segment): Delete unused variable.
+       (objfile_find_memory_regions): Use unused variable.
+       * jit.c (jit_inferior_init): Delete unused variable.
+       * progspace.c (clone_program_space): Delete unused variable.
+       (pspace_empty_p): Delete unused variable.
+       
        * frame-unwind.c (frame_unwind_find_by_frame): 
        Delete unused variable.
        * gnu-v2-abi.c (gnuv2_value_rtti_type): Delete unused variable.
index d8e7ed44f16bff01aacb19350cc820bdf49d721d..5c5816c033be4acdee31fe5318838ce0dda36720 100644 (file)
@@ -300,7 +300,6 @@ call_target_sbrk (int sbrk_arg)
 static int
 derive_heap_segment (bfd *abfd, bfd_vma *bottom, bfd_vma *top)
 {
-  struct gdbarch *gdbarch;
   bfd_vma top_of_data_memory = 0;
   bfd_vma top_of_heap = 0;
   bfd_size_type sec_size;
@@ -476,14 +475,13 @@ objfile_find_memory_regions (int (*func) (CORE_ADDR, unsigned long,
       bfd *ibfd = objfile->obfd;
       asection *isec = objsec->the_bfd_section;
       flagword flags = bfd_get_section_flags (ibfd, isec);
-      int ret;
 
       if ((flags & SEC_ALLOC) || (flags & SEC_LOAD))
        {
          int size = bfd_section_size (ibfd, isec);
          int ret;
 
-         ret = (*func) (obj_section_addr (objsec), bfd_section_size (ibfd, isec),
+         ret = (*func) (obj_section_addr (objsec), size, 
                         1, /* All sections will be readable.  */
                         (flags & SEC_READONLY) == 0, /* Writable.  */
                         (flags & SEC_CODE) != 0, /* Executable.  */
index f1991c97381077c4088c9f2c54c1fa3dcb8c7dfc..a48972140b25bb072833cc1cfe353f202223737a 100644 (file)
@@ -527,8 +527,6 @@ print_inferior (struct ui_out *uiout, int requested_inferior)
   /* Compute number of inferiors we will print.  */
   for (inf = inferior_list; inf; inf = inf->next)
     {
-      struct cleanup *chain2;
-
       if (requested_inferior != -1 && inf->num != requested_inferior)
        continue;
 
index e17f0ab78aba31e58fef424c0b47410240e86289..42ef8efb5cad4ecb01f0c3eb06fb178ec2891688 100644 (file)
--- a/gdb/jit.c
+++ b/gdb/jit.c
@@ -313,7 +313,6 @@ jit_inferior_init (struct gdbarch *gdbarch)
   struct jit_descriptor descriptor;
   struct jit_code_entry cur_entry;
   CORE_ADDR cur_entry_addr;
-  struct cleanup *old_cleanups;
 
   /* When we register code, GDB resets its breakpoints in case symbols have
      changed.  That in turn calls this handler, which makes us look for new
index 42139fd4599e3bcc7f6bcfe7d3b5a64ed6162bfd..5a2acfd59029d10d512548af39d103d0247d6dfb 100644 (file)
@@ -186,7 +186,6 @@ remove_program_space (struct program_space *pspace)
 struct program_space *
 clone_program_space (struct program_space *dest, struct program_space *src)
 {
-  struct program_space *new_pspace;
   struct cleanup *old_chain;
 
   old_chain = save_current_program_space ();
@@ -248,8 +247,6 @@ save_current_program_space (void)
 static int
 pspace_empty_p (struct program_space *pspace)
 {
-  struct inferior *inf;
-
   if (find_inferior_for_program_space (pspace) != NULL)
       return 0;
 
index fa6cfbbee89d99364cc4a15c86ba9c273e93f0bc..8da10d46944c1b8b382a859065e658fc2206ea76 100644 (file)
@@ -838,8 +838,6 @@ record_core_open_1 (char *name, int from_tty)
 static void
 record_open_1 (char *name, int from_tty)
 {
-  struct target_ops *t;
-
   if (record_debug)
     fprintf_unfiltered (gdb_stdlog, "Process record: record_open\n");
 
@@ -2174,7 +2172,6 @@ record_restore (void)
 
   while (1)
     {
-      int ret;
       uint8_t rectype;
       uint32_t regnum, len, signal, count;
       uint64_t addr;
@@ -2333,7 +2330,6 @@ static void
 cmd_record_save (char *args, int from_tty)
 {
   char *recfilename, recfilename_buffer[40];
-  int recfd;
   struct record_entry *cur_record_list;
   uint32_t magic;
   struct regcache *regcache;
index 86adc9d6beeb459057bca87a04390a53ebfd5dd6..874730f5b24fd6425f2b7f39762b5ee197c4a39b 100644 (file)
@@ -702,7 +702,6 @@ tdesc_gdb_type (struct gdbarch *gdbarch, struct tdesc_type *tdesc_type)
 
     case TDESC_TYPE_FLAGS:
       {
-       struct type *type, *field_type;
        struct tdesc_type_flag *f;
        int ix;
 
@@ -852,7 +851,6 @@ tdesc_register_size (const struct tdesc_feature *feature,
 static struct tdesc_arch_reg *
 tdesc_find_arch_register (struct gdbarch *gdbarch, int regno)
 {
-  struct tdesc_arch_reg *reg;
   struct tdesc_arch_data *data;
 
   data = gdbarch_data (gdbarch, tdesc_data);
@@ -1091,7 +1089,7 @@ tdesc_use_registers (struct gdbarch *gdbarch,
                     struct tdesc_arch_data *early_data)
 {
   int num_regs = gdbarch_num_regs (gdbarch);
-  int i, ixf, ixr;
+  int ixf, ixr;
   struct tdesc_feature *feature;
   struct tdesc_reg *reg;
   struct tdesc_arch_data *data;
index bc134f11fc0f667f7ad64087366426bcf7fc7e99..a8dbc519ae8b23384203238d28055c690d2af153 100644 (file)
@@ -720,7 +720,6 @@ xinclude_start_include (struct gdb_xml_parser *parser,
   char *href = VEC_index (gdb_xml_value_s, attributes, 0)->value;
   struct cleanup *back_to;
   char *text, *output;
-  int ret;
 
   gdb_xml_debug (parser, _("Processing XInclude of \"%s\""), href);
 
@@ -832,7 +831,6 @@ xml_process_xincludes (const char *name, const char *text,
                       xml_fetch_another fetcher, void *fetcher_baton,
                       int depth)
 {
-  enum XML_Error err;
   struct gdb_xml_parser *parser;
   struct xinclude_parsing_data *data;
   struct cleanup *back_to;
index 2a4d010bf28ca5f5d0122fc517ba84757a7647a5..0dc223987bd1a88484b05173e109b6899804bc95 100644 (file)
@@ -237,8 +237,6 @@ syscall_parse_xml (const char *document, xml_fetch_another fetcher,
   struct cleanup *result_cleanup;
   struct gdb_xml_parser *parser;
   struct syscall_parsing_data data;
-  char *expanded_text;
-  int i;
 
   parser = gdb_xml_create_parser_and_cleanup (_("syscalls info"),
                                              syselements, &data);
index 1d78cad33ccdf3ce43475e8e64caef5cafa431dd..ca60ffb411433b524c1aa18c5ae4144dd0ca9aaa 100644 (file)
@@ -152,7 +152,6 @@ tdesc_start_target (struct gdb_xml_parser *parser,
                    const struct gdb_xml_element *element,
                    void *user_data, VEC(gdb_xml_value_s) *attributes)
 {
-  struct tdesc_parsing_data *data = user_data;
   char *version = VEC_index (gdb_xml_value_s, attributes, 0)->value;
 
   if (strcmp (version, "1.0") != 0)