Checking whether a pointer is in the young generation of the serial collector is currently done by comparing the pointer to the end of the young generation reserved space. However, these checks are duplicated in various places, which complicates any changes to the layout of the young generation since all these locations would need to be updated. DefNewGeneration::is_in_reserved method should serve a the sole source of truth for whether a pointer is in the young generation.
- links to
-
Review(master) openjdk/jdk/23792