From 26c03e3257824a2cf829230ee121c0584b84465d Mon Sep 17 00:00:00 2001 From: Taras Glek Date: Thu, 6 May 2010 09:26:05 +0200 Subject: [PATCH] Bug 418866 - Set the proper gcc flags for pgo on Linux [r=ted.mielczarek] --- configure.in | 6 +++--- js/src/configure.in | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/configure.in b/configure.in index c43ce7c19dab..744b2e2fec5e 100644 --- a/configure.in +++ b/configure.in @@ -2100,7 +2100,7 @@ ia64*-hpux*) # -Os is broken on gcc 4.1.x and 4.2.x, we need to tweak it to get good results. MOZ_OPTIMIZE_SIZE_TWEAK="-finline-limit=50" esac - MOZ_OPTIMIZE_FLAGS="-Os -freorder-blocks -fno-reorder-functions -fomit-frame-pointer $MOZ_OPTIMIZE_SIZE_TWEAK" + MOZ_OPTIMIZE_FLAGS="-Os -freorder-blocks -fomit-frame-pointer $MOZ_OPTIMIZE_SIZE_TWEAK" MOZ_DEBUG_FLAGS="-g" fi @@ -7522,7 +7522,7 @@ MOZ_PROFILE_GUIDED_OPTIMIZE_DISABLE=) AC_SUBST(MOZ_PROFILE_GUIDED_OPTIMIZE_DISABLE) _SAVE_CFLAGS="$CFLAGS" -CFLAGS="$CFLAGS -fprofile-generate" +CFLAGS="$CFLAGS -fprofile-generate -fprofile-correction" AC_MSG_CHECKING([whether C compiler supports -fprofile-generate]) AC_TRY_COMPILE([], [return 0;], @@ -7532,7 +7532,7 @@ AC_MSG_RESULT([$result]) if test $result = "yes"; then PROFILE_GEN_LDFLAGS="-fprofile-generate" - PROFILE_USE_CFLAGS="-fprofile-use" + PROFILE_USE_CFLAGS="-fprofile-use -fprofile-correction -Wcoverage-mismatch -freorder-blocks-and-partition" PROFILE_USE_LDFLAGS="-fprofile-use" else CFLAGS="$_SAVE_CFLAGS -fprofile-arcs" diff --git a/js/src/configure.in b/js/src/configure.in index 0f8f11cae4d0..1375d0306095 100644 --- a/js/src/configure.in +++ b/js/src/configure.in @@ -4636,7 +4636,7 @@ MOZ_PROFILE_GUIDED_OPTIMIZE_DISABLE=) AC_SUBST(MOZ_PROFILE_GUIDED_OPTIMIZE_DISABLE) _SAVE_CFLAGS="$CFLAGS" -CFLAGS="$CFLAGS -fprofile-generate" +CFLAGS="$CFLAGS -fprofile-generate -fprofile-correction" AC_MSG_CHECKING([whether C compiler supports -fprofile-generate]) AC_TRY_COMPILE([], [return 0;], @@ -4646,7 +4646,7 @@ AC_MSG_RESULT([$result]) if test $result = "yes"; then PROFILE_GEN_LDFLAGS="-fprofile-generate" - PROFILE_USE_CFLAGS="-fprofile-use" + PROFILE_USE_CFLAGS="-fprofile-use -fprofile-correction -Wcoverage-mismatch -freorder-blocks-and-partition" PROFILE_USE_LDFLAGS="-fprofile-use" else CFLAGS="$_SAVE_CFLAGS -fprofile-arcs"