[cfe-dev] Training files for building clang with PGO?

Justin Bogner via cfe-dev cfe-dev at lists.llvm.org
Thu Mar 16 13:09:42 PDT 2017


Alex Wang via cfe-dev <cfe-dev at lists.llvm.org> writes:
> Hi all! Quick question about building clang with PGO.
>
> I've found the documentation on this process somewhat unclear. I get
> that the source files used for training/profiling should go into
> <clang-path>/utils/perf-training, but I don't understand from where I
> am supposed to get those files. The single hello_world.cpp definitely
> isn't enough for PGO to be useful.
>
> Are the training files something that is to be added in the future? Or
> am I supposed to copy the training files from somewhere else? And if
> it's the latter, from where?

The idea is that you add representative inputs from workloads you care
about there. These can and do differ between different vendors of clang,
so it really depends on what you want your clang optimized for.


More information about the cfe-dev mailing list