The JAVA_TOOL_OPTIONS environment variable is used to pass additional JVM arguments.
The current implementation has an internal limit on the length of the option variable (1024 bytes) and the number of options (64).
A longer variable will be silently truncated and options will be lost or the VM will exist with an unrecognized option error.
Such limits are not set in the specification: https://docs.oracle.com/javase/8/docs/platform/jvmti/jvmti.html#tooloptions
It's partial backport of relevant changes from JDK-8135195, JDK-8074895, JDK-8061999