I've been doing a lot of googling to figure out various ways I could analyze my include directives per translation unit to determine why my overall build is so slow. The entire project consists of around 800 translation units, and when combined with the number of header files we maintain and use (e.g. third party) it's difficult to track exactly what we're including at the top-level that may be included by most translation units being built that do not even need it. I feel like eliminating needless includes will help bring our build times down.
Can anyone suggest any techniques or tools that may be useful in analyzing unnecessary includes? For example, maybe something that prints which headers are included the most in descending order across the whole project build (all translation units)? It would be even better if such a tool could provide statistics such as " included by 600 translation units and not needed by 90% of them". I do not want to use precompiled headers, so I feel like this is my only option (eliminate unnecessary includes and redesign headers to make use of the pimpl idiom to improve build times).
Note I'm using clang as my compiler on linux & android (NDK). I also build with MSVC on the Windows platform.