mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-18 01:54:47 +02:00
8130459: Add additional validation after heap creation
Some PLAB related flags' validation can happen after heap creation. Introduced additional stage of validation check. Reviewed-by: coleenp, dholmes, kbarrett, gziemski, ecaspole, ddmitriev
This commit is contained in:
parent
093ee9b659
commit
a13fe250b0
17 changed files with 342 additions and 244 deletions
|
@ -52,6 +52,8 @@
|
|||
#include "runtime/arguments.hpp"
|
||||
#include "runtime/atomic.inline.hpp"
|
||||
#include "runtime/biasedLocking.hpp"
|
||||
#include "runtime/commandLineFlagConstraintList.hpp"
|
||||
#include "runtime/commandLineFlagRangeList.hpp"
|
||||
#include "runtime/deoptimization.hpp"
|
||||
#include "runtime/fprofiler.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
|
@ -3322,8 +3324,15 @@ jint Threads::create_vm(JavaVMInitArgs* args, bool* canTryAgain) {
|
|||
jint ergo_result = Arguments::apply_ergo();
|
||||
if (ergo_result != JNI_OK) return ergo_result;
|
||||
|
||||
// Final check of all arguments after ergonomics which may change values.
|
||||
if (!CommandLineFlags::check_all_ranges_and_constraints()) {
|
||||
// Final check of all ranges after ergonomics which may change values.
|
||||
if (!CommandLineFlagRangeList::check_ranges()) {
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
|
||||
// Final check of all 'AfterErgo' constraints after ergonomics which may change values.
|
||||
bool constraint_result = CommandLineFlagConstraintList::check_constraints(CommandLineFlagConstraint::AfterErgo);
|
||||
Arguments::post_after_ergo_constraint_check(constraint_result);
|
||||
if (!constraint_result) {
|
||||
return JNI_EINVAL;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue