]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Silence a few warnings issued by GCC 5.1 claiming that 'res' is
authorFlorian Krohm <florian@eich-krohm.de>
Sun, 2 Aug 2015 19:35:49 +0000 (19:35 +0000)
committerFlorian Krohm <florian@eich-krohm.de>
Sun, 2 Aug 2015 19:35:49 +0000 (19:35 +0000)
uninitialised. Perhaps an incorrect clobber or a compiler bug?
Anyhow, initialising the variable will do the trick.

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

memcheck/tests/x86/fprem.c

index 864c9b076bf321098ae40a853b49d7cc945e930f..c6cd74808e46d349faabf7c0c19dd62cd68b7f72 100644 (file)
@@ -6,7 +6,7 @@
 
 double do_fprem ( void )
 {
-  double res;
+  double res = 0.0;
   __asm__ __volatile__(
     "ffree %%st(0)\n\t"
     "ffree %%st(1)\n\t"
@@ -21,7 +21,7 @@ double do_fprem ( void )
 
 double do_fprem1 ( void )
 {
-  double res;
+  double res = 0.0;
   __asm__ __volatile__(
     "ffree %%st(0)\n\t"
     "ffree %%st(1)\n\t"
@@ -36,7 +36,7 @@ double do_fprem1 ( void )
 
 double do_fsincos ( void )
 {
-  double res;
+  double res = 0.0;
   __asm__ __volatile__(
     "fldln2\n\t"
     "fsincos\n\t"