On 19 Dec 2020 10:10, H.J. Lu via Gdb-patches wrote:
> --- a/Makefile.in
> +++ b/Makefile.in
>
> +PGO_BUILD_TRAINING_FLAGS_TO_PASS = \
> + PGO_BUILD_TRAINING=yes \
> + CFLAGS_FOR_TARGET="$(PGO_BUILD_TRAINING_CFLAGS)" \
> + CXXFLAGS_FOR_TARGET="$(PGO_BUILD_TRAINING_CXXFLAGS)"
> +
> +# Ig
Add the --enable-pgo-build[=lto] configure option. When binutils+gdb
is not built together with GCC, --enable-pgo-build enables the PGO build:
1. First build with -fprofile-generate.
2. Use "make maybe-check-*" to generate profiling data and pass -i to make
to ignore errors when generating profil