From: "Catalin Marinas" <catalin.marinas@gmail.com>
To: "Karl Hasselström" <kha@treskal.com>
Cc: git@vger.kernel.org
Subject: Re: [StGIT PATCH] Don't use patches/<branch>/current
Date: Thu, 17 May 2007 13:43:35 +0100 [thread overview]
Message-ID: <b0943d9e0705170543g4d8c7542p6b44a4e6fa54676a@mail.gmail.com> (raw)
In-Reply-To: <20070516204029.GB17805@diana.vm.bytemark.co.uk>
[-- Attachment #1: Type: text/plain, Size: 1483 bytes --]
On 16/05/07, Karl Hasselström <kha@treskal.com> wrote:
> I set up a kernel repository with 100 applied and 100 unapplied
> patches:
[...]
> Then repeatedly:
>
> $ time stg series >/dev/null
I ran 'git repack -a -d' and 'git prune'. There are no other objects
apart from the generated pack:
$ du -sh .git
211M .git
And then repeatedly 'time stg series > /dev/null':
real 0m1.638s
user 0m1.422s
sys 0m0.088s
real 0m2.542s
user 0m1.436s
sys 0m0.078s
real 0m2.916s
user 0m1.424s
sys 0m0.083s
real 0m2.940s
user 0m1.425s
sys 0m0.081s
real 0m1.614s
user 0m1.421s
sys 0m0.081s
real 0m1.587s
user 0m1.423s
sys 0m0.081s
real 0m2.653s
user 0m1.427s
sys 0m0.075s
> But my kernel repository is _much_ smaller than yours:
>
> $ du -sh .git
> 183M .git
>
> Do you perchance have a bunch of loose objects in there?
It got smaller after repacking but it is still bigger than yours.
Maybe the reason is that I have 14 branches with various patches, some
of them just for historical reasons but going back to 2.6.12. There
are also several commits generated for the patch logs.
The CPU is a P4 at 2.5GHz and the 'stg series' operation seems to be
CPU bound rather than IO. I'm also using Python 2.3 on this PC and for
this reason I changed 2 generator constructs (x for x in ...) with
list comprehension (see the attached patch).
--
Catalin
[-- Attachment #2: list-comprehension.patch --]
[-- Type: text/x-patch, Size: 1101 bytes --]
commit f7cc1f7fa6b2ee4f42e812970760ba5db5d2cafc
Author: Catalin Marinas <catalin.marinas@gmail.com>
Date: Wed May 16 13:08:45 2007 +0100
refresh b5003aa7bb5ec384e1dbe2887c07885a791384c2
diff --git a/stgit/stack.py b/stgit/stack.py
index 13eb692..0ef26b8 100644
--- a/stgit/stack.py
+++ b/stgit/stack.py
@@ -349,8 +349,8 @@ def unapplied_patches(ref2hash):
unapplied = Set()
for line in git._output_lines(
'git-rev-list --stdin',
- ('%s%s\n' % (['', '^'][ref == None], sha1)
- for ref, sha1 in ref2hash.iteritems())):
+ ['%s%s\n' % (['', '^'][ref == None], sha1)
+ for ref, sha1 in ref2hash.iteritems()]):
for ref in hash2refs.get(line.strip(), []):
unapplied.add(ref)
return unapplied
@@ -364,7 +364,7 @@ def sort_applied_patches(ref2hash):
if r != None:
hash2refs.setdefault(h, Set()).add(r)
- missing = Set(ref for ref in ref2hash.iterkeys() if ref != None)
+ missing = Set([ref for ref in ref2hash.iterkeys() if ref != None])
if not missing:
return []
applied = []
next prev parent reply other threads:[~2007-05-17 12:43 UTC|newest]
Thread overview: 51+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-06 15:13 [StGIT PATCH] Don't use patches/<branch>/current Karl Hasselström
2007-05-15 15:56 ` Catalin Marinas
2007-05-15 16:21 ` Peter Oberndorfer
2007-05-15 16:50 ` Catalin Marinas
2007-05-15 18:25 ` Karl Hasselström
2007-05-15 19:38 ` [StGIT PATCH] Remove obsolete files when deleting a branch Karl Hasselström
2007-05-15 20:01 ` [StGIT PATCH] Don't use patches/<branch>/current Catalin Marinas
2007-05-16 7:11 ` Karl Hasselström
2007-05-16 12:07 ` Catalin Marinas
2007-05-16 19:40 ` Karl Hasselström
2007-05-16 20:40 ` Karl Hasselström
2007-05-17 12:43 ` Catalin Marinas [this message]
2007-05-17 14:57 ` Karl Hasselström
2007-05-17 20:51 ` Catalin Marinas
2007-05-18 6:30 ` Karl Hasselström
2007-06-10 9:54 ` [StGIT PATCH 0/6] New and improved DAG appliedness series Karl Hasselström
2007-06-10 9:54 ` [StGIT PATCH 1/6] Verify patch status during the test Karl Hasselström
2007-06-10 9:55 ` [StGIT PATCH 2/6] Make use of the get_patch() utility function Karl Hasselström
2007-06-10 9:55 ` [StGIT PATCH 3/6] Compute patch appliedness from commit DAG Karl Hasselström
2007-06-10 9:55 ` [StGIT PATCH 4/6] Test the new DAG appliedness machinery Karl Hasselström
2007-06-10 9:55 ` [StGIT PATCH 5/6] Fix bash completion after the DAG appliedness patch Karl Hasselström
2007-06-10 9:55 ` [StGIT PATCH 6/6] Speed up the appliedness test Karl Hasselström
2007-06-30 19:54 ` [StGIT PATCH 0/6] New and improved DAG appliedness series Yann Dirson
2007-07-01 14:35 ` Karl Hasselström
2007-05-15 21:08 ` [StGIT PATCH] Don't use patches/<branch>/current Yann Dirson
2007-05-15 21:36 ` Catalin Marinas
2007-05-15 21:49 ` Yann Dirson
2007-05-16 6:27 ` Karl Hasselström
2007-05-19 0:09 ` [StGIT PATCH 0/5] Metadata format versioning Karl Hasselström
2007-05-19 0:09 ` [StGIT PATCH 1/5] Fix config caching so that get, set, get works Karl Hasselström
2007-05-19 0:09 ` [StGIT PATCH 2/5] Have only a single command in each test_expect_failure Karl Hasselström
2007-05-19 0:10 ` [StGIT PATCH 3/5] Upgrade old StGIT branches to new-format metadata Karl Hasselström
2007-05-19 0:10 ` [StGIT PATCH 4/5] Test the format version upgrade code Karl Hasselström
2007-05-19 0:10 ` [StGIT PATCH 5/5] Add --binary flag to commands that generate diffs Karl Hasselström
2007-05-22 12:15 ` Catalin Marinas
2007-05-22 13:31 ` Karl Hasselström
2007-05-20 20:03 ` [StGit PATCH 0/2] Bash prompt updates Robin Rosenberg
2007-05-20 20:04 ` [StGit PATCH 1/2] Update the bash prompt from 'applied' instead of the obsolete 'current' Robin Rosenberg
2007-05-20 20:46 ` Yann Dirson
2007-05-20 21:22 ` [PATCH " Robin Rosenberg
2007-05-21 7:48 ` Karl Hasselström
2007-05-21 9:31 ` Catalin Marinas
2007-05-21 10:15 ` Karl Hasselström
2007-05-21 11:39 ` Karl Hasselström
2007-05-21 15:17 ` Catalin Marinas
2007-05-21 15:39 ` Karl Hasselström
2007-05-22 12:11 ` Catalin Marinas
2007-05-22 13:29 ` Karl Hasselström
2007-05-21 18:57 ` Yann Dirson
2007-05-20 21:24 ` [PATCH 2/2] Don't use / as separatar since it is common i branch names Robin Rosenberg
2007-05-20 20:04 ` [StGit PATCH " Robin Rosenberg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b0943d9e0705170543g4d8c7542p6b44a4e6fa54676a@mail.gmail.com \
--to=catalin.marinas@gmail.com \
--cc=git@vger.kernel.org \
--cc=kha@treskal.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).