Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id E8CAE431FAF for ; Mon, 10 Dec 2012 20:50:50 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.7 X-Spam-Level: X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hiAg7Uy5Gn1o for ; Mon, 10 Dec 2012 20:50:48 -0800 (PST) Received: from dmz-mailsec-scanner-1.mit.edu (DMZ-MAILSEC-SCANNER-1.MIT.EDU [18.9.25.12]) by olra.theworths.org (Postfix) with ESMTP id A0B88431FAE for ; Mon, 10 Dec 2012 20:50:48 -0800 (PST) X-AuditID: 1209190c-b7f886d000000936-85-50c6bba8f888 Received: from mailhub-auth-1.mit.edu ( [18.9.21.35]) by dmz-mailsec-scanner-1.mit.edu (Symantec Messaging Gateway) with SMTP id 40.8A.02358.8ABB6C05; Mon, 10 Dec 2012 23:50:48 -0500 (EST) Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103]) by mailhub-auth-1.mit.edu (8.13.8/8.9.2) with ESMTP id qBB4olbh027660; Mon, 10 Dec 2012 23:50:47 -0500 Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91]) (authenticated bits=0) (User authenticated as amdragon@ATHENA.MIT.EDU) by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id qBB4ojhr023138 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); Mon, 10 Dec 2012 23:50:47 -0500 (EST) Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.80) (envelope-from ) id 1TiHnp-0003s8-Lc; Mon, 10 Dec 2012 23:50:45 -0500 From: Austin Clements To: david@tethera.net, notmuch@notmuchmail.org Subject: Re: [Patch v2 10/11] perf-test: split basic into 00-new and 01-dump-restore In-Reply-To: <1354762908-5788-11-git-send-email-david@tethera.net> References: <1354762908-5788-1-git-send-email-david@tethera.net> <1354762908-5788-11-git-send-email-david@tethera.net> User-Agent: Notmuch/0.14+159~g6895fee (http://notmuchmail.org) Emacs/23.4.1 (i486-pc-linux-gnu) Date: Mon, 10 Dec 2012 23:50:45 -0500 Message-ID: <87hantnqe2.fsf@awakening.csail.mit.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpgleLIzCtJLcpLzFFi42IR4hRV1l2x+1iAwesr3BYbl/1ktrjR2s1o cf3mTGYHZo9fbXOZPZ6tusXsseXQe+YA5igum5TUnMyy1CJ9uwSujKVTTjMV/JOv+PRtPmsD 413JLkZODgkBE4nvez6xQthiEhfurWfrYuTiEBLYxyhxuqmdFcLZwCix6MEJFgjnIpPEv5N3 mSCcJYwS06/9YgbpZxPQl1ixdhJQCweHiICexMKtMiBhZgE1iUlrzrCD2MICIRKbpj8G6mXn 4BRwkrigBBIVEiiT2ND6jg2kUVQgXmL2OR+QMIuAqsSvi6/YQGxeoDs7l/UyQdiCEidnPmGB GK4lcePfS6YJjIKzkKRmIUktYGRaxSibklulm5uYmVOcmqxbnJyYl5dapGuol5tZopeaUrqJ ERy4kjw7GN8cVDrEKMDBqMTDW6F6LECINbGsuDL3EKMkB5OSKO+BXUAhvqT8lMqMxOKM+KLS nNTiQ4wSHMxKIryluUA53pTEyqrUonyYlDQHi5I47+WUm/5CAumJJanZqakFqUUwWRkODiUJ 3vkgQwWLUtNTK9Iyc0oQ0kwcnCDDeYCGHwOp4S0uSMwtzkyHyJ9i1OWYM7P9CaMQS15+XqqU OO8+kCIBkKKM0jy4ObCE84pRHOgtYd7lIFU8wGQFN+kV0BImoCUnBQ+DLClJREhJNTCKLlNu Va/f/a+Nbdtfl40qXx9WbfSVa3ba5OSquuaC9eHXm19d4TsQ81FgkXRg1IwWGfennMp9fDca m1dmb84+uNLmbLmVvKMs+4qNfyMMmUM17qTsDTHzKjk03/G5Z8fSvZKbb3gFiSskXvP7LL3g iM0i16y0JRPemhWv3jr3aKyMgZ3QXRslluKMREMt5qLiRAC0ymHPEwMAAA== Cc: David Bremner X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Dec 2012 04:50:51 -0000 On Wed, 05 Dec 2012, david@tethera.net wrote: > From: David Bremner > > We rely on subsequent "notmuch new" invocations being relatively fast > rather than trying to detect if notmuch-new needs to be run. > --- > performance-test/00-new | 21 +++++++++++++++++++++ > performance-test/01-dump-restore | 15 +++++++++++++++ > performance-test/README | 8 ++++++-- > performance-test/basic | 20 -------------------- > performance-test/notmuch-perf-test | 3 ++- > 5 files changed, 44 insertions(+), 23 deletions(-) > create mode 100755 performance-test/00-new > create mode 100755 performance-test/01-dump-restore > delete mode 100755 performance-test/basic > > diff --git a/performance-test/00-new b/performance-test/00-new > new file mode 100755 > index 0000000..02db874 > --- /dev/null > +++ b/performance-test/00-new > @@ -0,0 +1,21 @@ > +#!/bin/bash > + > +test_description='notmuch new' > + > +. ./perf-test-lib.sh > + > +uncache_database > + > +add_email_corpus > + > +print_header > + > +time_run 'initial notmuch new' 'notmuch new' > + > +cache_database > + > +for i in $(seq 2 6); do > + time_run "notmuch new #$i" 'notmuch new' > +done > + > +time_done > diff --git a/performance-test/01-dump-restore b/performance-test/01-dump-restore > new file mode 100755 > index 0000000..09444e3 > --- /dev/null > +++ b/performance-test/01-dump-restore > @@ -0,0 +1,15 @@ > +#!/bin/bash > + > +test_description='Dump and restore' > + > +. ./perf-test-lib.sh > + > +add_email_corpus > + > +print_header > + > +time_run 'notmuch new' 'notmuch new' > +time_run 'dump *' 'notmuch dump > tags.out' > +time_run 'restore *' 'notmuch restore < tags.out' > + > +time_done > diff --git a/performance-test/README b/performance-test/README > index fd5c977..35489a9 100644 > --- a/performance-test/README > +++ b/performance-test/README > @@ -51,8 +51,8 @@ Each test script supports the following arguments > Writing tests > ------------- > > -Have a look at "basic" for an example. Sourcing "perf-test-lib.sh" is > -mandatory. Utility functions include > +Have a look at "01-dump-restore" for an example. Sourcing > +"perf-test-lib.sh" is mandatory. Utility functions include > > - 'add_email_corpus' unpacks a set of messages and adds them to the database. > - 'cache_database': makes a snapshot of the current database > @@ -60,3 +60,7 @@ mandatory. Utility functions include > database. > - 'time_done' does the cleanup; comment it out or pass --debug to the > script to leave the temporary files around. > + > +Scripts are run in the order specified in notmuch-perf-test. In the > +future this order might be chosen automatically so please follow the > +convention of starting the name with two digits to specify the order. > diff --git a/performance-test/basic b/performance-test/basic > deleted file mode 100755 > index 41a7ff1..0000000 > --- a/performance-test/basic > +++ /dev/null > @@ -1,20 +0,0 @@ > -#!/bin/bash > - > -. ./perf-test-lib.sh > - > -uncache_database > - > -add_email_corpus > - > -print_header > - > -time_run 'initial notmuch new' 'notmuch new' > - > -cache_database > - > -time_run 'second notmuch new' 'notmuch new' > -time_run 'dump *' 'notmuch dump > tags.out' > -time_run 'restore *' 'notmuch restore < tags.out' > -time_run 'tag * +new_tag' "notmuch tag +new_tag '*'" Did you mean to lose the tag-everything test? > - > -time_done > diff --git a/performance-test/notmuch-perf-test b/performance-test/notmuch-perf-test > index 1bea345..f93d8a4 100755 > --- a/performance-test/notmuch-perf-test > +++ b/performance-test/notmuch-perf-test > @@ -17,7 +17,8 @@ fi > cd $(dirname "$0") > > TESTS=" > - basic > + 00-new > + 01-dump-restore > " > > for test in $TESTS; do > -- > 1.7.10.4 > > _______________________________________________ > notmuch mailing list > notmuch@notmuchmail.org > http://notmuchmail.org/mailman/listinfo/notmuch