Replies: 2 comments 2 replies
-
C++ takes ages to compile. Colour me surprised. |
Beta Was this translation helpful? Give feedback.
0 replies
-
I guess the interesting parts are things that are not C++, like LZ4. On the other hand, I would rather pay extra compilation time for parson (also on one of the lists) than glue (and in the future parse) JSON myself, hoping to do better. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I recently learned about ClangBuildAnalyzer, a tool that helps parsing the json files generated by clang's
-ftime-trace
, contributed by the same author and landed in Clang 9 in Sept 2019. https://aras-p.info/blog/2019/01/16/time-trace-timeline-flame-chart-profiler-for-Clang/I was curious on what is taking time in our builds on the C/C++ side, if ever there were some optimizations possible.
I built ClangBuildAnalyzer from source with CMake, from the main branch at aras-p/ClangBuildAnalyzer@fc7ff35
I then did:
Profile files:
The files that can be individually opened in
chrome://tracing
are the json files next to the object files. they aren't uploaded here.There are way less interesting details on object files that weren't C++.
I was using clang 18.1.8:
Summary as colored screenshots
From first run:
The json file for v.in.pdal's main.o compilation (one of the longest to parse), opened in
chrome://tracing
:Summary as text (first run)
Summary as text (run 2)
Other interesting reads:
Beta Was this translation helpful? Give feedback.
All reactions