--- a/hotspot/src/share/vm/opto/library_call.cpp Fri Jan 08 11:41:04 2016 +0100
+++ b/hotspot/src/share/vm/opto/library_call.cpp Fri Jan 08 21:06:50 2016 -0800
@@ -1628,8 +1628,6 @@
Node* n = NULL;
switch (id) {
- case vmIntrinsics::_dsin: n = new SinDNode(C, control(), arg); break;
- case vmIntrinsics::_dcos: n = new CosDNode(C, control(), arg); break;
case vmIntrinsics::_dtan: n = new TanDNode(C, control(), arg); break;
default: fatal_unexpected_iid(id); break;
}
@@ -1692,16 +1690,6 @@
// Slow path - non-blocking leaf call
Node* call = NULL;
switch (id) {
- case vmIntrinsics::_dsin:
- call = make_runtime_call(RC_LEAF, OptoRuntime::Math_D_D_Type(),
- CAST_FROM_FN_PTR(address, SharedRuntime::dsin),
- "Sin", NULL, arg, top());
- break;
- case vmIntrinsics::_dcos:
- call = make_runtime_call(RC_LEAF, OptoRuntime::Math_D_D_Type(),
- CAST_FROM_FN_PTR(address, SharedRuntime::dcos),
- "Cos", NULL, arg, top());
- break;
case vmIntrinsics::_dtan:
call = make_runtime_call(RC_LEAF, OptoRuntime::Math_D_D_Type(),
CAST_FROM_FN_PTR(address, SharedRuntime::dtan),
@@ -1752,17 +1740,21 @@
#define FN_PTR(f) CAST_FROM_FN_PTR(address, f)
switch (id) {
// These intrinsics are not properly supported on all hardware
- case vmIntrinsics::_dcos: return Matcher::has_match_rule(Op_CosD) ? inline_trig(id) :
- runtime_math(OptoRuntime::Math_D_D_Type(), FN_PTR(SharedRuntime::dcos), "COS");
- case vmIntrinsics::_dsin: return Matcher::has_match_rule(Op_SinD) ? inline_trig(id) :
- runtime_math(OptoRuntime::Math_D_D_Type(), FN_PTR(SharedRuntime::dsin), "SIN");
+ case vmIntrinsics::_dsin:
+ return StubRoutines::dsin() != NULL ?
+ runtime_math(OptoRuntime::Math_D_D_Type(), StubRoutines::dsin(), "dsin") :
+ runtime_math(OptoRuntime::Math_D_D_Type(), FN_PTR(SharedRuntime::dsin), "SIN");
+ case vmIntrinsics::_dcos:
+ return StubRoutines::dcos() != NULL ?
+ runtime_math(OptoRuntime::Math_D_D_Type(), StubRoutines::dcos(), "dcos") :
+ runtime_math(OptoRuntime::Math_D_D_Type(), FN_PTR(SharedRuntime::dcos), "COS");
case vmIntrinsics::_dtan: return Matcher::has_match_rule(Op_TanD) ? inline_trig(id) :
runtime_math(OptoRuntime::Math_D_D_Type(), FN_PTR(SharedRuntime::dtan), "TAN");
case vmIntrinsics::_dlog:
return StubRoutines::dlog() != NULL ?
- runtime_math(OptoRuntime::Math_D_D_Type(), StubRoutines::dlog(), "dlog") :
- runtime_math(OptoRuntime::Math_D_D_Type(), FN_PTR(SharedRuntime::dlog), "LOG");
+ runtime_math(OptoRuntime::Math_D_D_Type(), StubRoutines::dlog(), "dlog") :
+ runtime_math(OptoRuntime::Math_D_D_Type(), FN_PTR(SharedRuntime::dlog), "LOG");
case vmIntrinsics::_dlog10: return Matcher::has_match_rule(Op_Log10D) ? inline_math(id) :
runtime_math(OptoRuntime::Math_D_D_Type(), FN_PTR(SharedRuntime::dlog10), "LOG10");