Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8286851 Deprecate for removal several of the undocumented java launcher options
  3. JDK-8339918

Remove checks for outdated -t -tm -Xfuture -checksource -cs -noasyncgc options from the launcher

XMLWordPrintable

    • b16

      The "java" launcher currently checks for a few outdated options and either transforms those options and passes it along or logs a warning and ignores those options.

      Specifically,

      The launcher converts the -t and -tm options to -Xt and -Xtm and passes it along to the JVM. Both these options are outdated and even -Xt and -Xtm are unsupported. So currently launching with either of these options runs into (an expected) error during launch:

      java -t Foo
      Unrecognized option: -Xt
      Error: Could not create the Java Virtual Machine.
      Error: A fatal exception has occurred. Program will exit.

      For -checksource -cs and -noasyncgc we currently just log a warning and ignore those options. These 3 options have all been unsupported since Java 1.2 days.

      For -Xfuture, the launcher converts it to -Xverify:all and logs a warning message about deprecation and then passes -Xverify:all to the JVM. The -Xfuture was deprecated for removal in Java 13 through https://bugs.openjdk.org/browse/JDK-8215156 :

      java -Xfuture Foo
      Warning: -Xfuture option is deprecated and may be removed in a future release.
      ...

      The code in the launcher which checks for these options should be updated to remove support/checks for these options and these should be treated like any other unknown option when launching "java".

            jpai Jaikiran Pai
            jpai Jaikiran Pai
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: