[darcs-users] Google Summer of Code 2010

Benedikt Schmidt beschmi at gmail.com
Tue Mar 9 14:37:26 UTC 2010

Hi all,

[it seems like my last mail got lost]

Benedikt Schmidt wrote:
> Reinier Lamers wrote:
>> Op zondag 07 maart 2010 03:03 schreef Adolfo Builes:
>>> So, what do you guys think about it ? At this stage I don't have
>>> really clear in what I
>>> should specifically work to improve "darcs annotate", but I'm sure We
>>> can have an
>>> interesting discussion here, which could help me to define, in what I 
>>> should
>>> specifically work if we want to see "darcs annotate" going faster.
>> AFAIK, what we need for a faster annotate is what we call a 
>> "filecache". By that we mean a data structure that will let us look up 
>> quickly which patches affect a given file. Benedikt Schmidt has been 
>> working on this for a long time. I don't know if this has resulted in 
>> some demo-able code yet.
>> Maybe you should ask him (beschmi at gmail) about the current state of 
>> this work and if it would be possible to make a GSoC project out of it.
> I have started porting the code to the newest unstable and ran into some 
> problems because Commands.Changes uses witnesses now. I have the feeling 
> that I need unsafe operations here if I only want to read the patches 
> that touch a certain file, but I have to investigate this further.
> I can give some more details later this week and of course after Zurihac.

I now have a version where optimize creates a filecache from
scratch and changes <filename> uses the filecache to avoid
reading unnecessary patches. So the following things are
missing now:

- annotate should use the cache. I think it would be best to
   have a function
   filterPatchSetTouching :: RepoPatch p => [FilePath]
     -> [PatchId] -> (PatchSet p) (C x y) -> (PatchSet p) (C x y)
   that returns a valid Patchset that only contains patches affecting
   the given files.
   Then, one could still use the original code, it would just be
   more efficient since it would work with a smaller repo.

- other repository operations should update the filecache

I'm not sure how far I/we'll get with these from the 19th to 21st
during Zurihac, but it seems like the basic functionality could
be finished before GSoC starts. I have sent a patch against current
unstable if anyone wants to check it out.


More information about the darcs-users mailing list