Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-core-dev] [perf] AbstractDataTreeNode.simplifyWithParent creates 100 mil instances during one build

Thanks for the analysis. I hope you can investigate enough to turn some findings into concrete bugs/patches.

One thing that you did not mention (or how you controlled for it) was if these were a "first time clean builds" with each of the tools ... or second, or third ...etc.

We all know maven caches a lot, sometimes in "hidden" places :) sometimes in /targets ... and I know from experience a "first time clean build" with Eclipse is much longer than subsequent incremental builds (since the latter makes use of "cached" results. I know less about IntelliJ IDEA but suspect it'd have some caching mechanisms too.

I am not disputing what you've found so far, just saying that it is an important variable to account for and know about. Put another way, performance of both are important, first time clean builds and subsequent "incremental" builds ... I am just saying it is important to know which the measurements and comparisons are from.

Thanks again,





From:        Martin Kočí <martin.kocicak.koci@xxxxxxxxx>
To:        platform-core-dev@xxxxxxxxxxx,
Date:        08/13/2013 08:17 AM
Subject:        [platform-core-dev] [perf] AbstractDataTreeNode.simplifyWithParent creates 100 mil instances during one build
Sent by:        platform-core-dev-bounces@xxxxxxxxxxx




Hi,

i´m doing some profiling. We have a project  with ~200 modules/bundles. The build takes with maven (not tycho) 3 min, in parallel (wth -T 2C  maven parameter) only 1 min 10 sec. IntelliJ IDEA need only 8 minutes but eclipse ~ 30 minutes! The Eclipse installation has no know CPU-eaters like Subclipse or mylyn Context (=Resource changed listeners evaluting every change of .class). I eliminated the influence of harddrive and I/O-Operaions with SSD and the maschine has enough of RAM (no swap)

I did a profiling with YouKitProfiler and the of "Hot Spots by object count" is the method simplifyWithParent with ~ 100 mil of allocations of
org.eclipse.core.internal.dtree.AbstractDataTreeNode[]
org.eclipse.core.internal.dtree.DataDeltaNode
org.eclipse.core.internal.dtree.NoDataDeltaNode
java.lang.String[]
org.eclipse.core.runtime.Path
org.eclipse.core.internal.dtree.DataTreeNode

I don't know the purpose of the code, but here are some wild guesses:

A) simplifyWithParent creates e new instance of Path with key.append(String). Path instance ist a representation of /a/path/to/a/file/ and thus probably immutable. if it is really immutable, is a pool of Paths possible ? In this case the created Path instance very short-lived and it provides only a info about a path for org.eclipse.core.internal.dtree.AbstractDataTreeNode.simplifyWithParent(IPath, DeltaDataTree, IComparator) implementations.

B) node.simplifyWithParent returns simplifiedNode.isEmptyDelta() : true for NoDataDeltaNode. In this case, the NoDataDeltaNode instance is very short-lived, used for simplifiedNode.isEmptyDelta() only. Is it possible to use null-return-values as empty delta ? (Most likely not - it must be backward-compatible). What about a new method then?


C) a triviality: https://bugs.eclipse.org/bugs/show_bug.cgi?id=414902


Other infos: the tested enviroment ist eclipse kepler with m2e plugin. No other plugin installed. The m2e / maven plugins self consumes a lot, but I will discuss it in m2e devel mailing list. There is most likely a problem with hiearchical layout too. Sometimes are some resources processed (with simplifyWithParent)  2x : first in a bar.foo.subproject self and next time in bar.foo.parent.project/bar.foo.subproject. I'll investigate it more.

Many thanks for your ideas

Martin
_________________ _________________________ _____
platform-core-dev mailing list
platform-core-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/platform-core-dev


Back to the top