JDK-8074373 : NMT is not enabled if NMT option is specified after class path specifiers
Type:Bug
Component:tools
Sub-Component:launcher
Affected Version:9
Priority:P3
Status:Closed
Resolution:Fixed
Submitted:2015-03-04
Updated:2019-01-14
Resolved:2015-03-08
The Version table provides details related to the release that this issue/RFE will be addressed.
Unresolved : Release in which this issue/RFE will be addressed. Resolved: Release in which this issue/RFE has been resolved. Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.
Reproduces with:
java -cp . -XX:NativeMemoryTracking=detail -version
which with the change for JDK-8066185 results in:
Java HotSpot(TM) 64-Bit Server VM warning: Native Memory Tracking did not setup properly, using wrong launcher?
Comments
http://cr.openjdk.java.net/~ksrini/8074373/
05-03-2015
No if we have a failing regression test then the launcher logic must be fixed, I will take care of it.
05-03-2015
The bug is that when trying to determine if the flag exists prior to terminal flags,
the logic looks for an option without a leading dash "-" implying a main class etc, in this case
the logic must also determine if the preceding option is not -cp or -classpath.
04-03-2015
ILW => LLL == P5
Workaround: Dont use -XX flags after -cp.