Thu, 15 Nov 2012 10:42:06 -0800
8001077: remove ciMethod::will_link
Summary: Removed will_link and changed all calls to is_loaded().
Reviewed-by: kvn
1.1 --- a/src/share/vm/c1/c1_GraphBuilder.cpp Mon Nov 12 14:03:53 2012 -0800 1.2 +++ b/src/share/vm/c1/c1_GraphBuilder.cpp Thu Nov 15 10:42:06 2012 -0800 1.3 @@ -1836,7 +1836,7 @@ 1.4 // check if we could do inlining 1.5 if (!PatchALot && Inline && klass->is_loaded() && 1.6 (klass->is_initialized() || klass->is_interface() && target->holder()->is_initialized()) 1.7 - && target->will_link(klass, callee_holder, code)) { 1.8 + && target->is_loaded()) { 1.9 // callee is known => check if we have static binding 1.10 assert(target->is_loaded(), "callee must be known"); 1.11 if (code == Bytecodes::_invokestatic ||
2.1 --- a/src/share/vm/ci/bcEscapeAnalyzer.cpp Mon Nov 12 14:03:53 2012 -0800 2.2 +++ b/src/share/vm/ci/bcEscapeAnalyzer.cpp Thu Nov 15 10:42:06 2012 -0800 2.3 @@ -282,7 +282,7 @@ 2.4 ciMethod* inline_target = NULL; 2.5 if (target->is_loaded() && klass->is_loaded() 2.6 && (klass->is_initialized() || klass->is_interface() && target->holder()->is_initialized()) 2.7 - && target->will_link(klass, callee_holder, code)) { 2.8 + && target->is_loaded()) { 2.9 if (code == Bytecodes::_invokestatic 2.10 || code == Bytecodes::_invokespecial 2.11 || code == Bytecodes::_invokevirtual && target->is_final_method()) {
3.1 --- a/src/share/vm/ci/ciMethod.cpp Mon Nov 12 14:03:53 2012 -0800 3.2 +++ b/src/share/vm/ci/ciMethod.cpp Thu Nov 15 10:42:06 2012 -0800 3.3 @@ -876,25 +876,6 @@ 3.4 } 3.5 3.6 // ------------------------------------------------------------------ 3.7 -// ciMethod::will_link 3.8 -// 3.9 -// Will this method link in a specific calling context? 3.10 -bool ciMethod::will_link(ciKlass* accessing_klass, 3.11 - ciKlass* declared_method_holder, 3.12 - Bytecodes::Code bc) { 3.13 - if (!is_loaded()) { 3.14 - // Method lookup failed. 3.15 - return false; 3.16 - } 3.17 - 3.18 - // The link checks have been front-loaded into the get_method 3.19 - // call. This method (ciMethod::will_link()) will be removed 3.20 - // in the future. 3.21 - 3.22 - return true; 3.23 -} 3.24 - 3.25 -// ------------------------------------------------------------------ 3.26 // ciMethod::should_exclude 3.27 // 3.28 // Should this method be excluded from compilation?
4.1 --- a/src/share/vm/ci/ciMethod.hpp Mon Nov 12 14:03:53 2012 -0800 4.2 +++ b/src/share/vm/ci/ciMethod.hpp Thu Nov 15 10:42:06 2012 -0800 4.3 @@ -241,9 +241,6 @@ 4.4 int resolve_vtable_index(ciKlass* caller, ciKlass* receiver); 4.5 4.6 // Compilation directives 4.7 - bool will_link(ciKlass* accessing_klass, 4.8 - ciKlass* declared_method_holder, 4.9 - Bytecodes::Code bc); 4.10 bool should_exclude(); 4.11 bool should_inline(); 4.12 bool should_not_inline();
5.1 --- a/src/share/vm/opto/doCall.cpp Mon Nov 12 14:03:53 2012 -0800 5.2 +++ b/src/share/vm/opto/doCall.cpp Thu Nov 15 10:42:06 2012 -0800 5.3 @@ -334,7 +334,7 @@ 5.4 return true; 5.5 } 5.6 5.7 - assert(dest_method->will_link(method()->holder(), klass, bc()), "dest_method: typeflow responsibility"); 5.8 + assert(dest_method->is_loaded(), "dest_method: typeflow responsibility"); 5.9 return false; 5.10 } 5.11