RFR: 8321939: [GenShen] ShenandoahOldEvacRatioPercent=100 fails with divide-by-zero [v2]

Y. Srinivas Ramakrishna ysr at openjdk.org
Wed Dec 13 21:58:23 UTC 2023


On Wed, 13 Dec 2023 21:16:08 GMT, Kelvin Nilsen <kdnilsen at openjdk.org> wrote:

>> Y. Srinivas Ramakrishna has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Fix a scope issue with a local variable.
>
> src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp line 1242:
> 
>> 1240:   const bool doing_promotions = promo_load > 0;
>> 1241:   if (doing_promotions) {
>> 1242:     // We're only promoting and we have a maximum bound on the amount to be promoted
> 
> With reference to the preceding comment, we should probably add an assert here: assert(!doing_mixed, "Don't do mixed and promotions in the same cycle")
> 
> Or maybe this is no longer true.  It doesn't have to be true.  The code that follows seems to suggest this is no longer true.  It was a simplification at some point in the implementation history.  If it is no longer true, let's remove that comment.

I believe you are right. The comment appears obsolete. I'll check/confirm and delete the comment. Thanks!

-------------

PR Review Comment: https://git.openjdk.org/shenandoah/pull/369#discussion_r1425925729


More information about the shenandoah-dev mailing list