Hi, On Mon, 12 Feb 2007, Bruno Haible wrote: > Robin Rosenberg wrote: > > Since you know that you are not interested in the whole history, you can limit your scan. > > > > git log COREUTILS-5_2_1..COREUTILS-6_4 src/tr.c > > Thanks, that indeed does the trick: it reduces the time from 33 sec to 11 sec. > > To reduce the time even more, and to allow more flexibility among the > search criteria (e.g. "I need the commits from date X to date Y, on this > file set, from anyone except me"), I would need to connect git to a > database. git cannot store all kinds of indices and reverse mappings to > allow all kinds of queries; that's really a classical database > application area. [in the following paragraph, "index" means the index on a classical database table] And -- as everywhere else with classical databases -- you have to ask if it is worth it. Given the fact that a one-time use of such an index is _worse_ than doing it without index at all (building and writing the index is _at least_ as expensive as searching once without an index), I'd rather doubt it. However, if you do similar kinds of searches quite often, it makes tons of sense to connect to a database. We already use sqlite in cvsserver, so I'd try that. Ciao, Dscho - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html