Mercurial > hg > graal-compiler
comparison src/share/vm/runtime/sharedRuntimeTrans.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 |
---|---|
54 #else | 54 #else |
55 # define __HI(x) *(int*)&x | 55 # define __HI(x) *(int*)&x |
56 # define __LO(x) *(1+(int*)&x) | 56 # define __LO(x) *(1+(int*)&x) |
57 #endif | 57 #endif |
58 | 58 |
59 #if !defined(AIX) | |
59 double copysign(double x, double y) { | 60 double copysign(double x, double y) { |
60 __HI(x) = (__HI(x)&0x7fffffff)|(__HI(y)&0x80000000); | 61 __HI(x) = (__HI(x)&0x7fffffff)|(__HI(y)&0x80000000); |
61 return x; | 62 return x; |
62 } | 63 } |
64 #endif | |
63 | 65 |
64 /* | 66 /* |
65 * ==================================================== | 67 * ==================================================== |
66 * Copyright (c) 1998 Oracle and/or its affiliates. All rights reserved. | 68 * Copyright (c) 1998 Oracle and/or its affiliates. All rights reserved. |
67 * | 69 * |
83 two54 = 1.80143985094819840000e+16, /* 0x43500000, 0x00000000 */ | 85 two54 = 1.80143985094819840000e+16, /* 0x43500000, 0x00000000 */ |
84 twom54 = 5.55111512312578270212e-17, /* 0x3C900000, 0x00000000 */ | 86 twom54 = 5.55111512312578270212e-17, /* 0x3C900000, 0x00000000 */ |
85 hugeX = 1.0e+300, | 87 hugeX = 1.0e+300, |
86 tiny = 1.0e-300; | 88 tiny = 1.0e-300; |
87 | 89 |
90 #if !defined(AIX) | |
88 double scalbn (double x, int n) { | 91 double scalbn (double x, int n) { |
89 int k,hx,lx; | 92 int k,hx,lx; |
90 hx = __HI(x); | 93 hx = __HI(x); |
91 lx = __LO(x); | 94 lx = __LO(x); |
92 k = (hx&0x7ff00000)>>20; /* extract exponent */ | 95 k = (hx&0x7ff00000)>>20; /* extract exponent */ |
109 } | 112 } |
110 k += 54; /* subnormal result */ | 113 k += 54; /* subnormal result */ |
111 __HI(x) = (hx&0x800fffff)|(k<<20); | 114 __HI(x) = (hx&0x800fffff)|(k<<20); |
112 return x*twom54; | 115 return x*twom54; |
113 } | 116 } |
117 #endif | |
114 | 118 |
115 /* __ieee754_log(x) | 119 /* __ieee754_log(x) |
116 * Return the logrithm of x | 120 * Return the logrithm of x |
117 * | 121 * |
118 * Method : | 122 * Method : |