]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Use fxsave64 and fxrstor64 mnemonics instead of old-school rex64 prefix
authorRhys Kidd <rhyskidd@gmail.com>
Sat, 9 May 2015 23:32:13 +0000 (23:32 +0000)
committerRhys Kidd <rhyskidd@gmail.com>
Sat, 9 May 2015 23:32:13 +0000 (23:32 +0000)
bz#339636

Before:

== 591 tests, 232 stderr failures, 22 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

After:

== 591 tests, 232 stderr failures, 22 stdout failures, 0 stderrB failures, 0 stdoutB failures, 30 post failures ==

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

NEWS
memcheck/tests/amd64/fxsave-amd64.c

diff --git a/NEWS b/NEWS
index 89a2c3d52aa600333ea6c7fac502648c6bca5448..4d88267914a5a7e504fa3a5036289239c7ae60d5 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -87,6 +87,7 @@ where XXXXXX is the bug number as listed below.
 339288  support Cavium Octeon MIPS specific BBIT*32 instructions
 339442  Fix testsuite build failure on OS X 10.9
 339542  Enable compilation with Intel's ICC compiler
+339636  Use fxsave64 and fxrstor64 mnemonics instead of old-school rex64 prefix 
 339688  Mac-specific ASM does not support .version directive (cpuid,
         tronical and pushfpopf tests)
 339745  Valgrind crash when check Marmalade app (partial fix)
index 49281dd8e4dea23752f30084853f6750594ee511..de0403763d38c4ce6ccf2513e9a00a87735a143e 100644 (file)
@@ -17,7 +17,11 @@ const unsigned int vecZ[4]
 __attribute__((noinline))
 void do_fxsave ( void* p, int rexw ) {
    if (rexw) {
+#if defined(VGO_linux)
+      asm __volatile__("fxsave64 (%0)" : : "r" (p) : "memory" );
+#else
       asm __volatile__("rex64/fxsave (%0)" : : "r" (p) : "memory" );
+#endif
    } else {
       asm __volatile__("fxsave (%0)" : : "r" (p) : "memory" );
    }
@@ -26,7 +30,11 @@ void do_fxsave ( void* p, int rexw ) {
 __attribute__((noinline))
 void do_fxrstor ( void* p, int rexw ) {
    if (rexw) {
+#if defined(VGO_linux)
+      asm __volatile__("fxrstor64 (%0)" : : "r" (p) : "memory" );
+#else
       asm __volatile__("rex64/fxrstor (%0)" : : "r" (p) : "memory" );
+#endif
    } else {
       asm __volatile__("fxrstor (%0)" : : "r" (p) : "memory" );
    }