What information does GCC Profile Guided Optimization (PGO) collect and which optimizations use it?

前端 未结 2 1508
滥情空心
滥情空心 2020-12-04 23:53

Which information does GCC collect when I enable -fprofile-generate and which optimization does in fact uses the collected information (when setting the -

2条回答
  •  执念已碎
    2020-12-05 00:37

    -fprofile-generate enables -fprofile-arcs, -fprofile-values and -fvpt.

    -fprofile-use enables -fbranch-probabilities, -fvpt, -funroll-loops, -fpeel-loops and -ftracer

    Source: http://gcc.gnu.org/onlinedocs/gcc-4.7.2/gcc/Optimize-Options.html#Optimize-Options

    PS. Information about LTO also on that page.

提交回复
热议问题