RFR: 8244297: Provide utility for testing for memory leaks [v10]

Florian Kirmaier fkirmaier at openjdk.java.net
Wed Oct 28 09:47:32 UTC 2020


On Tue, 27 Oct 2020 20:40:23 GMT, Kevin Rushforth <kcr at openjdk.org> wrote:

>> I've added runFinalization followed with another System.gc (otherwise it wouldn't make any difference)
>> I'm quite sure it's avoiding an error in the library, but I don't have a unit-test for it yet.
>> 
>> It's a tradeoff between speed and reliability. The library tries to avoid false-negative test results at all costs.
>> false-positive results are tolerated for speed if they are "sufficiently reliable".
>> The Library has tests for assertNotCollectable, which are executed with every commit for different JVM's, and I don't remember any false-positive results (which would be visible as a negative test result, because the unit-test checks for failing tests). For that reason, we can assume they are "sufficiently reliable" despite the theoretical problem.
>
> That sounds fine then.
> 
> As soon as you've pushed the follow-on fix (to add the `runFinalization` and a second `gc`) I'll finish my review.

I forgot to push my changes yesterday. They are pushed now!

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

PR: https://git.openjdk.java.net/jfx/pull/204


More information about the openjfx-dev mailing list