]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Make sure the x86 direction flag is cleared again if we set it as part
authorTom Hughes <tom@compton.nu>
Mon, 27 Jul 2009 23:09:42 +0000 (23:09 +0000)
committerTom Hughes <tom@compton.nu>
Mon, 27 Jul 2009 23:09:42 +0000 (23:09 +0000)
of a test, as the x86 requires it to be clear when any function is called
and gcc 4.3.0 and later rely on that. Fixes #201708.

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

none/tests/x86/bug152818-x86.c
none/tests/x86/gen_insn_test.pl

index 9fbe0e904d7fb7806fd42ecf3f9a168f961ef0b2..cda0bf995edd6d9aa3ff2d76c7cac6e309fdf317 100644 (file)
@@ -60,6 +60,7 @@ static void pp_eflags (unsigned int _8bits_eflags)
     "lahf       \t\n"                       \
     "movl %%eax, %1 \t\n"                       \
     "movl %%esi, %2 \t\n"                       \
+    "cld \t\n" \
     : "=d"(out_eax),                        \
       "=b"(out_eflags),                       \
       "=r"(out_esi)                         \
index d97eee8be30b91701277a808b23322c785fa253b..283583dc3e644a27c46bc5a77407ffec230db7c8 100644 (file)
@@ -809,7 +809,8 @@ while (<>)
     }
 
     print qq|         \"frstor %$stateargnum\\n\"\n|;
-
+    print qq|         \"cld\\n\"\n|;
+    
     print qq|         :|;
 
     $prefix = " ";