trouble with java -Xpatch
Michael Rasmussen
michael.rasmussen at zeroturnaround.com
Tue Mar 29 09:14:46 UTC 2016
With the new -Xpatch format, are there any plans to add support for
adding (or modifying) these from JVMTI in the OnLoad phase?
/Michael
On 28 March 2016 at 20:30, Alan Bateman <Alan.Bateman at oracle.com> wrote:
>
> Sorry, it is a bit confusing as we aren't quite done with the transition
> from an older form of a -Xpatch to the new form.
>
> The syntax you see in JEP 261 and in the java -X usage output is the new
> form. That works for modules defined to the platform or application class
> loaders but doesn't work for modules (like java.base) that are defined to
> the boot loader. Lois is working on the missing piece in hotspot, it is
> tracked by JDK-8146448. All the other pieces (in javac and the runtime) are
> in place.
>
> In the mean-time, the old form still works. The old syntax is
> -Xpatch:<dir>(:<dir>*) where <dir> is a directory of exploded patches. If
> you want to override CHM then you would run with -Xpatch:jsr166 where jsr166
> contains:
>
> java.base/java/util/concurrent/ConcurrentHashMap.class
>
> You can use the old syntax with the first usage of -Xpatch, not second or
> subsequent usages. That is why you see a difference in the -Xpatch:junk
> behavior when you specify it more than once.
>
> -Alan.
More information about the jigsaw-dev
mailing list