1.1 --- a/src/share/vm/opto/doCall.cpp Fri Mar 02 13:13:25 2012 -0800 1.2 +++ b/src/share/vm/opto/doCall.cpp Mon Mar 05 18:10:31 2012 -0800 1.3 @@ -61,7 +61,7 @@ 1.4 1.5 CallGenerator* Compile::call_generator(ciMethod* call_method, int vtable_index, bool call_is_virtual, 1.6 JVMState* jvms, bool allow_inline, 1.7 - float prof_factor) { 1.8 + float prof_factor, bool allow_intrinsics) { 1.9 ciMethod* caller = jvms->method(); 1.10 int bci = jvms->bci(); 1.11 Bytecodes::Code bytecode = caller->java_code_at_bci(bci); 1.12 @@ -108,7 +108,7 @@ 1.13 // then we return it as the inlined version of the call. 1.14 // We do this before the strict f.p. check below because the 1.15 // intrinsics handle strict f.p. correctly. 1.16 - if (allow_inline) { 1.17 + if (allow_inline && allow_intrinsics) { 1.18 CallGenerator* cg = find_intrinsic(call_method, call_is_virtual); 1.19 if (cg != NULL) return cg; 1.20 } 1.21 @@ -455,21 +455,12 @@ 1.22 // cg->generate(), we are committed. If it fails, the whole 1.23 // compilation task is compromised. 1.24 if (failing()) return; 1.25 -#ifndef PRODUCT 1.26 - if (PrintOpto || PrintOptoInlining || PrintInlining) { 1.27 - // Only one fall-back, so if an intrinsic fails, ignore any bytecodes. 1.28 - if (cg->is_intrinsic() && call_method->code_size() > 0) { 1.29 - tty->print("Bailed out of intrinsic, will not inline: "); 1.30 - call_method->print_name(); tty->cr(); 1.31 - } 1.32 - } 1.33 -#endif 1.34 + 1.35 // This can happen if a library intrinsic is available, but refuses 1.36 // the call site, perhaps because it did not match a pattern the 1.37 - // intrinsic was expecting to optimize. The fallback position is 1.38 - // to call out-of-line. 1.39 - try_inline = false; // Inline tactic bailed out. 1.40 - cg = C->call_generator(call_method, vtable_index, call_is_virtual, jvms, try_inline, prof_factor()); 1.41 + // intrinsic was expecting to optimize. Should always be possible to 1.42 + // get a normal java call that may inline in that case 1.43 + cg = C->call_generator(call_method, vtable_index, call_is_virtual, jvms, try_inline, prof_factor(), /* allow_intrinsics= */ false); 1.44 if ((new_jvms = cg->generate(jvms)) == NULL) { 1.45 guarantee(failing(), "call failed to generate: calls should work"); 1.46 return;