changeset 33062:406c7ef068af

Eliminate more instances of volatile keywoard missed in cset 147c69ad945d (bug #65321). * CSparse.cc: Delete keyword volatile before declaration of "rcond_plus_one" variable.
author Rik <rik@octave.org>
date Tue, 20 Feb 2024 13:41:10 -0800
parents 50e19b01e111
children d9ff240f1339
files liboctave/array/CSparse.cc
diffstat 1 files changed, 17 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/liboctave/array/CSparse.cc	Tue Feb 20 15:04:18 2024 -0500
+++ b/liboctave/array/CSparse.cc	Tue Feb 20 13:41:10 2024 -0800
@@ -5297,7 +5297,8 @@
                   if (err != 0)
                     err = -2;
 
-                  volatile double rcond_plus_one = rcond + 1.0;
+                  // Prevent use of extra precision.
+                  double rcond_plus_one = rcond + 1.0;
 
                   if (rcond_plus_one == 1.0 || octave::math::isnan (rcond))
                     {
@@ -5467,7 +5468,8 @@
                   if (err != 0)
                     err = -2;
 
-                  volatile double rcond_plus_one = rcond + 1.0;
+                  // Prevent use of extra precision.
+                  double rcond_plus_one = rcond + 1.0;
 
                   if (rcond_plus_one == 1.0 || octave::math::isnan (rcond))
                     {
@@ -5630,7 +5632,9 @@
         rcond = Info (UMFPACK_RCOND);
       else
         rcond = 1.;
-      volatile double rcond_plus_one = rcond + 1.0;
+
+      // Prevent use of extra precision.
+      double rcond_plus_one = rcond + 1.0;
 
       if (status == UMFPACK_WARNING_singular_matrix
           || rcond_plus_one == 1.0 || octave::math::isnan (rcond))
@@ -5780,7 +5784,8 @@
             }
           else
             {
-              volatile double rcond_plus_one = rcond + 1.0;
+              // Prevent use of extra precision.
+              double rcond_plus_one = rcond + 1.0;
 
               if (rcond_plus_one == 1.0 || octave::math::isnan (rcond))
                 {
@@ -6029,7 +6034,8 @@
             }
           else
             {
-              volatile double rcond_plus_one = rcond + 1.0;
+              // Prevent use of extra precision.
+              double rcond_plus_one = rcond + 1.0;
 
               if (rcond_plus_one == 1.0 || octave::math::isnan (rcond))
                 {
@@ -6311,7 +6317,8 @@
             }
           else
             {
-              volatile double rcond_plus_one = rcond + 1.0;
+              // Prevent use of extra precision.
+              double rcond_plus_one = rcond + 1.0;
 
               if (rcond_plus_one == 1.0 || octave::math::isnan (rcond))
                 {
@@ -6539,7 +6546,8 @@
             }
           else
             {
-              volatile double rcond_plus_one = rcond + 1.0;
+              // Prevent use of extra precision.
+              double rcond_plus_one = rcond + 1.0;
 
               if (rcond_plus_one == 1.0 || octave::math::isnan (rcond))
                 {
@@ -6674,7 +6682,8 @@
               retval.maybe_compress ();
 
               rcond = Info (UMFPACK_RCOND);
-              volatile double rcond_plus_one = rcond + 1.0;
+              // Prevent use of extra precision.
+              double rcond_plus_one = rcond + 1.0;
 
               if (status == UMFPACK_WARNING_singular_matrix
                   || rcond_plus_one == 1.0 || octave::math::isnan (rcond))