RFR: 8292697: ZGC: Hangs when almost out of metaspace memory
Coleen Phillimore
coleenp at openjdk.org
Wed Aug 24 15:36:22 UTC 2022
On Wed, 24 Aug 2022 15:18:03 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:
>> src/hotspot/share/memory/metaspaceCriticalAllocation.cpp line 152:
>>
>>> 150: if (is_first_unprocessed()) {
>>> 151: // The first non-processed request takes ownership of triggering the GC
>>> 152: // on behalf of itself, and all trailing requests in the list.
>>
>> why is this a lambda? why can't it just be code?
>
> Just style:
> 1) I wanted to pull this logic out to a function/lambda
> 2) I wanted to keep the code near its usage
> 3) I didn't want all ceremony of having to declare the function / or creating a free function taking two extra parameters.
why did it need to be pulled out into a function? It's just a small amount of code that either is a lambda inline or just code inline? I'm a massive fan of lambdas but I don't see the purpose here.
>> test/hotspot/jtreg/vmTestbase/metaspace/shrink_grow/ShrinkGrowTest/ShrinkGrowTest.java line 148:
>>
>>> 146: // it should be impossible
>>> 147: try {
>>> 148: log("just a tiny mint");
>>
>> huh?
>
> I wanted extra logging to see if we reached this statement (we didn't). And I though this line fitted the context, similar to the other rather silly statements in the test (eatALittleMemory, "washing hands before meal"). I can change it if it bothers you.
nah, it's fine.
-------------
PR: https://git.openjdk.org/jdk/pull/9985
More information about the hotspot-dev
mailing list