]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Yesterday's push/pop merging optimisations break the cache profiler:
authorJulian Seward <jseward@acm.org>
Wed, 8 May 2002 21:26:01 +0000 (21:26 +0000)
committerJulian Seward <jseward@acm.org>
Wed, 8 May 2002 21:26:01 +0000 (21:26 +0000)
    vg_cachesim.c:536 (vgPlain_cachesim_instrument):
    Assertion `instr_size >= 1 && instr_size <= 16' failed.
so disable them when cache profiling.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@238

coregrind/vg_to_ucode.c
vg_to_ucode.c

index de1c066ad286a56c51ef33ab1880e4a85025cad7..e354e93ead04aeefeaf92d270a6e7abe3d61223c 100644 (file)
@@ -3714,7 +3714,8 @@ static Addr disInstr ( UCodeBlock* cb, Addr eip, Bool* isEnd )
     { Int   n_pops;
       Addr  eipS, eipE;
       UChar ch;
-      if (sz != 4) goto normal_pop_case;
+      if (sz != 4)           goto normal_pop_case;
+      if (VG_(clo_cachesim)) goto normal_pop_case;
       /* eip points at first pop insn + 1.  Make eipS and eipE
          bracket the sequence. */
       eipE = eipS = eip - 1;
@@ -3823,7 +3824,8 @@ static Addr disInstr ( UCodeBlock* cb, Addr eip, Bool* isEnd )
     { Int   n_pushes;
       Addr  eipS, eipE;
       UChar ch;
-      if (sz != 4) goto normal_push_case;
+      if (sz != 4)           goto normal_push_case;
+      if (VG_(clo_cachesim)) goto normal_push_case;
       /* eip points at first push insn + 1.  Make eipS and eipE
          bracket the sequence. */
       eipE = eipS = eip - 1;
index de1c066ad286a56c51ef33ab1880e4a85025cad7..e354e93ead04aeefeaf92d270a6e7abe3d61223c 100644 (file)
@@ -3714,7 +3714,8 @@ static Addr disInstr ( UCodeBlock* cb, Addr eip, Bool* isEnd )
     { Int   n_pops;
       Addr  eipS, eipE;
       UChar ch;
-      if (sz != 4) goto normal_pop_case;
+      if (sz != 4)           goto normal_pop_case;
+      if (VG_(clo_cachesim)) goto normal_pop_case;
       /* eip points at first pop insn + 1.  Make eipS and eipE
          bracket the sequence. */
       eipE = eipS = eip - 1;
@@ -3823,7 +3824,8 @@ static Addr disInstr ( UCodeBlock* cb, Addr eip, Bool* isEnd )
     { Int   n_pushes;
       Addr  eipS, eipE;
       UChar ch;
-      if (sz != 4) goto normal_push_case;
+      if (sz != 4)           goto normal_push_case;
+      if (VG_(clo_cachesim)) goto normal_push_case;
       /* eip points at first push insn + 1.  Make eipS and eipE
          bracket the sequence. */
       eipE = eipS = eip - 1;