src/share/vm/compiler/compilerOracle.cpp
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File
*** old/src/share/vm/compiler/compilerOracle.cpp Fri Oct 2 15:58:56 2015
--- new/src/share/vm/compiler/compilerOracle.cpp Fri Oct 2 15:58:56 2015
*** 104,113 ****
--- 104,114 ----
class MethodMatcher;
class TypedMethodOptionMatcher;
static BasicMatcher* lists[OracleCommandCount] = { 0, };
static TypedMethodOptionMatcher* option_list = NULL;
+ static bool any_set = false;
class TypedMethodOptionMatcher : public MethodMatcher {
private:
TypedMethodOptionMatcher* _next;
const char* _option;
*** 290,299 ****
--- 291,301 ----
T value) {
assert(matcher != option_list, "No circular lists please");
matcher->init(option, get_type_for<T>(), option_list);
matcher->set_value<T>(value);
option_list = matcher;
+ any_set = true;
return;
}
static bool check_predicate(OracleCommand command, methodHandle method) {
return ((lists[command] != NULL) &&
*** 306,316 ****
--- 308,320 ----
if (command == LogCommand && !LogCompilation && lists[LogCommand] == NULL) {
tty->print_cr("Warning: +LogCompilation must be enabled in order for individual methods to be logged.");
}
bm->set_next(lists[command]);
lists[command] = bm;
+ if ((command != DontInlineCommand) && (command != InlineCommand)) {
+ any_set = true;
+ }
return;
}
template<typename T>
bool CompilerOracle::has_option_value(methodHandle method, const char* option, T& value) {
*** 322,331 ****
--- 326,339 ----
}
}
return false;
}
+ bool CompilerOracle::has_any_option() {
+ return any_set;
+ }
+
// Explicit instantiation for all OptionTypes supported.
template bool CompilerOracle::has_option_value<intx>(methodHandle method, const char* option, intx& value);
template bool CompilerOracle::has_option_value<uintx>(methodHandle method, const char* option, uintx& value);
template bool CompilerOracle::has_option_value<bool>(methodHandle method, const char* option, bool& value);
template bool CompilerOracle::has_option_value<ccstr>(methodHandle method, const char* option, ccstr& value);
*** 335,365 ****
--- 343,366 ----
bool value = false;
has_option_value(method, option, value);
return value;
}
- bool CompilerOracle::should_exclude(methodHandle method, bool& quietly) {
quietly = true;
if (lists[ExcludeCommand] != NULL) {
if (lists[ExcludeCommand]->match(method)) {
quietly = _quiet;
+ if (check_predicate(ExcludeCommand, method)) {
return true;
}
}
if (lists[CompileOnlyCommand] != NULL) {
return !lists[CompileOnlyCommand]->match(method);
}
return false;
}
bool CompilerOracle::should_inline(methodHandle method) {
return (check_predicate(InlineCommand, method));
}
// Check both DontInlineCommand and ExcludeCommand here
// - consistent behavior for all compilers
bool CompilerOracle::should_not_inline(methodHandle method) {
return check_predicate(DontInlineCommand, method) || check_predicate(ExcludeCommand, method);
}
bool CompilerOracle::should_print(methodHandle method) {
src/share/vm/compiler/compilerOracle.cpp
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File