Mercurial > hg > graal-compiler
comparison src/share/vm/runtime/sharedRuntimeTrig.cpp @ 14411:bdd155477289
8023033: PPC64 (part 13): basic changes for AIX
Summary: Added AIX includes alpha-sorted before BSD. Fix compilation issues with xlC in shared code. Basic shared platform dependend adaption (vm_version etc.).
Reviewed-by: kvn, dholmes, stefank
author | goetz |
---|---|
date | Thu, 22 Aug 2013 09:39:54 -0700 |
parents | f95d63e2154a |
children | 8a9bb7821e28 631c3a4ea10c |
comparison
equal
deleted
inserted
replaced
14410:f42f2e2a1518 | 14411:bdd155477289 |
---|---|
656 C5 = 2.08757232129817482790e-09, /* 0x3E21EE9E, 0xBDB4B1C4 */ | 656 C5 = 2.08757232129817482790e-09, /* 0x3E21EE9E, 0xBDB4B1C4 */ |
657 C6 = -1.13596475577881948265e-11; /* 0xBDA8FAE9, 0xBE8838D4 */ | 657 C6 = -1.13596475577881948265e-11; /* 0xBDA8FAE9, 0xBE8838D4 */ |
658 | 658 |
659 static double __kernel_cos(double x, double y) | 659 static double __kernel_cos(double x, double y) |
660 { | 660 { |
661 double a,hz,z,r,qx; | 661 double a,h,z,r,qx; |
662 int ix; | 662 int ix; |
663 ix = __HI(x)&0x7fffffff; /* ix = |x|'s high word*/ | 663 ix = __HI(x)&0x7fffffff; /* ix = |x|'s high word*/ |
664 if(ix<0x3e400000) { /* if x < 2**27 */ | 664 if(ix<0x3e400000) { /* if x < 2**27 */ |
665 if(((int)x)==0) return one; /* generate inexact */ | 665 if(((int)x)==0) return one; /* generate inexact */ |
666 } | 666 } |
673 qx = 0.28125; | 673 qx = 0.28125; |
674 } else { | 674 } else { |
675 __HI(qx) = ix-0x00200000; /* x/4 */ | 675 __HI(qx) = ix-0x00200000; /* x/4 */ |
676 __LO(qx) = 0; | 676 __LO(qx) = 0; |
677 } | 677 } |
678 hz = 0.5*z-qx; | 678 h = 0.5*z-qx; |
679 a = one-qx; | 679 a = one-qx; |
680 return a - (hz - (z*r-x*y)); | 680 return a - (h - (z*r-x*y)); |
681 } | 681 } |
682 } | 682 } |
683 | 683 |
684 /* __kernel_tan( x, y, k ) | 684 /* __kernel_tan( x, y, k ) |
685 * kernel tan function on [-pi/4, pi/4], pi/4 ~ 0.7854 | 685 * kernel tan function on [-pi/4, pi/4], pi/4 ~ 0.7854 |