3 ms·
Can someone using modules chime in on whether they’ve seen build times improve?
by cmovq 9mo ago
Can someone using modules chime in on whether they’ve seen build times improve?
- nickelpro 9mo agoimport std; is an order of magnitude faster than using the STL individually, if that's evidence enough for you. It's faster than #include <iostream> alone. Chuanqi says "The data I have obtained from practice ranges from 25% to 45%, excluding the build time of third-party libraries, including the standard library."[1] [1]: https://chuanqixu9.github.io/c++/2025/08/14/C++20-Modules.en.html#how-much-compile-time-can-c20-modules-save https://chuanqixu9.github.io/c++/2025/08/14/C++20-Modules.en...
- luke5441 9mo agoYeah, but now compare this to pre-compiled headers. Maybe we should be happy with getting a standard way to have pre-compiled std headers, but now my build has a "scanning" phase which takes up some time.
- direwolf20 9mo agoModules are a lot like precompiled headers, but done properly and not as a hack.
- nickelpro 9mo agoThe OP does this and measures ~1.2x improvement over PCH.
- vitaut 9mo agoWe did see build time improvements from deploying modules at Meta.