RFR: JDK-8293114: JVM should trim the native heap [v4]
Thomas Stuefe
stuefe at openjdk.org
Fri Jul 7 11:29:55 UTC 2023
On Fri, 7 Jul 2023 04:42:53 GMT, David Holmes <dholmes at openjdk.org> wrote:
> I had an initial look at this. Seems okay in principle. The naming/terminology needs some updating IMO: "trimNative" doesn't convey enough information, please use "trimNativeHeap". "trim" for logging tag is also too non-descript.
>
> As this is initially experimental I'm not overly concerned about the impact, though I do cringe at yet-another-VM-thread.
>
> FYI I will be away until next Thursday, but no need to wait for me for further comments.
Thank you @dholmes-ora.
I dislike the introduction of another thread too, but the benefits are undeniably there, and we need to keep the invocation of malloc_trim away from other code paths. That said, maybe a future glibc will offer us a ways to influence trim to make its runtime predictable. Which would remove the need of an own thread.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/14781#issuecomment-1625271681
More information about the serviceability-dev
mailing list