• tal@lemmy.today
    link
    fedilink
    English
    arrow-up
    4
    ·
    edit-2
    8 days ago

    I think that there’s a legit rejoinder of “Why aren’t you optimizing the code to reduce compilation time, if it’s such a problem?”

    For something like C++, ccache, distcc, PIMPL (to reduce use of templates, which blows up C++ compilation time), precompiled headers, make code more modular to reduce the size of the compilation unit that changes when any one change happens, break stuff into libraries, etc. Look to see whether there are things like build timestamps being inserted into headers that are producing unnecessary recompilations. clang and gcc can profile compilations to identify what’s chewing up time.