|
Boost-Build : |
From: Vladimir Prus (ghost_at_[hidden])
Date: 2004-11-18 02:16:25
On Wednesday 17 November 2004 19:56, Rene Rivera wrote:
> Vladimir Prus wrote:
> > On Wednesday 17 November 2004 11:30, Rene Rivera wrote:
> >>Modified Files:
> >> allyourbase.jam boost-base.jam
> >>Log Message:
> >>Fix extra updates on targets when a header has the same name as a
> >> directory which is in the headers search path.
> >>
> >>+ if ! [ GLOB "$(bound-path)" : * ]
> >>+ {
> >>+ header-locate = $(bound-path) ;
> >>+ }
> >
> > Rene, did you do any performance testing of this patch? This seems to me
> > a pretty easy way to kill performance. FWIW, I've spend some time
> > removing any loops from V2 header scanning because of performance
> > reasons.
>
> It will definitely make things slower...
Yikes, I also recall that GLOB iterates over all elements in a directory,
which is pretty slow way to check for a file.
> And there are ways to make it
> faster. But this is BBv1 so the lifetime is limited, it can be improved
> with some caching if needed. I expect that we can come up with a much
> better fix for BBv2. Most likely adding some Jam native rule to handle
> this.
Ok, that's what I'll do.
> While working on this I noticed a rather slow aspect of the way binding
> works in Jam. If a binding does not already exist it will do directory
> scans every time to search for a binding. That should be a candidate for
> caching, no point in scanning the same directories over and over for
> each target.
Are you sure? What about this code in timestamp.c:
if( !( b->flags & BIND_SCANNED ) )
{
file_dirscan( buf->value, time_enter, bindhash );
b->flags |= BIND_SCANNED;
}
}
?
- Volodya
Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk