[8u] RFR: 8240676: Meet not symmetric failure when running lucene on jdk8
Roland Westrelin
rwestrel at redhat.com
Fri Jul 24 09:26:36 UTC 2020
Hi Andrew,
Thanks for looking at this one.
> The changes to Type::meet_helper and Type::check_symmetrical look fine.
>
> However, I don't understand what the cherry-picked change to line 3996
> in TypeAryPtr::xmeet_helper does and why it is legitimate:
>
> - return make(NotNull, NULL, tary, lazy_klass, false, off,
> InstanceBot);
> + return make(NotNull, NULL, tary, lazy_klass, false, off,
> InstanceBot, speculative, depth);
>
> Obviously it fixes a crash but -- for the record -- can you explain
>
> 1) why the crash happened and how this fixes it
The background for this patch is the following: we saw a rare crash
during testing. The crash couldn't be reproduced. My attempts at a test
case didn't succeed either. So instead, I made a change to the
verification code in the type system so it stress tested some
combinations of types that were usually rarely exercised. It was then
easy to write a test case that triggered the failure and implement a
fix.
The risk with this change is not so much in the fix itself but in the
improvement to the verification code that can uncover bugs that we were
not aware of before. That's what happens with 8u where we hit a bug that
was never seen with 8u before.
Object pointer types have 2 parts: a known type part and a speculative
part. When the verification code triggers it verify both parts. In the
case of this fix, the speculative parts gets accidentally dropped. The
new verification code catches it. The previous one didn't for some
reason.
> 2) why this was not needed in the upstream patch and is needed here
I cherry-picked the change from a later release (jdk 9 I think). So the
change was not needed in the 11u patch because it was already there.
Roland
More information about the jdk8u-dev
mailing list