On Mon, Apr 26, 2010 at 3:11 AM, Hambridge, Philip J (ODP)
<[email protected]> wrote:
...
> I’ve started to wonder about reducing the start-up time by placing all
> source dependencies in a per-directory .d file generated at the archive link
> stage and including this instead of including all the source .d files. A
> quick test verifies that this significantly reduces the start-up time due to
> make having to open far less files. I’ve yet to figure out quite what the
> implications are for ensuring the per-directory .d file gets updated
> correctly.
>
> Before I go any further, has anyone else done anything like this? If so,
> were there any pitfalls?

I haven't tried it, but the pitfall that made me shy away from it was
that if a build fails, you don't have the updated dependencies from
the most recent (incomplete) build for the files that did get built.
I.e., the build fails and the fix involves changing a header file that
was #included in sources that _did_ build successfully.  Will those
get rebuilt after you change the header?  Even if this was in a fresh
tree?

Then again, maybe that's only a problem if you try to update the
per-directory .d file at the end of the build instead of during the
start.  That is, don't try to generate the per-directory file as part
of building the archive library, but rather have make build it from
the existing .d files using rules and re-exec.


Philip Guenther


_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make

Reply via email to