comparison src/cpu/x86/vm/interpreter_x86_32.cpp @ 6084:6759698e3140

7133857: exp() and pow() should use the x87 ISA on x86 Summary: use x87 instructions to implement exp() and pow() in interpreter/c1/c2. Reviewed-by: kvn, never, twisti
author roland
date Tue, 15 May 2012 10:10:23 +0200
parents 3d2ab563047a
children 1d7922586cf6
comparison
equal deleted inserted replaced
6057:8f972594effc 6084:6759698e3140
179 __ flog10(); 179 __ flog10();
180 // Store to stack to convert 80bit precision back to 64bits 180 // Store to stack to convert 80bit precision back to 64bits
181 __ push_fTOS(); 181 __ push_fTOS();
182 __ pop_fTOS(); 182 __ pop_fTOS();
183 break; 183 break;
184 case Interpreter::java_lang_math_pow:
185 __ fld_d(Address(rsp, 3*wordSize)); // second argument
186 __ pow_with_fallback(0);
187 // Store to stack to convert 80bit precision back to 64bits
188 __ push_fTOS();
189 __ pop_fTOS();
190 break;
191 case Interpreter::java_lang_math_exp:
192 __ exp_with_fallback(0);
193 // Store to stack to convert 80bit precision back to 64bits
194 __ push_fTOS();
195 __ pop_fTOS();
196 break;
184 default : 197 default :
185 ShouldNotReachHere(); 198 ShouldNotReachHere();
186 } 199 }
187 200
188 // return double result in xmm0 for interpreter and compilers. 201 // return double result in xmm0 for interpreter and compilers.