RFR: 8279523: Parallel: Remove unnecessary PSScavenge::_to_space_top_before_gc

Albert Mingkun Yang ayang at openjdk.java.net
Thu Jan 6 10:50:11 UTC 2022


On Thu, 6 Jan 2022 07:12:21 GMT, Hamlin Li <mli at openjdk.org> wrote:

>> Simple change of removing an unnecessary field.
>> 
>> Test: hotspot_gc
>
> src/hotspot/share/gc/parallel/psScavenge.inline.hpp line 49:
> 
>> 47:     // Skip objects copied to to_space since the scavenge started.
>> 48:     HeapWord* const addr = cast_from_oop<HeapWord*>(obj);
>> 49:     return addr < to_space->bottom() || addr >= to_space->end();
> 
> Not sure if I understand this correctly, is this a typo or intended from top to bottom?

It's intended because `to_space_top_before_gc() == to_space->bottom()`.

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

PR: https://git.openjdk.java.net/jdk/pull/6968



More information about the hotspot-gc-dev mailing list