git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Shawn Pearce <spearce@spearce.org>
To: Marco Costalba <mcostalba@gmail.com>
Cc: Git Mailing List <git@vger.kernel.org>
Subject: Re: Fast access git-rev-list output: some OS knowledge required
Date: Wed, 6 Dec 2006 14:51:42 -0500	[thread overview]
Message-ID: <20061206195142.GE20320@spearce.org> (raw)
In-Reply-To: <20061206194258.GD20320@spearce.org>

Shawn Pearce <spearce@spearce.org> wrote:
> I think all you may need is:
> 
> 	#include "revision.h"
> 	...

You'll also need to call:

	setup_git_directory();

before any of the below; but that should be done once per process.

> 	struct rev_info revs;
> 	init_revisions(&revs, prefix);
> 	revs.abbrev = 0;
> 	revs.commit_format = CMIT_FMT_UNSPECIFIED;
> 	argc = setup_revisions(argc, argv, &revs, NULL);

Although now that I think about it the library may not be enough
of a library.  Some data (e.g. commits) will stay in memory forever
once loaded.  Pack files won't be released once read; a pack recently
made available while the application is running may not get noticed.

Perhaps there is some fast IPC API supported by Qt that you could
use to run the revision listing outside of the main UI process,
to eliminate the bottlenecks you are seeing and remove the problems
noted above?  One that doesn't involve reading from a pipe I mean...

-- 

  reply	other threads:[~2006-12-06 19:51 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 [this message]
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

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=20061206195142.GE20320@spearce.org \
    --to=spearce@spearce.org \
    --cc=git@vger.kernel.org \
    --cc=mcostalba@gmail.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).