RFR: 8345656: Move os alignment functions out of ReservedSpace [v2]

David Holmes dholmes at openjdk.org
Mon Dec 9 02:38:38 UTC 2024


On Fri, 6 Dec 2024 14:54:13 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:

>> I have a wish to simplify the ReservedSpace classes (See: [JDK-8345655](https://bugs.openjdk.org/browse/JDK-8345655)) and as a small step I would like to move the small helper functions that align addresses and sizes to `os::vm_page_size()` and `os::vm_allocation_granularity()` out to be `os::` helpers.
>> 
>> Tested tier1-3 together with the other patches in the JDK-8345655 prototype.
>
> Stefan Karlsson has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Copyright

I don't see the removal of the "moved" functions from ./share/memory/virtualspace.cpp ??

src/hotspot/share/runtime/os.hpp line 408:

> 406:   static size_t vm_page_size() { return OSInfo::vm_page_size(); }
> 407: 
> 408:   static size_t align_up_vm_page_size(size_t size)   { return align_up  (size, os::vm_page_size()); }

Style Nit: please don't add extra whitespace before the opening function parenthesis.

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

PR Review: https://git.openjdk.org/jdk/pull/22600#pullrequestreview-2487519426
PR Review Comment: https://git.openjdk.org/jdk/pull/22600#discussion_r1875194126


More information about the shenandoah-dev mailing list