From: "Marco Costalba" <mcostalba@gmail.com>
To: "Linus Torvalds" <torvalds@osdl.org>
Cc: "Johannes Schindelin" <Johannes.Schindelin@gmx.de>,
"Shawn Pearce" <spearce@spearce.org>,
"Git Mailing List" <git@vger.kernel.org>
Subject: Re: Fast access git-rev-list output: some OS knowledge required
Date: Thu, 7 Dec 2006 07:46:05 +0100 [thread overview]
Message-ID: <e5bfff550612062246m194ce235nf97149f8b041f486@mail.gmail.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0612061642440.3542@woody.osdl.org>
On 12/7/06, Linus Torvalds <torvalds@osdl.org> wrote:
>
>
> On Thu, 7 Dec 2006, Johannes Schindelin wrote:
> >
> > Because, depending on what you do, the revision machinery is not
> > reentrable. For example, if you filter by filename, the history is
> > rewritten in-memory to simulate a history where just that filename was
> > tracked, and nothing else. These changes are not cleaned up after calling
> > the internal revision machinery.
>
> Well, it really wouldn't be that hard to add a new library interface to
> "reset object state". We could fairly trivially either:
>
So the library approach sounds like the best?
Of course in this case the producer git-rev-list and the receiver use
the same address space.
In the case of a temporary file data is first copied to OS disk cache
buffers and then again to userspace, in qgit address space. But the
real pain is that the temporary file is always flushed to disk after
4-5 seconds from creation, also if under heavy read/write activity.
This is a problem for big repos. I really don't know how to workaround
this useless disk flush.
Finally, what about using some kind of shared memory at run time,
instead of _sharing_ developer libraries ;-) ? is it too messy?
Probably the concurrent reading while writing is possible without
syncro if the reader understands that a sequence of _two_ or more \0
it means the end of current write stream if producer is still running
or the end of data if producer is not running anymore. I use a similar
approach in the 'temporary file' patch where receiver is able to read
while producer writes without explicit synchronization. In that case a
read() of a block smaller then maximum with producer still running is
used as the 'break' condition in the receiver while loop.
prev parent reply other threads:[~2006-12-07 6:46 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-06 19:24 Fast access git-rev-list output: some OS knowledge required Marco Costalba
2006-12-06 19:28 ` Shawn Pearce
2006-12-06 19:34 ` Marco Costalba
2006-12-06 19:42 ` Shawn Pearce
2006-12-06 19:51 ` Shawn Pearce
2006-12-06 20:08 ` Marco Costalba
2006-12-06 20:18 ` Shawn Pearce
2006-12-07 13:25 ` Andreas Ericsson
2006-12-07 14:53 ` Johannes Schindelin
2006-12-07 15:28 ` Andreas Ericsson
2006-12-07 16:01 ` Johannes Schindelin
2006-12-08 18:34 ` Marco Costalba
2006-12-08 20:10 ` Michael K. Edwards
2006-12-09 12:15 ` Marco Costalba
2006-12-06 23:27 ` Johannes Schindelin
2006-12-07 0:47 ` Linus Torvalds
2006-12-07 6:46 ` Marco Costalba [this message]
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=e5bfff550612062246m194ce235nf97149f8b041f486@mail.gmail.com \
--to=mcostalba@gmail.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
--cc=spearce@spearce.org \
--cc=torvalds@osdl.org \
/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).