From: Thomas Rast <trast@student.ethz.ch>
To: <git@vger.kernel.org>
Cc: "René Scharfe" <rene.scharfe@lsrfire.ath.cx>,
"Junio C Hamano" <gitster@pobox.com>,
"Eric Herman" <eric@freesa.org>
Subject: [POC PATCH 0/5] Threaded loose object and pack access
Date: Fri, 9 Dec 2011 09:39:32 +0100 [thread overview]
Message-ID: <cover.1323419666.git.trast@student.ethz.ch> (raw)
Well, just to make sure we're all left in a confused mess of partly
conflicting patches, here's another angle on the same thing:
Jeff King wrote:
> Wow, that's horrible. Leaving aside the parallelism, it's just terrible
> that reading from the cache is 20 times slower than the worktree. I get
> similar results on my quad-core machine.
By poking around in sha1_file.c I got that down to about 10. It's not
great yet, but it seems a start.
The goal would be to improve it to the point where a patch lookup that
already has all relevant packs open and windows mapped can proceed
without locking. I'm not sure that's doable short of duplicating the
whole pack state (including fds and windows) across threads, but I'll
give it some more thought before going that route.
Thomas Rast (5):
Turn grep's use_threads into a global flag
grep: push locking into read_sha1_*
sha1_file_name_buf(): sha1_file_name in caller's buffer
sha1_file: stuff various pack reading variables into a struct
sha1_file: make the pack machinery thread-safe
builtin/grep.c | 60 +++++-----------
cache.h | 1 +
replace_object.c | 5 +-
sha1_file.c | 213 +++++++++++++++++++++++++++++++++++++++++-------------
thread-utils.c | 30 ++++++++
thread-utils.h | 23 ++++++
6 files changed, 240 insertions(+), 92 deletions(-)
--
1.7.8.431.g2abf2
next reply other threads:[~2011-12-09 8:39 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-09 8:39 Thomas Rast [this message]
2011-12-09 8:39 ` [POC PATCH 1/5] Turn grep's use_threads into a global flag Thomas Rast
2011-12-09 8:39 ` [POC PATCH 2/5] grep: push locking into read_sha1_* Thomas Rast
2011-12-09 8:39 ` [POC PATCH 3/5] sha1_file_name_buf(): sha1_file_name in caller's buffer Thomas Rast
2011-12-09 8:39 ` [POC PATCH 4/5] sha1_file: stuff various pack reading variables into a struct Thomas Rast
2011-12-09 8:39 ` [POC PATCH 5/5] sha1_file: make the pack machinery thread-safe Thomas Rast
2012-04-09 14:43 ` Nguyen Thai Ngoc Duy
2012-04-10 12:29 ` Thomas Rast
2012-04-10 13:39 ` Nguyen Thai Ngoc Duy
2011-12-09 8:45 ` [POC PATCH 0/5] Threaded loose object and pack access Thomas Rast
2011-12-10 15:51 ` Nguyen Thai Ngoc Duy
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=cover.1323419666.git.trast@student.ethz.ch \
--to=trast@student.ethz.ch \
--cc=eric@freesa.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=rene.scharfe@lsrfire.ath.cx \
/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).