Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jgit-dev] insertUnpackedObject() perf regression: j.nio.file.Files.exists() 15x slower than j.io.File.exists()

On 28 August 2015 at 16:44, Alex Blewitt <alex.blewitt@xxxxxxxxx> wrote:
I think a micro benchmark just looking at the relative performance of Files.exists vs File.exist should not require a 1.2G reference data and a ramdisk to execute.

That's true, a micro benchmark to determine the relative speed of Files.exists vs File.exist would be much smaller, have fewer dependencies, etc. I'm afraid all I have is a macro benchmark to establish the speed of the BFG - I appreciate that the performance of the BFG benchmark does not necessarily reflect the performance of JGit in other real-world use cases, it's only the real-world use-case that's most relevant to me. The average timings (4 microseconds vs 60 microseconds) for the exists() methods in my previous email are based on VisualVM CPU profiling times when attached to running BFG benchmarks.

I'm not experienced in writing high-quality micro-benchmarks - I've heard it's hard.

Roberto



Back to the top