RFR: JDK-8312182: THPs cause huge RSS due to thread start timing issue [v2]
David Holmes
dholmes at openjdk.org
Thu Jul 20 06:55:45 UTC 2023
On Wed, 19 Jul 2023 15:56:42 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:
>> src/hotspot/os/linux/os_linux.cpp line 932:
>>
>>> 930: // into one VMA.
>>> 931: if (PreventTHPsForThreadStacks) {
>>> 932: guard_size = MAX2(guard_size, os::vm_page_size());
>>
>> It would be helpful to add a comment clarifying that we don't add glibc guard pages for JavaThreads and Compiler threads (i.e. default_guard_size returns 0 for these threads), and when PreventTHPsforThreadStacks is true, JavaThreads and Compiler threads will have both the glibc guard page and JVM guard pages.
>
> Hmm. We already have a comment in place in `os::Linux::default_guard_size(thr_type);`. Maybe @dholmes-ora is right; I will add this logic to default_guard_size and extent the comment over there.
Thanks for moving the logic.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14919#discussion_r1269010115
More information about the hotspot-runtime-dev
mailing list