> That's the thing, it is hard to measure the impact of bad dependencies unless > you compare the same code with bad and good dependencies (which would > mean spending the time to fix existing code), or have already experienced it > in another project, or even trust what people say on the internet about this > subject.
But it sounds like you have some data, e.g. from dzbarsky's earlier work? What are the results of your preliminary experiments? On Wed, Aug 8, 2012 at 3:36 PM, Nicolas Silva <[email protected]> wrote: > On 08/08/2012 02:27 PM, Benjamin Smedberg wrote: >> >> On 8/8/2012 2:09 PM, Nicolas Silva wrote: >>> >>> Hi dev-platform, >>> >>> I spent some time looking at include dependencies lately, and I think it >>> is an area where we can improve our code without too much effort. >>> Bad include dependencies lead to slower builds. >> >> What kind of evidence do we have for this? Before spending time tinkering >> with removing includes, I think we need to understand whether it's worth it: >> unless there is a clear and significant improvement, there are many other >> things we could be doing which are probably more valuable. And if there are >> significant wins to be had, should we instead be considering using >> module-wide includes and precompiled headers? >> >> --BDS >> > That's the thing, it is hard to measure the impact of bad dependencies > unless you compare the same code with bad and good dependencies (which would > mean spending the time to fix existing code), or have already experienced it > in another project, or even trust what people say on the internet about this > subject. > > Right now I think our build times could benefit more from a better build > system than fixing our include dependencies, if you ask me. > > what I propose is to pay attention to these details when adding new code, > because it does not take more time to write these things the right way. With > the example of nsRefPtr, I think the problem is that a lot of people didn't > know it was possible to use forward references with ref pointers. > > I have an ugly script that goes through the dependency files generated by > make to collect informations about dependencies. I'll clean it up if you are > interested (and rewrite it in python because I suppose people in here don't > want to deal with D code). > > I think it would help even with module-wide includes because most > translation units include headers from several other modules. Here is a list > of the TUs that include 2D.h (as of last Wednesday) on a Linux debug build: > http://pastebin.mozilla.org/1745045 > A lot of them have nothing to do with graphics. > > Nicolas Silva > > || > _______________________________________________ > dev-platform mailing list > [email protected] > https://lists.mozilla.org/listinfo/dev-platform _______________________________________________ dev-platform mailing list [email protected] https://lists.mozilla.org/listinfo/dev-platform

