3504 // Initialize the os module
3505 os::init();
3506
3507 // Record VM creation timing statistics
3508 TraceVmCreationTime create_vm_timer;
3509 create_vm_timer.start();
3510
3511 // Initialize system properties.
3512 Arguments::init_system_properties();
3513
3514 // So that JDK version can be used as a discriminator when parsing arguments
3515 JDK_Version_init();
3516
3517 // Update/Initialize System properties after JDK version number is known
3518 Arguments::init_version_specific_system_properties();
3519
3520 // Make sure to initialize log configuration *before* parsing arguments
3521 LogConfiguration::initialize(create_vm_timer.begin_time());
3522
3523 // Parse arguments
3524 jint parse_result = Arguments::parse(args);
3525 if (parse_result != JNI_OK) return parse_result;
3526
3527 os::init_before_ergo();
3528
3529 jint ergo_result = Arguments::apply_ergo();
3530 if (ergo_result != JNI_OK) return ergo_result;
3531
3532 // Final check of all ranges after ergonomics which may change values.
3533 if (!CommandLineFlagRangeList::check_ranges()) {
3534 return JNI_EINVAL;
3535 }
3536
3537 // Final check of all 'AfterErgo' constraints after ergonomics which may change values.
3538 bool constraint_result = CommandLineFlagConstraintList::check_constraints(CommandLineFlagConstraint::AfterErgo);
3539 if (!constraint_result) {
3540 return JNI_EINVAL;
3541 }
3542
3543 CommandLineFlagWriteableList::mark_startup();
|
3504 // Initialize the os module
3505 os::init();
3506
3507 // Record VM creation timing statistics
3508 TraceVmCreationTime create_vm_timer;
3509 create_vm_timer.start();
3510
3511 // Initialize system properties.
3512 Arguments::init_system_properties();
3513
3514 // So that JDK version can be used as a discriminator when parsing arguments
3515 JDK_Version_init();
3516
3517 // Update/Initialize System properties after JDK version number is known
3518 Arguments::init_version_specific_system_properties();
3519
3520 // Make sure to initialize log configuration *before* parsing arguments
3521 LogConfiguration::initialize(create_vm_timer.begin_time());
3522
3523 // Parse arguments
3524 // Note: this internally calls os::init_container_support()
3525 jint parse_result = Arguments::parse(args);
3526 if (parse_result != JNI_OK) return parse_result;
3527
3528 os::init_before_ergo();
3529
3530 jint ergo_result = Arguments::apply_ergo();
3531 if (ergo_result != JNI_OK) return ergo_result;
3532
3533 // Final check of all ranges after ergonomics which may change values.
3534 if (!CommandLineFlagRangeList::check_ranges()) {
3535 return JNI_EINVAL;
3536 }
3537
3538 // Final check of all 'AfterErgo' constraints after ergonomics which may change values.
3539 bool constraint_result = CommandLineFlagConstraintList::check_constraints(CommandLineFlagConstraint::AfterErgo);
3540 if (!constraint_result) {
3541 return JNI_EINVAL;
3542 }
3543
3544 CommandLineFlagWriteableList::mark_startup();
|