equal
deleted
inserted
replaced
23 */ |
23 */ |
24 |
24 |
25 #include "precompiled.hpp" |
25 #include "precompiled.hpp" |
26 #include "oops/oop.inline.hpp" |
26 #include "oops/oop.inline.hpp" |
27 #include "oops/symbol.hpp" |
27 #include "oops/symbol.hpp" |
28 #include "prims/jvmtiRedefineClassesTrace.hpp" |
|
29 #include "prims/methodComparator.hpp" |
28 #include "prims/methodComparator.hpp" |
30 #include "runtime/handles.inline.hpp" |
29 #include "runtime/handles.inline.hpp" |
31 #include "utilities/globalDefinitions.hpp" |
30 #include "utilities/globalDefinitions.hpp" |
32 |
31 |
33 BytecodeStream *MethodComparator::_s_old; |
32 BytecodeStream *MethodComparator::_s_old; |
37 |
36 |
38 bool MethodComparator::methods_EMCP(Method* old_method, Method* new_method) { |
37 bool MethodComparator::methods_EMCP(Method* old_method, Method* new_method) { |
39 if (old_method->code_size() != new_method->code_size()) |
38 if (old_method->code_size() != new_method->code_size()) |
40 return false; |
39 return false; |
41 if (check_stack_and_locals_size(old_method, new_method) != 0) { |
40 if (check_stack_and_locals_size(old_method, new_method) != 0) { |
42 // RC_TRACE macro has an embedded ResourceMark |
41 if (log_is_enabled(Debug, redefine, class, methodcomparator)) { |
43 RC_TRACE(0x00800000, ("Methods %s non-comparable with diagnosis %d", |
42 ResourceMark rm; |
44 old_method->name()->as_C_string(), |
43 log_debug(redefine, class, methodcomparator) |
45 check_stack_and_locals_size(old_method, new_method))); |
44 ("Methods %s non-comparable with diagnosis %d", |
|
45 old_method->name()->as_C_string(), check_stack_and_locals_size(old_method, new_method)); |
|
46 } |
46 return false; |
47 return false; |
47 } |
48 } |
48 |
49 |
49 _old_cp = old_method->constants(); |
50 _old_cp = old_method->constants(); |
50 _new_cp = new_method->constants(); |
51 _new_cp = new_method->constants(); |