4 ms·
A big improvement in compile times with modern C++ can be had with C++20 standard modules. This requires extremely bleeding-edge toolchains, though: VS 2022 17
by delta_p_delta_x 2y ago
A big improvement in compile times with modern C++ can be had with C++20 standard modules.
This requires extremely bleeding-edge toolchains, though: VS 2022 17.10, Clang 18, and GCC 14.
- sfpotter 2y agoI'm under the impression "big" here might mean a 10-20% improvement if you're lucky. Good to back this claim up with hard data.
- celrod 2y agoI'm still waiting for clangd support, e.g. [0] before trying modules. But maybe I should just try it, as at least one person reports that it already works [1]. [0] https://github.com/clangd/clangd/issues/1293 https://github.com/clangd/clangd/issues/1293 [1] https://github.com/snu-sf-class/swpp202401/issues/21 https://github.com/snu-sf-class/swpp202401/issues/21
- jupp0r 2y agoYou know you are talking about C++ when "bleeding edge" is compilers from 3 years ago which implement the version before the current standard from 4 years ago....
- IAmLiterallyAB 2y agoClang 18 came out in March and GCC 14 isn't even out. So those are bleeding edge by just about any metric
- Longhanks 2y agoWell, ISO C++ is a standard, and the standard being finished does not mean the implementation being finished. Also, modules is probably one of the biggest changes in terms of work required in build systems, compilers and tooling since at least C++11.
- delta_p_delta_x 2y agoClang 18 was released this March, barely two months ago[1]; VS 2022 17.10 is still in preview[2], and GCC 14 isn't even out yet. This can't be nearer the bleeding edge. [1]: https://github.com/llvm/llvm-project/releases/tag/llvmorg-18.1.0 https://github.com/llvm/llvm-project/releases/tag/llvmorg-18... [2]: https://learn.microsoft.com/en-us/visualstudio/releases/2022/release-notes-preview#17100-pre50--visual-studio-2022-version-1710-preview-5 https://learn.microsoft.com/en-us/visualstudio/releases/2022...
- bdd8f1df777b 2y agoI'm still waiting for CMake support to mature.