-
Bug
-
Resolution: Fixed
-
P4
-
11, 17, 20
-
b11
This should have more parenthesis in java.cpp. The lack of parenthesis makes this always true, and we always run SystemDictionary::methods_do. The collect_profiled_methods function has a conditional that won't add the method, so this is a useless iteration through the methods at exit.
void print_method_profiling_data() {
if (ProfileInterpreter COMPILER1_PRESENT(|| C1UpdateMethodData) &&
(PrintMethodData || CompilerOracle::should_print_methods())) {
ResourceMark rm;
collected_profiled_methods = new GrowableArray<Method*>(1024);
SystemDictionary::methods_do(collect_profiled_methods);
collected_profiled_methods->sort(&compare_methods);
There are no tests for -XX:+PrintMethodData so one should be added with this bug fix.
void print_method_profiling_data() {
if (ProfileInterpreter COMPILER1_PRESENT(|| C1UpdateMethodData) &&
(PrintMethodData || CompilerOracle::should_print_methods())) {
ResourceMark rm;
collected_profiled_methods = new GrowableArray<Method*>(1024);
SystemDictionary::methods_do(collect_profiled_methods);
collected_profiled_methods->sort(&compare_methods);
There are no tests for -XX:+PrintMethodData so one should be added with this bug fix.