public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
* [SCM]  archer-jankratochvil-vla: Fix a regression on gdb.pascal/arrays.exp.
@ 2011-01-15 16:26 jkratoch
  0 siblings, 0 replies; only message in thread
From: jkratoch @ 2011-01-15 16:26 UTC (permalink / raw)
  To: archer-commits

The branch, archer-jankratochvil-vla has been updated
       via  bb4cba229f5dd5ca8e9ce367644e04a45cd1bc3e (commit)
      from  eb6132fc212249096d1a4e66decba99bd7c04bcd (commit)

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

- Log -----------------------------------------------------------------
commit bb4cba229f5dd5ca8e9ce367644e04a45cd1bc3e
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Sat Jan 15 17:26:27 2011 +0100

    Fix a regression on gdb.pascal/arrays.exp.

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

Summary of changes:
 gdb/findvar.c  |    8 +-------
 gdb/gdbtypes.c |    3 ++-
 2 files changed, 3 insertions(+), 8 deletions(-)

First 500 lines of diff:
diff --git a/gdb/findvar.c b/gdb/findvar.c
index 198e100..951c2fe 100644
--- a/gdb/findvar.c
+++ b/gdb/findvar.c
@@ -452,7 +452,6 @@ read_var_value (struct symbol *var, struct frame_info *frame)
       return v;
 
     case LOC_STATIC:
-      v = allocate_value_lazy (type);
       if (overlay_debugging)
 	addr = symbol_overlayed_address (SYMBOL_VALUE_ADDRESS (var),
 					 SYMBOL_OBJ_SECTION (var));
@@ -465,7 +464,6 @@ read_var_value (struct symbol *var, struct frame_info *frame)
       if (!addr)
 	return 0;
       addr += SYMBOL_VALUE (var);
-      v = allocate_value_lazy (type);
       break;
 
     case LOC_REF_ARG:
@@ -479,14 +477,12 @@ read_var_value (struct symbol *var, struct frame_info *frame)
 	argref += SYMBOL_VALUE (var);
 	ref = value_at (lookup_pointer_type (type), argref);
 	addr = value_as_address (ref);
-	v = allocate_value_lazy (type);
 	break;
       }
 
     case LOC_LOCAL:
       addr = get_frame_locals_address (frame);
       addr += SYMBOL_VALUE (var);
-      v = allocate_value_lazy (type);
       break;
 
     case LOC_TYPEDEF:
@@ -494,7 +490,6 @@ read_var_value (struct symbol *var, struct frame_info *frame)
       break;
 
     case LOC_BLOCK:
-      v = allocate_value_lazy (type);
       if (overlay_debugging)
 	addr = symbol_overlayed_address
 	  (BLOCK_START (SYMBOL_BLOCK_VALUE (var)), SYMBOL_OBJ_SECTION (var));
@@ -519,7 +514,6 @@ read_var_value (struct symbol *var, struct frame_info *frame)
 	      error (_("Value of register variable not available."));
 
 	    addr = value_as_address (regval);
-	    v = allocate_value_lazy (type);
 	  }
 	else
 	  {
@@ -558,7 +552,6 @@ read_var_value (struct symbol *var, struct frame_info *frame)
 	if (obj_section
 	    && (obj_section->the_bfd_section->flags & SEC_THREAD_LOCAL) != 0)
 	  addr = target_translate_tls_address (obj_section->objfile, addr);
-	v = allocate_value_lazy (type);
       }
       break;
 
@@ -576,6 +569,7 @@ read_var_value (struct symbol *var, struct frame_info *frame)
   /* ADDR is set here for ALLOCATE_VALUE's CHECK_TYPEDEF for
      DW_OP_PUSH_OBJECT_ADDRESS.  */
   object_address_set (addr);
+  v = allocate_value_lazy (type);
   VALUE_LVAL (v) = lval_memory;
   set_value_address (v, addr);
   return v;
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
index b353f9d..5348702 100644
--- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c
@@ -945,7 +945,8 @@ create_array_type (struct type *result_type,
      DW_OP_PUSH_OBJECT_ADDRESS not being available during the
      CREATE_ARRAY_TYPE time.  */
   if (TYPE_RANGE_DATA (range_type)->low.kind != RANGE_BOUND_KIND_CONSTANT
-      || TYPE_RANGE_DATA (range_type)->high.kind != RANGE_BOUND_KIND_CONSTANT)
+      || TYPE_RANGE_DATA (range_type)->high.kind != RANGE_BOUND_KIND_CONSTANT
+      || TYPE_DYNAMIC (element_type))
     TYPE_LENGTH (result_type) = 0;
   else
     {


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


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

only message in thread, other threads:[~2011-01-15 16:26 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-01-15 16:26 [SCM] archer-jankratochvil-vla: Fix a regression on gdb.pascal/arrays.exp jkratoch

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).