8221724: Enable archiving of Strings with hash 0

Reviewed-by: jiangli, iklam
This commit is contained in:
Claes Redestad 2019-04-02 11:37:11 +02:00
parent 1908897b93
commit 3880f3db74
4 changed files with 39 additions and 15 deletions

View file

@ -761,10 +761,6 @@ struct CopyToArchive : StackObj {
return true;
}
unsigned int hash = java_lang_String::hash_code(s);
if (hash == 0) {
// We do not archive Strings with a 0 hashcode because ......
return true;
}
java_lang_String::set_hash(s, hash);
oop new_s = StringTable::create_archived_string(s, Thread::current());