ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: DirectoryScanner performance
Date Thu, 18 Sep 2008 15:48:37 GMT
My complete test results are below.  Ant 1.7.1 has been consistently a
lot faster than 1.6.5 which consistently took half the time of 1.7.0.
svn trunk's HEAD is consistently faster than 1.7.1.

At the same time memory usage has increased with 1.7.0 and never
decreased after that, in fact the current HEAD uses more memory than
ever before.  Something between revisions 687768 and 693846 has bumped
the memory mark without gaining us much in terms of performance, I'll
try to isolate and remove that later.

The symlink loop detection has cost us a bit of performance but has
been compensated by the later tokenization changes (and been more than
made up for by VectorSet).

Memoization of File.list and File.getCanonicalPath doesn't seem to win
much, but before I remove it, I want to try it on a different OS.

followsymlinks=false costs a lot of performance, and it seems to suck
up memory as well - but this is completely due to
File.getCanonicalPath and I don't think there was anything we could
do.

Stefan

Raw test results to follow

Method
======

All tests run on the same machine (WinXP) with the same JDK (1.4).

For all tests < 60s the values are the median values of three
consecutive runs (but to tell the truth, in most cases all three runs
yielded the exact same results).

Times are what Ant reports itself when it says "Build finished",
memory numbers are the maximum values seen while watching the windows
task manager - which also means it is the total memory of the Java
process which could itself contain an empty heap.


Contestants:
============

Ant 1.6.5
Ant 1.7.0
Ant 1.7.1
trunk rev 687768        - PathPattern
trunk rev 693846        - pre loop detection
trunk rev 694254        - with loop detection
trunk rev 695389        - memoization of canonical path
trunk rev 696146        - more pre-tokenization work
trunk rev 696345        - full pre-tokenization, no File.list memo
trunk rev 696355        - bring back memoization of File.list
trunk rev 696674        - introduction of VectorSet

tests with default settings
===========================

matchall
--------

Ant 1.6.5               1 min 30 s      ~ 19 MB
Ant 1.7.0               3 min 53 s      ~ 24 MB
Ant 1.7.1                     10 s      ~ 14 MB
trunk rev 687768               9 s      ~ 19 MB
trunk rev 693846               9 s      ~ 30 MB
trunk rev 694254              10 s      ~ 41 MB
trunk rev 695389              10 s      ~ 39 MB
trunk rev 696146              11 s      ~ 39 MB
trunk rev 696345              10 s      ~ 41 MB
trunk rev 696355              10 s      ~ 43 MB
trunk rev 696674               6 s      ~ 44 MB

roots
-----

Ant 1.6.5                      1 s      ~ 14 MB
Ant 1.7.0                      3 s      ~ 12 MB
Ant 1.7.1                      0 s      ~ ?? MB
trunk rev 687768               0 s      ~ ?? MB
trunk rev 693846               0 s      ~ ?? MB
trunk rev 694254               0 s      ~ ?? MB
trunk rev 695389               0 s      ~ ?? MB
trunk rev 696146               0 s      ~ ?? MB
trunk rev 696345               0 s      ~ ?? MB
trunk rev 696355               0 s      ~ ?? MB
trunk rev 696674               0 s      ~ ?? MB

recursive-excludes
------------------

Ant 1.6.5                      8 s      ~ 19 MB
Ant 1.7.0                     16 s      ~ 16 MB
Ant 1.7.1                      3 s      ~ 14 MB
trunk rev 687768               3 s      ~ 14 MB
trunk rev 693846               3 s      ~ 24 MB
trunk rev 694254               4 s      ~ 29 MB
trunk rev 695389               4 s      ~ 28 MB
trunk rev 696146               4 s      ~ 28 MB
trunk rev 696345               4 s      ~ 27 MB
trunk rev 696355               4 s      ~ 28 MB
trunk rev 696674               3 s      ~ 31 MB

name-matches
------------

Ant 1.6.5                     11 s      ~ 19 MB
Ant 1.7.0                     28 s      ~ 17 MB
Ant 1.7.1                      3 s      ~ 15 MB
trunk rev 687768               3 s      ~ 14 MB
trunk rev 693846               4 s      ~ 31 MB
trunk rev 694254               5 s      ~ 32 MB
trunk rev 695389               5 s      ~ 34 MB
trunk rev 696146               5 s      ~ 38 MB
trunk rev 696345               4 s      ~ 29 MB
trunk rev 696355               5 s      ~ 30 MB
trunk rev 696674               3 s      ~ 35 MB

many-patterns
-------------

Ant 1.6.5                      7 s      ~ 19 MB
Ant 1.7.0                     13 s      ~ 17 MB
Ant 1.7.1                      4 s      ~ 17 MB
trunk rev 687768               3 s      ~ 14 MB
trunk rev 693846               4 s      ~ 20 MB
trunk rev 694254               4 s      ~ 23 MB
trunk rev 695389               4 s      ~ 24 MB
trunk rev 696146               4 s      ~ 25 MB
trunk rev 696345               4 s      ~ 29 MB
trunk rev 696355               4 s      ~ 25 MB
trunk rev 696674               3 s      ~ 26 MB

all
---

Ant 1.6.5               1 min 49 s      ~ 30 MB
Ant 1.7.0               4 min 54 s      ~ 44 MB
Ant 1.7.1                     19 s      ~ 43 MB
trunk rev 687768              18 s      ~ 43 MB
trunk rev 693846              19 s      ~ 42 MB
trunk rev 694254              21 s      ~ 43 MB
trunk rev 695389              21 s      ~ 44 MB
trunk rev 696146              21 s      ~ 47 MB
trunk rev 696345              20 s      ~ 47 MB
trunk rev 696355              20 s      ~ 49 MB
trunk rev 696674              11 s      ~ 52 MB

Case-insensitive scan
=====================

all
---

Ant 1.6.5               1 min 49 s      ~ 30 MB
Ant 1.7.0               4 min 53 s      ~ 44 MB
Ant 1.7.1                     19 s      ~ 44 MB
trunk rev 687768              19 s      ~ 43 MB
trunk rev 693846              20 s      ~ 42 MB
trunk rev 694254              21 s      ~ 47 MB
trunk rev 695389              21 s      ~ 46 MB
trunk rev 696146              21 s      ~ 53 MB
trunk rev 696345              20 s      ~ 47 MB
trunk rev 696355              20 s      ~ 48 MB
trunk rev 696674              11 s      ~ 51 MB

No followSymlinks
=================

all
---

Ant 1.6.5               2 min 20 s      ~ 67 MB
Ant 1.7.0               5 min 30 s      ~ 71 MB
Ant 1.7.1                     45 s      ~ 71 MB
trunk rev 687768              40 s      ~ 70 MB
trunk rev 693846              43 s      ~ 71 MB
trunk rev 694254              43 s      ~ 72 MB
trunk rev 695389              43 s      ~ 71 MB
trunk rev 696146              43 s      ~ 70 MB
trunk rev 696345              41 s      ~ 71 MB
trunk rev 696355              42 s      ~ 73 MB
trunk rev 696674              29 s      ~ 73 MB

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message