Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jgit-dev] ObjectDirectory.scanPacksImpl performance regression and temporary memory leak



On Thu, May 23, 2019 at 10:44 PM Luca Milanesio <luca.milanesio@xxxxxxxxx> wrote:


On 22 May 2019, at 19:01, Thomas Wolf <thomas.wolf@xxxxxxxxxx> wrote:

Hi Marc,

On 22 May 2019, at 19:24 , Marc Strapetz <marc.strapetz@xxxxxxxxxxx> wrote:

With commits 82b1af31 and fef78212, the reuse condition of existing PackFiles in ObjectDirectory.scanPacksImpl has been changed
[...]
Due to the racy-clean handling in FileSnapshot.isModified, this results in many false-positive modification detections immediately after creating or modifying a PackFile and thus in redundant re-creation of PackFiles. I'm experiencing our unit tests to be ~5x slower with this change.

Yes, that's bug 546891: https://bugs.eclipse.org/bugs/show_bug.cgi?id=546891 We're trying to fix it. See the chain of changes at https://git.eclipse.org/r/#/c/141843/ .

Also, the oldPack may now be removed from "forReuse" and thus not properly closed anymore further down the loop.

That bit got missed. Thanks for pointing it out.

Good catch Marc, thanks for that.

@Matthias: are you OK for me to fix it on the stable-4.5 branch? Or anywhere else?

Marc's fix is pushed for stable-5.1 here

-Matthias 

Back to the top