RFR (XS): 8066670 - PrintSharedArchiveAndExit does not exit the VM when the archive is invalid
ioi.lam at oracle.com
Thu Dec 4 11:40:00 UTC 2014
On 12/4/14, 3:27 AM, David Holmes wrote:
> Hi Ioi,
> On 4/12/2014 8:32 PM, Ioi Lam wrote:
>> Hi Folks,
>> Please review a small fix:
>> Summary of fix:
>> Do not set UseSharedSpaces to falseif PrintSharedArchiveAndExit is
>> After this fix, the JVM correctly exits when
>> PrintSharedArchiveAndExit is enabled and an invalid archive is
> The change to metaspaceShared.cpp is fine.
> In filemap.cpp I'm less clear on the logic. It seems that if
> _validating_classpath_entry_table is false then we will still
> continue, even if PrintSharedArchiveAndExit is true.
The goal is try to print out as much information as possible. It turns
out the most useful information with PrintSharedArchiveAndExit is to
find out which part of the classpath is invalid. When
_validating_classpath_entry_table is true, we know it's safe to print an
error message (about a part of the classpath that's invalid) and continue.
When doing other things (_validating_classpath_entry_table==false), it's
less clear whether we can continue if a failure is encountered. In this
case, since PrintSharedArchiveAndExit is true, RequireSharedSpaces is
automatically set to true (by arguments.cpp), so we will print out the
error message and exit immediately.
>> New test cases are in closed source code.
> Begs the question as to why there can't be an open test for this?
I will add an open test as well.
More information about the hotspot-runtime-dev