src/share/vm/runtime/sharedRuntimeMath.hpp

changeset 7003
69ea58782b1a
parent 7002
a073be2ce5c2
     1.1 --- a/src/share/vm/runtime/sharedRuntimeMath.hpp	Tue Jul 29 13:56:29 2014 +0200
     1.2 +++ b/src/share/vm/runtime/sharedRuntimeMath.hpp	Thu Jul 31 19:59:36 2014 +0200
     1.3 @@ -42,29 +42,34 @@
     1.4  } DoubleIntConv;
     1.5  
     1.6  static inline int high(double d) {
     1.7 -  DoubleIntConv x = { d };
     1.8 +  DoubleIntConv x;
     1.9 +  x.d = d;
    1.10    return x.split.hi;
    1.11  }
    1.12  
    1.13  static inline int low(double d) {
    1.14 -  DoubleIntConv x = { d };
    1.15 +  DoubleIntConv x;
    1.16 +  x.d = d;
    1.17    return x.split.lo;
    1.18  }
    1.19  
    1.20  static inline void set_high(double* d, int high) {
    1.21 -  DoubleIntConv conv = { *d };
    1.22 +  DoubleIntConv conv;
    1.23 +  conv.d = *d;
    1.24    conv.split.hi = high;
    1.25    *d = conv.d;
    1.26  }
    1.27  
    1.28  static inline void set_low(double* d, int low) {
    1.29 -  DoubleIntConv conv = { *d };
    1.30 +  DoubleIntConv conv;
    1.31 +  conv.d = *d;
    1.32    conv.split.lo = low;
    1.33    *d = conv.d;
    1.34  }
    1.35  
    1.36  static double copysignA(double x, double y) {
    1.37 -  DoubleIntConv convX = { x };
    1.38 +  DoubleIntConv convX;
    1.39 +  convX.d = x;
    1.40    convX.split.hi = (convX.split.hi & 0x7fffffff) | (high(y) & 0x80000000);
    1.41    return convX.d;
    1.42  }

mercurial