-
Bug
-
Resolution: Fixed
-
P3
-
9
in Thread::create_vm we call
CommandLineFlagRangeList::check_ranges()
and CommandLineFlagConstraintList::check_constraints(CommandLineFlagConstraint::AfterErgo)
which together cause more than 302k strlen calls, a fraction of that strcmps for a total of about ~14M instructions, or 4% of the total, in a Hello World startup test (comparing a build where these calls are commented out). The cost is O(n*m), where n is the number of constraints and m is the total number of flags.
While a very small regression (~0.5-1.5ms) there are a number of ways to improve this, such as sorting the constraints and flag table so that we could do the scan in O(n+m) time.
CommandLineFlagRangeList::check_ranges()
and CommandLineFlagConstraintList::check_constraints(CommandLineFlagConstraint::AfterErgo)
which together cause more than 302k strlen calls, a fraction of that strcmps for a total of about ~14M instructions, or 4% of the total, in a Hello World startup test (comparing a build where these calls are commented out). The cost is O(n*m), where n is the number of constraints and m is the total number of flags.
While a very small regression (~0.5-1.5ms) there are a number of ways to improve this, such as sorting the constraints and flag table so that we could do the scan in O(n+m) time.
- duplicates
-
JDK-8180614 Skip range and constraint checks on non-existent flags
- Resolved
- relates to
-
JDK-8180614 Skip range and constraint checks on non-existent flags
- Resolved
-
JDK-8059557 JEP 245: Validate JVM Command-Line Flag Arguments
- Closed
There are no Sub-Tasks for this issue.