This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Disable ipa-reference with -fprofile-arcs
- From: Jan Hubicka <hubicka at ucw dot cz>
- To: gcc-patches at gcc dot gnu dot org, rguenther at suse dot de
- Date: Mon, 10 Jan 2011 00:01:17 +0100
- Subject: Disable ipa-reference with -fprofile-arcs
Hi,
this patch workarounds problems with ipa-reference and profile feedback.
Profile feedback adds static var access into every function in program.
Especially with LTO this makes ipa-reference tables to explode. It is the case
for Mozilla build where LTO -fprofile-generate OOms for me after allocating 9GB
of bitmaps.
lto-Profilebootstrapped/regtested x86_64-linux, OK?
Honza
PR tree-optimization/47233
* opts.c (common_handle_option): Disable ipa-reference with profile feedback.
Index: opts.c
===================================================================
--- opts.c (revision 168596)
+++ opts.c (working copy)
@@ -1561,6 +1561,11 @@ common_handle_option (struct gcc_options
opts->x_flag_value_profile_transformations = value;
if (!opts_set->x_flag_inline_functions)
opts->x_flag_inline_functions = value;
+ /* FIXME: Instrumentation we insert makes ipa-reference bitmaps
+ quadratic. Disable the pass until better memory representation
+ is done. */
+ if (!opts_set->x_flag_ipa_reference)
+ opts->x_flag_ipa_reference = false;
break;
case OPT_fshow_column: