mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 06:45:07 +02:00
8179026: Remove explicit code cache options processing
Removed explicit processing of code cache related options because generic processing already handles these. Reviewed-by: kvn
This commit is contained in:
parent
01e9cb7e23
commit
d54de52f13
3 changed files with 11 additions and 65 deletions
|
@ -2152,12 +2152,7 @@ bool Arguments::check_vm_args_consistency() {
|
|||
// Check lower bounds of the code cache
|
||||
// Template Interpreter code is approximately 3X larger in debug builds.
|
||||
uint min_code_cache_size = CodeCacheMinimumUseSpace DEBUG_ONLY(* 3);
|
||||
if (InitialCodeCacheSize < (uintx)os::vm_page_size()) {
|
||||
jio_fprintf(defaultStream::error_stream(),
|
||||
"Invalid InitialCodeCacheSize=%dK. Must be at least %dK.\n", InitialCodeCacheSize/K,
|
||||
os::vm_page_size()/K);
|
||||
status = false;
|
||||
} else if (ReservedCodeCacheSize < InitialCodeCacheSize) {
|
||||
if (ReservedCodeCacheSize < InitialCodeCacheSize) {
|
||||
jio_fprintf(defaultStream::error_stream(),
|
||||
"Invalid ReservedCodeCacheSize: %dK. Must be at least InitialCodeCacheSize=%dK.\n",
|
||||
ReservedCodeCacheSize/K, InitialCodeCacheSize/K);
|
||||
|
@ -2770,18 +2765,6 @@ jint Arguments::parse_each_vm_init_arg(const JavaVMInitArgs* args, bool* patch_m
|
|||
if (FLAG_SET_CMDLINE(intx, ThreadStackSize, value) != Flag::SUCCESS) {
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
} else if (match_option(option, "-XX:CodeCacheExpansionSize=", &tail)) {
|
||||
julong long_CodeCacheExpansionSize = 0;
|
||||
ArgsRange errcode = parse_memory_size(tail, &long_CodeCacheExpansionSize, os::vm_page_size());
|
||||
if (errcode != arg_in_range) {
|
||||
jio_fprintf(defaultStream::error_stream(),
|
||||
"Invalid argument: %s. Must be at least %luK.\n", option->optionString,
|
||||
os::vm_page_size()/K);
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
if (FLAG_SET_CMDLINE(uintx, CodeCacheExpansionSize, (uintx)long_CodeCacheExpansionSize) != Flag::SUCCESS) {
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
} else if (match_option(option, "-Xmaxjitcodesize", &tail) ||
|
||||
match_option(option, "-XX:ReservedCodeCacheSize=", &tail)) {
|
||||
julong long_ReservedCodeCacheSize = 0;
|
||||
|
@ -2795,45 +2778,6 @@ jint Arguments::parse_each_vm_init_arg(const JavaVMInitArgs* args, bool* patch_m
|
|||
if (FLAG_SET_CMDLINE(uintx, ReservedCodeCacheSize, (uintx)long_ReservedCodeCacheSize) != Flag::SUCCESS) {
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
// -XX:NonNMethodCodeHeapSize=
|
||||
} else if (match_option(option, "-XX:NonNMethodCodeHeapSize=", &tail)) {
|
||||
julong long_NonNMethodCodeHeapSize = 0;
|
||||
|
||||
ArgsRange errcode = parse_memory_size(tail, &long_NonNMethodCodeHeapSize, 1);
|
||||
if (errcode != arg_in_range) {
|
||||
jio_fprintf(defaultStream::error_stream(),
|
||||
"Invalid maximum non-nmethod code heap size: %s.\n", option->optionString);
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
if (FLAG_SET_CMDLINE(uintx, NonNMethodCodeHeapSize, (uintx)long_NonNMethodCodeHeapSize) != Flag::SUCCESS) {
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
// -XX:ProfiledCodeHeapSize=
|
||||
} else if (match_option(option, "-XX:ProfiledCodeHeapSize=", &tail)) {
|
||||
julong long_ProfiledCodeHeapSize = 0;
|
||||
|
||||
ArgsRange errcode = parse_memory_size(tail, &long_ProfiledCodeHeapSize, 1);
|
||||
if (errcode != arg_in_range) {
|
||||
jio_fprintf(defaultStream::error_stream(),
|
||||
"Invalid maximum profiled code heap size: %s.\n", option->optionString);
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
if (FLAG_SET_CMDLINE(uintx, ProfiledCodeHeapSize, (uintx)long_ProfiledCodeHeapSize) != Flag::SUCCESS) {
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
// -XX:NonProfiledCodeHeapSizee=
|
||||
} else if (match_option(option, "-XX:NonProfiledCodeHeapSize=", &tail)) {
|
||||
julong long_NonProfiledCodeHeapSize = 0;
|
||||
|
||||
ArgsRange errcode = parse_memory_size(tail, &long_NonProfiledCodeHeapSize, 1);
|
||||
if (errcode != arg_in_range) {
|
||||
jio_fprintf(defaultStream::error_stream(),
|
||||
"Invalid maximum non-profiled code heap size: %s.\n", option->optionString);
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
if (FLAG_SET_CMDLINE(uintx, NonProfiledCodeHeapSize, (uintx)long_NonProfiledCodeHeapSize) != Flag::SUCCESS) {
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
// -green
|
||||
} else if (match_option(option, "-green")) {
|
||||
jio_fprintf(defaultStream::error_stream(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue