RFR: JDK-8284178: os::commit_memory() should assert the given range [v2]

Thomas Stuefe stuefe at openjdk.java.net
Thu Apr 7 04:46:19 UTC 2022


On Wed, 6 Apr 2022 08:08:18 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

>> Thomas Stuefe has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Alexey-feedback
>
> src/hotspot/share/runtime/os.cpp line 1679:
> 
>> 1677: 
>> 1678: static void assert_nonempty_range(const char* addr, size_t bytes) {
>> 1679:   assert(addr != nullptr && bytes > 0, "invalid range (" PTR_FORMAT ", " SIZE_FORMAT ")",
> 
> The message suggests it is *range*, i.e. `(begin, end)`. I wonder if we better print `p2i(addr) + bytes`?

Okay, I changed the message

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

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


More information about the hotspot-runtime-dev mailing list