]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* target.c (memory_xfer_partial): Don't use the stack cache if
authorPedro Alves <palves@redhat.com>
Fri, 12 Mar 2010 03:56:31 +0000 (03:56 +0000)
committerPedro Alves <palves@redhat.com>
Fri, 12 Mar 2010 03:56:31 +0000 (03:56 +0000)
inspecting trace frames.
* tracepoint.c (finish_tfind_command): Invalidate the target
dcache.

gdb/ChangeLog
gdb/target.c
gdb/tracepoint.c

index 991d3c881a6d422c869185c8d5ba9ecab2b15e68..3334cece8edbeea34153031165b58e9a141adade 100644 (file)
@@ -1,3 +1,10 @@
+2010-03-12  Pedro Alves  <pedro@codesourcery.com>
+
+       * target.c (memory_xfer_partial): Don't use the stack cache if
+       inspecting trace frames.
+       * tracepoint.c (finish_tfind_command): Invalidate the target
+       dcache.
+
 2010-03-10  Pierre Muller  <muller@ics.u-strasbg.fr>
 
        * p-lang.c (is_pascal_string_type): Check that TYPE arg is non NULL.
index e6659c9aac460ca709e364cee82935d367f164f2..8ca4320367cf17d8301633a49cc40f7a54f08c42 100644 (file)
@@ -43,6 +43,7 @@
 #include "solib.h"
 #include "exec.h"
 #include "inline-frame.h"
+#include "tracepoint.h"
 
 static void target_info (char *, int);
 
@@ -1292,6 +1293,10 @@ memory_xfer_partial (struct target_ops *ops, enum target_object object,
     inf = NULL;
 
   if (inf != NULL
+      /* The dcache reads whole cache lines; that doesn't play well
+        with reading from a trace buffer, because reading outside of
+        the collected memory range fails.  */
+      && get_traceframe_number () == -1
       && (region->attrib.cache
          || (stack_cache_enabled_p && object == TARGET_OBJECT_STACK_MEMORY)))
     {
index 1d2785f7f78c1c121a4a1644a4f7b6e4ddd219d3..4d85a89d404e29fe74f09e3d77b9a2839342d87d 100644 (file)
@@ -1746,6 +1746,7 @@ finish_tfind_command (enum trace_find_type type, int num,
 
   reinit_frame_cache ();
   registers_changed ();
+  target_dcache_invalidate ();
   set_traceframe_num (target_frameno);
   set_tracepoint_num (tp ? tp->number : target_tracept);
   if (target_frameno == -1)