On Tue, 1 Dec 2015, Jan Hubicka wrote: > > Hi, > > this is polished version of the patch to implement IL level incremental > > inking. > > -flinker-output is now documented and can be specified to the GCC driver. > > In this case plugin gets option -linker-output-known and it stops from > > attempts to detect it from info passed down by linker. I also added doc for > > the flag to invoke.texi > > > > Modulo the testsuite compensation the rest of patch is basically unchanged > > since earlier version: lto-wrapper looks for linker-output flag and > > switches to > > non-WPA mode (because we do not want to execute ltrans compilatoins) and lto > > frontends configure the compiler to output IL and possibly flat lto binary > > to > > the object file. > > > > Bootstrapped/regtested x86_64-linux, OK? > Hmm and now for the fun part. I just noticed that the patch works well with > both > GNU LD and Gold from my system instalation, wich is > > GNU gold (GNU Binutils 2.24.51.20140405) 1.11 > > while newer version: > > GNU gold (GNU Binutils 2.25.51.20150520) 1.11 > > fails with: > > /tmp/ccPIuUSA.lto.o: plugin needed to handle lto object > > in the final stage of incremental linking. This seems like binutils bug > - the message should be output only if there are LTO objects not claimed > by the linker before invoking the plugin. There is no need to error out > when plugin itself produce IL for incremental linking.
Ah, yeah - I ran into this issue with GNU ld as well with LTO early debug... Richard. > I will check if new version fixes it and fill in PR. I suppose I can > whitelist > ld versions in the plugin and enable -flinker-output=rel only on binutils > version where this works. There is LDPT_GOLD_VERSION which tells me the > info. I will update patch accordingly and check what version range refuses to > finish the link. > > Honza > > > > > Honza > > > > * lto-plugin.c: Document options; add -linker-output-known; > > determine when to use rel and when nolto-rel output. > > > > * lto-wrapper.c (run_gcc): Look for -flinker-output=rel also in the > > list of options passed from the driver. > > * passes.c (ipa_write_summaries): Only modify statements if body > > is in memory. > > * cgraphunit.c (ipa_passes): Also produce intermeidate code when > > incrementally linking. > > (ipa_passes): LIkewise. > > * lto-cgraph.c (lto_output_node): When incrementally linking do not > > pass down resolution info. > > * common.opt (flag_incremental_link): Update info. > > * gcc.c (plugin specs): Turn flinker-output=* to > > -plugin-opt=-linker-output-known > > * toplev.c (compile_file): Also cut compilation when doing incremental > > link. > > * flag-types.h (enum lto_partition_model): Add > > LTO_LINKER_OUTPUT_NOLTOREL. > > (invoke.texi): Add -flinker-output docs. > > > > * lang.opt (lto_linker_output): Add nolto-rel. > > * lto-lang.c (lto_post_options): Handle LTO_LINKER_OUTPUT_REL > > and LTO_LINKER_OUTPUT_NOLTOREL:. > > (lto_init): Generate lto when doing incremental link. > > > > * gcc.dg/lto/20081120-2_0.c: Add -flinker-output=nolto-rel > > * gcc.dg/lto/20090126-1_0.c: Likewise. > > * gcc.dg/lto/20091020-2_0.c: Likewise. > > * gcc.dg/lto/20081204-2_0.c: Likewise. > > * gcc.dg/lto/20091015-1_0.c: Likewise. > > * gcc.dg/lto/20090126-2_0.c: Likewiwe. > > * gcc.dg/lto/20090116_0.c: Likewise. > > * gcc.dg/lto/20081224_0.c: Likewise. > > * gcc.dg/lto/20091027-1_0.c: Likewise. > > * gcc.dg/lto/20090219_0.c: Likewise. > > * gcc.dg/lto/20081212-1_0.c: Likewise. > > * gcc.dg/lto/20091013-1_0.c: Likewise. > > * gcc.dg/lto/20081126_0.c: Likewise. > > * gcc.dg/lto/20090206-1_0.c: Likewise. > > * gcc.dg/lto/20091016-1_0.c: Likewise. > > * gcc.dg/lto/20081120-1_0.c: Likewise. > > * gcc.dg/lto/20091020-1_0.c: Likewise. > > * gcc.dg/lto/20100426_0.c: Likewise. > > * gcc.dg/lto/20081204-1_0.c: Likewise. > > * gcc.dg/lto/20091014-1_0.c: Likewise. > > * g++.dg/lto/20081109-1_0.C: Likewise. > > * g++.dg/lto/20100724-1_0.C: Likewise. > > * g++.dg/lto/20081204-1_0.C: Likewise. > > * g++.dg/lto/pr45679-2_0.C: Likewise. > > * g++.dg/lto/20110311-1_0.C: Likewise. > > * g++.dg/lto/20090302_0.C: Likewise. > > * g++.dg/lto/20081118_0.C: Likewise. > > * g++.dg/lto/20091002-2_0.C: Likewise. > > * g++.dg/lto/20081120-2_0.C: Likewise. > > * g++.dg/lto/20081123_0.C: Likewise. > > * g++.dg/lto/20090313_0.C: Likewise. > > * g++.dg/lto/pr54625-1_0.c: Likewise. > > * g++.dg/lto/pr48354-1_0.C: Likewise. > > * g++.dg/lto/20081219_0.C: Likewise. > > * g++.dg/lto/pr48042_0.C: Likewise. > > * g++.dg/lto/20101015-2_0.C: Likewise. > > * g++.dg/lto/pr45679-1_0.C: Likewise. > > * g++.dg/lto/20091026-1_0.C: Likewise. > > * g++.dg/lto/pr45621_0.C: Likewise. > > * g++.dg/lto/20081119-1_0.C: Likewise. > > * g++.dg/lto/20101010-4_0.C: Likewise. > > * g++.dg/lto/20081120-1_0.C: Likewise. > > * g++.dg/lto/20091002-1_0.C: Likewise. > > * g++.dg/lto/20091002-3_0.C: Likewise. > > * gfortran.dg/lto/20091016-1_0.f90: Likewise. > > * gfortran.dg/lto/pr47839_0.f90: Likewise. > > * gfortran.dg/lto/pr46911_0.f: Likewise. > > * gfortran.dg/lto/20091028-1_0.f90: Likewise. > > * gfortran.dg/lto/20091028-2_0.f90: Likewise. > > Index: lto-plugin/lto-plugin.c > > =================================================================== > > --- lto-plugin/lto-plugin.c (revision 231081) > > +++ lto-plugin/lto-plugin.c (working copy) > > @@ -27,10 +27,13 @@ along with this program; see the file CO > > More information at http://gcc.gnu.org/wiki/whopr/driver. > > > > This plugin should be passed the lto-wrapper options and will forward > > them. > > - It also has 2 options of its own: > > + It also has options at his own: > > -debug: Print the command line used to run lto-wrapper. > > -nop: Instead of running lto-wrapper, pass the original to the plugin. > > This > > - only works if the input files are hybrid. */ > > + only works if the input files are hybrid. > > + -linker-output-known: Do not determine linker output > > + -sym-style={none,win32,underscore|uscore} > > + -pass-through */ > > > > #ifdef HAVE_CONFIG_H > > #include "config.h" > > @@ -151,6 +154,7 @@ static ld_plugin_add_symbols add_symbols > > > > static struct plugin_file_info *claimed_files = NULL; > > static unsigned int num_claimed_files = 0; > > +static unsigned int non_claimed_files = 0; > > > > static struct plugin_file_info *offload_files = NULL; > > static unsigned int num_offload_files = 0; > > @@ -169,6 +173,7 @@ static char nop; > > static char *resolution_file = NULL; > > static enum ld_plugin_output_file_type linker_output; > > static int linker_output_set; > > +static int linker_output_known; > > > > /* The version of gold being used, or -1 if not gold. The number is > > MAJOR * 100 + MINOR. */ > > @@ -626,7 +631,8 @@ all_symbols_read_handler (void) > > { > > unsigned i; > > unsigned num_lto_args > > - = num_claimed_files + num_offload_files + lto_wrapper_num_args + 2; > > + = num_claimed_files + num_offload_files + lto_wrapper_num_args + 1 > > + + !linker_output_known; > > char **lto_argv; > > const char *linker_output_str; > > const char **lto_arg_ptr; > > @@ -651,26 +657,38 @@ all_symbols_read_handler (void) > > for (i = 0; i < lto_wrapper_num_args; i++) > > *lto_arg_ptr++ = lto_wrapper_argv[i]; > > > > - assert (linker_output_set); > > - switch (linker_output) > > + if (!linker_output_known) > > { > > - case LDPO_REL: > > - linker_output_str = "-flinker-output=rel"; > > - break; > > - case LDPO_DYN: > > - linker_output_str = "-flinker-output=dyn"; > > - break; > > - case LDPO_PIE: > > - linker_output_str = "-flinker-output=pie"; > > - break; > > - case LDPO_EXEC: > > - linker_output_str = "-flinker-output=exec"; > > - break; > > - default: > > - message (LDPL_FATAL, "unsupported linker output %i", linker_output); > > - break; > > + assert (linker_output_set); > > + switch (linker_output) > > + { > > + case LDPO_REL: > > + if (non_claimed_files) > > + { > > + message (LDPL_WARNING, "incremental linking of LTO and non-LTO " > > + "objects; using -flinker-output=nolto-rel which will " > > + "bypass whole program optimization"); > > + linker_output_str = "-flinker-output=nolto-rel"; > > + } > > + else > > + linker_output_str = "-flinker-output=rel"; > > + break; > > + case LDPO_DYN: > > + linker_output_str = "-flinker-output=dyn"; > > + break; > > + case LDPO_PIE: > > + linker_output_str = "-flinker-output=pie"; > > + break; > > + case LDPO_EXEC: > > + linker_output_str = "-flinker-output=exec"; > > + break; > > + default: > > + message (LDPL_FATAL, "unsupported linker output %i", linker_output); > > + linker_output_str = ""; > > + break; > > + } > > + *lto_arg_ptr++ = xstrdup (linker_output_str); > > } > > - *lto_arg_ptr++ = xstrdup (linker_output_str); > > for (i = 0; i < num_claimed_files; i++) > > { > > struct plugin_file_info *info = &claimed_files[i]; > > @@ -1023,6 +1041,7 @@ claim_file_handler (const struct ld_plug > > goto cleanup; > > > > err: > > + non_claimed_files++; > > free (lto_file.name); > > > > cleanup: > > @@ -1037,6 +1056,8 @@ claim_file_handler (const struct ld_plug > > static void > > process_option (const char *option) > > { > > + if (strcmp (option, "-linker-output-known") == 0) > > + linker_output_known = 1; > > if (strcmp (option, "-debug") == 0) > > debug = 1; > > else if (strcmp (option, "-nop") == 0) > > Index: gcc/lto-wrapper.c > > =================================================================== > > --- gcc/lto-wrapper.c (revision 231081) > > +++ gcc/lto-wrapper.c (working copy) > > @@ -912,6 +912,7 @@ run_gcc (unsigned argc, char *argv[]) > > bool have_offload = false; > > unsigned lto_argc = 0, offload_argc = 0; > > char **lto_argv, **offload_argv; > > + bool linker_output_rel = false; > > > > /* Get the driver and options. */ > > collect_gcc = getenv ("COLLECT_GCC"); > > @@ -953,9 +954,12 @@ run_gcc (unsigned argc, char *argv[]) > > file_offset = (off_t) loffset; > > } > > fd = open (filename, O_RDONLY | O_BINARY); > > + /* Linker plugin passes -fresolution and -flinker-output options. */ > > if (fd == -1) > > { > > lto_argv[lto_argc++] = argv[i]; > > + if (strcmp (argv[i], "-flinker-output=rel") == 0) > > + linker_output_rel = true; > > continue; > > } > > > > @@ -1029,11 +1033,18 @@ run_gcc (unsigned argc, char *argv[]) > > lto_mode = LTO_MODE_WHOPR; > > break; > > > > + case OPT_flinker_output_: > > + linker_output_rel = !strcmp (option->arg, "rel"); > > + break; > > + > > default: > > break; > > } > > } > > > > + if (linker_output_rel) > > + no_partition = true; > > + > > if (no_partition) > > { > > lto_mode = LTO_MODE_LTO; > > Index: gcc/passes.c > > =================================================================== > > --- gcc/passes.c (revision 231081) > > +++ gcc/passes.c (working copy) > > @@ -2530,7 +2530,7 @@ ipa_write_summaries (void) > > { > > struct cgraph_node *node = order[i]; > > > > - if (node->has_gimple_body_p ()) > > + if (gimple_has_body_p (node->decl)) > > { > > /* When streaming out references to statements as part of some IPA > > pass summary, the statements need to have uids assigned and the > > Index: gcc/cgraphunit.c > > =================================================================== > > --- gcc/cgraphunit.c (revision 231081) > > +++ gcc/cgraphunit.c (working copy) > > @@ -2270,8 +2270,10 @@ ipa_passes (void) > > if (flag_generate_lto || flag_generate_offload) > > targetm.asm_out.lto_start (); > > > > - if (!in_lto_p) > > + if (!in_lto_p || flag_incremental_link == 2) > > { > > + if (!quiet_flag) > > + fprintf (stderr, "Streaming LTO\n"); > > if (g->have_offload) > > { > > section_name_prefix = OFFLOAD_SECTION_NAME_PREFIX; > > @@ -2290,7 +2292,9 @@ ipa_passes (void) > > if (flag_generate_lto || flag_generate_offload) > > targetm.asm_out.lto_end (); > > > > - if (!flag_ltrans && (in_lto_p || !flag_lto || flag_fat_lto_objects)) > > + if (!flag_ltrans > > + && ((in_lto_p && flag_incremental_link != 2) > > + || !flag_lto || flag_fat_lto_objects)) > > execute_ipa_pass_list (passes->all_regular_ipa_passes); > > invoke_plugin_callbacks (PLUGIN_ALL_IPA_PASSES_END, NULL); > > > > @@ -2381,7 +2385,8 @@ symbol_table::compile (void) > > > > /* Do nothing else if any IPA pass found errors or if we are just > > streaming LTO. */ > > if (seen_error () > > - || (!in_lto_p && flag_lto && !flag_fat_lto_objects)) > > + || ((!in_lto_p || flag_incremental_link == 2) > > + && flag_lto && !flag_fat_lto_objects)) > > { > > timevar_pop (TV_CGRAPHOPT); > > return; > > Index: gcc/lto-cgraph.c > > =================================================================== > > --- gcc/lto-cgraph.c (revision 231081) > > +++ gcc/lto-cgraph.c (working copy) > > @@ -534,7 +534,10 @@ lto_output_node (struct lto_simple_outpu > > bp_pack_value (&bp, node->thunk.thunk_p, 1); > > bp_pack_value (&bp, node->parallelized_function, 1); > > bp_pack_enum (&bp, ld_plugin_symbol_resolution, > > - LDPR_NUM_KNOWN, node->resolution); > > + LDPR_NUM_KNOWN, > > + /* When doing incremental link, we will get new resolution > > + info next time we process the file. */ > > + flag_incremental_link ? LDPR_UNKNOWN : node->resolution); > > bp_pack_value (&bp, node->instrumentation_clone, 1); > > bp_pack_value (&bp, node->split_part, 1); > > streamer_write_bitpack (&bp); > > Index: gcc/common.opt > > =================================================================== > > --- gcc/common.opt (revision 231081) > > +++ gcc/common.opt (working copy) > > @@ -48,7 +48,8 @@ bool in_lto_p = false > > > > ; This variable is set to non-0 only by LTO front-end. 1 indicates that > > ; the output produced will be used for incrmeental linking (thus weak > > symbols > > -; can still be bound). > > +; can still be bound) and 2 indicates that the IL is going to be linked and > > +; and output to LTO object file. > > Variable > > int flag_incremental_link = 0 > > > > Index: gcc/gcc.c > > =================================================================== > > --- gcc/gcc.c (revision 231081) > > +++ gcc/gcc.c (working copy) > > @@ -953,6 +953,7 @@ proper position among the other output f > > -plugin %(linker_plugin_file) \ > > -plugin-opt=%(lto_wrapper) \ > > -plugin-opt=-fresolution=%u.res \ > > + %{flinker-output=*:-plugin-opt=-linker-output-known} \ > > > > %{!nostdlib:%{!nodefaultlibs:%:pass-through-libs(%(link_gcc_c_sequence))}} \ > > }" PLUGIN_COND_CLOSE > > #else > > Index: gcc/toplev.c > > =================================================================== > > --- gcc/toplev.c (revision 231081) > > +++ gcc/toplev.c (working copy) > > @@ -504,7 +504,8 @@ compile_file (void) > > > > /* Compilation unit is finalized. When producing non-fat LTO object, we > > are > > basically finished. */ > > - if (in_lto_p || !flag_lto || flag_fat_lto_objects) > > + if ((in_lto_p && flag_incremental_link != 2) > > + || !flag_lto || flag_fat_lto_objects) > > { > > /* File-scope initialization for AddressSanitizer. */ > > if (flag_sanitize & SANITIZE_ADDRESS) > > Index: gcc/lto/lang.opt > > =================================================================== > > --- gcc/lto/lang.opt (revision 231081) > > +++ gcc/lto/lang.opt (working copy) > > @@ -34,6 +34,9 @@ EnumValue > > Enum(lto_linker_output) String(rel) Value(LTO_LINKER_OUTPUT_REL) > > > > EnumValue > > +Enum(lto_linker_output) String(nolto-rel) Value(LTO_LINKER_OUTPUT_NOLTOREL) > > + > > +EnumValue > > Enum(lto_linker_output) String(dyn) Value(LTO_LINKER_OUTPUT_DYN) > > > > EnumValue > > Index: gcc/lto/lto-lang.c > > =================================================================== > > --- gcc/lto/lto-lang.c (revision 231081) > > +++ gcc/lto/lto-lang.c (working copy) > > @@ -823,6 +823,26 @@ lto_post_options (const char **pfilename > > switch (flag_lto_linker_output) > > { > > case LTO_LINKER_OUTPUT_REL: /* .o: incremental link producing LTO IL > > */ > > + /* Configure compiler same way as normal frontend would do with > > -flto: > > + this way we read the trees (declarations & types), symbol table, > > + optimization summaries and link them. Subsequently we output new LTO > > + file. */ > > + flag_lto = ""; > > + flag_incremental_link = 2; > > + flag_whole_program = 0; > > + flag_wpa = 0; > > + flag_generate_lto = 1; > > + /* It would be cool to produce .o file directly, but our current > > + simple objects does not contain the lto symbol markers. Go the slow > > + way through the asm file. */ > > + lang_hooks.lto.begin_section = lhd_begin_section; > > + lang_hooks.lto.append_data = lhd_append_data; > > + lang_hooks.lto.end_section = lhd_end_section; > > + if (flag_ltrans) > > + error ("-flinker-output=rel and -fltrans are mutually exclussive"); > > + break; > > + > > + case LTO_LINKER_OUTPUT_NOLTOREL: /* .o: incremental link producing asm > > */ > > flag_whole_program = 0; > > flag_incremental_link = 1; > > break; > > @@ -1243,7 +1263,7 @@ lto_init (void) > > int i; > > > > /* We need to generate LTO if running in WPA mode. */ > > - flag_generate_lto = (flag_wpa != NULL); > > + flag_generate_lto = (flag_incremental_link == 2 || flag_wpa != NULL); > > > > /* Create the basic integer types. */ > > build_common_tree_nodes (flag_signed_char, flag_short_double); > > Index: gcc/flag-types.h > > =================================================================== > > --- gcc/flag-types.h (revision 231081) > > +++ gcc/flag-types.h (working copy) > > @@ -269,6 +269,7 @@ enum lto_partition_model { > > enum lto_linker_output { > > LTO_LINKER_OUTPUT_UNKNOWN, > > LTO_LINKER_OUTPUT_REL, > > + LTO_LINKER_OUTPUT_NOLTOREL, > > LTO_LINKER_OUTPUT_DYN, > > LTO_LINKER_OUTPUT_PIE, > > LTO_LINKER_OUTPUT_EXEC > > Index: gcc/doc/invoke.texi > > =================================================================== > > --- gcc/doc/invoke.texi (revision 231081) > > +++ gcc/doc/invoke.texi (working copy) > > @@ -492,7 +492,8 @@ Objective-C and Objective-C++ Dialects}. > > > > @item Linker Options > > @xref{Link Options,,Options for Linking}. > > -@gccoptlist{@var{object-file-name} -fuse-ld=@var{linker} -l@var{library} > > @gol > > +@gccoptlist{@var{object-file-name} -flinker-output=@var{type} @gol > > +-fuse-ld=@var{linker} -l@var{library} @gol > > -nostartfiles -nodefaultlibs -nostdlib -pie -rdynamic @gol > > -s -static -static-libgcc -static-libstdc++ @gol > > -static-libasan -static-libtsan -static-liblsan -static-libubsan @gol > > @@ -11317,6 +11318,50 @@ If any of these options is used, then th > > object file names should not be used as arguments. @xref{Overall > > Options}. > > > > +@item -flinker-output=@var{type} > > +@opindex -flinker-output > > +This option controls the code generation of the link time optimizer. By > > +default the linker output is determined by the linker plugin > > automatically. For > > +debugging the compiler and in the case of incremental linking it may be > > useful > > +to control the type manually. > > + > > +If @var{type} is @samp{exec} the code generation is configured to produce > > static > > +binary. In this case @option{-fpic} and @option{-fpie} are both disabled. > > + > > +If @var{type} is @samp{dyn} the code generation is configured to produce > > shared > > +library. In this case @option{-fpic} or @option{-fPIC} is preserved. These > > +options arenot implied to make it possible to build static libraries > > without > > +position independent code on architectures this is possible, i.e. on x86. > > + > > +If @var{type} is @samp{pie} the code generation is configured to produce > > +@option{-fpie} executable. This result in similar optimizations as > > @samp{exec} > > +except that @option{-fpie} is not disabled if specified at compilation > > time. > > + > > +If @var{type} is @samp{rel} the compiler assumes that incremental linking > > is > > +done. The sections containing intermediate code for link-time > > optimization are > > +merged, pre-optimized, and output to the resulting object file. In > > addition if > > +@option{-ffat-lto-objects} is specified the binary code is produced for > > future > > +non-lto linking. The object file produced by incremental linking will be > > smaller > > +than a static library produced from the same object files. At link-time > > the > > +result of incremental linking will also load faster to compiler than a > > static > > +library assuming that majority of objects in the library are used. > > + > > +Finally @samp{nolto-rel} configure compiler to for incremental linking > > where > > +code generation is forced, final binary is produced and the intermediate > > code > > +for later link-time optimization is stripped. When multiple object files > > are > > +linked together the resulting code will be optimized better than with link > > time > > +optimizations disabled (for example, the cross-module inlining will > > happen), > > +most of benefits of whole program optimizations are however lost. > > + > > +During the incremental link (by @option{-r}) the linker plugin will > > default to > > +@option{rel}. With current interfaces to GNU Binutils it is however not > > +possible to link incrementally LTO objects and non-LTO objects into a > > single > > +mixed object file. In the case any of object files in incremental link > > can not > > +be used for link-time optimization the linker plugin will output warning > > and > > +use @samp{nolto-rel}. To maintain the whole program optimization it is > > +recommended to link such objects into static library instead. > > Alternatively it > > +is possible to use H.J. Lu's binutils with support for mixed objects. > > + > > @item -fuse-ld=bfd > > @opindex fuse-ld=bfd > > Use the @command{bfd} linker instead of the default linker. > > Index: gcc/testsuite/gcc.dg/lto/20081120-2_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20081120-2_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20081120-2_0.c (working copy) > > @@ -1,3 +1,4 @@ > > /* { dg-lto-do link } */ > > /* { dg-lto-options {{-flto -flto-partition=1to1 -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > void bar(void) {} > > Index: gcc/testsuite/gcc.dg/lto/20090126-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20090126-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20090126-1_0.c (working copy) > > @@ -1,6 +1,6 @@ > > /* { dg-lto-do link } */ > > /* { dg-lto-options {{-O0 -flto -flto-partition=1to1}} } */ > > -/* { dg-extra-ld-options {-r -nostdlib -O2 -flto -flto-partition=1to1} } */ > > +/* { dg-extra-ld-options {-r -nostdlib -O2 -flto -flto-partition=1to1 > > -flinker-output=nolto-rel} } */ > > > > int main(int argc, char **argv) { > > return 0; > > Index: gcc/testsuite/gcc.dg/lto/20091020-2_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20091020-2_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20091020-2_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -r -nostdlib -flto}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > typedef struct { > > int NumPackStreams; > > Index: gcc/testsuite/gcc.dg/lto/20081204-2_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20081204-2_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20081204-2_0.c (working copy) > > @@ -1,5 +1,6 @@ > > /* { dg-lto-do link } */ > > /* { dg-skip-if "" { ! { i?86-*-* x86_64-*-* } } { "*" } { "" } } */ > > /* { dg-lto-options {{-w -flto -fPIC -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > register int ri asm("edi"); > > Index: gcc/testsuite/gcc.dg/lto/20091015-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20091015-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20091015-1_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -r -nostdlib -O2 -flto} {-fPIC -r -nostdlib > > -O2 -flto -flto-partition=1to1}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > #include "20091015-1_b.h" > > void diagnostic_initialize (FILE **stream) { *stream = stderr; } > > Index: gcc/testsuite/gcc.dg/lto/20090126-2_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20090126-2_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20090126-2_0.c (working copy) > > @@ -1,7 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -O2 -flto -flto-partition=1to1}} } */ > > -/* { dg-extra-ld-options {-fno-PIC -r -nostdlib -O2 -flto > > -flto-partition=1to1} } */ > > +/* { dg-extra-ld-options {-fno-PIC -r -nostdlib -O2 -flto > > -flto-partition=1to1 -flinker-output=nolto-rel} } */ > > > > int main(int argc, char **argv) { > > return 0; > > Index: gcc/testsuite/gcc.dg/lto/20090116_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20090116_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20090116_0.c (working copy) > > @@ -1,7 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-O1 -flto -flto-partition=1to1 -fPIC}} } */ > > -/* { dg-extra-ld-options {-r -nostdlib -O0} } */ > > +/* { dg-extra-ld-options {-r -nostdlib -O0 -flinker-output=nolto-rel} } */ > > > > int foo(void) { > > int ret, i; > > Index: gcc/testsuite/gcc.dg/lto/20081224_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20081224_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20081224_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-flto -flto-partition=1to1 -r -nostdlib -fPIC}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > #include "20081224_0.h" > > > > extern struct foo x; > > Index: gcc/testsuite/gcc.dg/lto/20091027-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20091027-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20091027-1_0.c (working copy) > > @@ -1,5 +1,5 @@ > > /* { dg-lto-do link } */ > > -/* { dg-extra-ld-options "-r -nostdlib" } */ > > +/* { dg-extra-ld-options "-r -nostdlib -flinker-output=nolto-rel" } */ > > > > typedef struct _xmlDict xmlDict; > > struct _xmlDict { > > Index: gcc/testsuite/gcc.dg/lto/20090219_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20090219_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20090219_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-O3 -flto -flto-partition=1to1 -fPIC -r -nostdlib}} > > } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > struct Foo { int f1, f2, f3, f4, f5; }; > > > > Index: gcc/testsuite/gcc.dg/lto/20081212-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20081212-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20081212-1_0.c (working copy) > > @@ -1,4 +1,5 @@ > > /* { dg-lto-do link } */ > > /* { dg-lto-options {{-r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > int exported_var = 42; > > /* { dg-final { scan-symbol "exported_var" } } */ > > Index: gcc/testsuite/gcc.dg/lto/20091013-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20091013-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20091013-1_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -r -nostdlib -flto} {-fPIC -r -nostdlib -O2 > > -flto}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > void * HeapAlloc(void*,unsigned int,unsigned long); > > > > Index: gcc/testsuite/gcc.dg/lto/20081126_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20081126_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20081126_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-skip-if "" { ! { i?86-*-* x86_64-*-* } } { "*" } { "" } } */ > > /* { dg-lto-options {{-flto -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > int f(void) { > > register int ri asm("edi"); > > Index: gcc/testsuite/gcc.dg/lto/20090206-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20090206-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20090206-1_0.c (working copy) > > @@ -3,6 +3,7 @@ > > /* { dg-lto-options {{-fPIC -r -nostdlib -flto -flto-partition=1to1 > > -msse2}} } */ > > /* { dg-require-effective-target sse2 } */ > > /* { dg-suppress-ld-options {-fPIC -msse2} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > typedef short v8hi __attribute__((__vector_size__(16))); > > void func (void) { > > Index: gcc/testsuite/gcc.dg/lto/20091016-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20091016-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20091016-1_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -r -nostdlib -O2 -flto}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > typedef struct VEC_constructor_elt_gc { } VEC_constructor_elt_gc; > > #include "20091016-1_a.h" > > Index: gcc/testsuite/gcc.dg/lto/20081120-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20081120-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20081120-1_0.c (working copy) > > @@ -1,5 +1,6 @@ > > /* { dg-lto-do link } */ > > /* { dg-lto-options {{-flto -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > extern int stat(void) __asm__("" "stat64"); > > extern inline int stat(void) { } > > static void foo(void) { stat(); } > > Index: gcc/testsuite/gcc.dg/lto/20091020-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20091020-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20091020-1_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -r -nostdlib -flto}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > typedef struct { > > int NumPackStreams; > > Index: gcc/testsuite/gcc.dg/lto/20100426_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20100426_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20100426_0.c (working copy) > > @@ -1,5 +1,6 @@ > > /* { dg-lto-do link } */ > > /* { dg-lto-options {{-r -nostdlib -flto -g}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > long Perl_my_htonl (long l) > > { > > Index: gcc/testsuite/gcc.dg/lto/20081204-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20081204-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20081204-1_0.c (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-flto -flto-partition=1to1 -fPIC -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > /* Tests for the absence during linking of: > > lto1: error: type of 'i' does not match original declaration */ > > Index: gcc/testsuite/gcc.dg/lto/20091014-1_0.c > > =================================================================== > > --- gcc/testsuite/gcc.dg/lto/20091014-1_0.c (revision 231081) > > +++ gcc/testsuite/gcc.dg/lto/20091014-1_0.c (working copy) > > @@ -1,5 +1,6 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -r -nostdlib -flto}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > /* Empty file. See PR41173. */ > > Index: gcc/testsuite/g++.dg/lto/20081109-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20081109-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20081109-1_0.C (working copy) > > @@ -1,6 +1,6 @@ > > // { dg-lto-do link } > > // { dg-require-effective-target fpic } > > // { dg-lto-options {{-fPIC -flto -flto-partition=1to1}} } > > -// { dg-extra-ld-options "-fPIC -flto -flto-partition=1to1 -r -nostdlib > > -fno-exceptions" } > > +// { dg-extra-ld-options "-fPIC -flto -flto-partition=1to1 -r -nostdlib > > -fno-exceptions -flinker-output=nolto-rel" } > > void func(); class Foo { }; > > void bar() { try { func(); } catch (Foo) { } }; > > Index: gcc/testsuite/g++.dg/lto/20100724-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20100724-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20100724-1_0.C (working copy) > > @@ -1,6 +1,6 @@ > > /* { dg-lto-do link } */ > > /* { dg-lto-options {{-ftoplevel-reorder -flto -flto-partition=none} > > {-ftoplevel-reorder -flto -flto-partition=1to1}} } */ > > -/* { dg-extra-ld-options {-r -nostdlib} } */ > > +/* { dg-extra-ld-options {-r -nostdlib -flinker-output=nolto-rel} } */ > > > > struct Foo { virtual ~Foo(); }; > > struct Bar:public Foo { Bar() { } }; > > Index: gcc/testsuite/g++.dg/lto/20081204-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20081204-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20081204-1_0.C (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-flto -flto-partition=1to1 -fPIC -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > /* Tests for the absence during linking of: > > lto1: error: type of '_ZTVN10__cxxabiv120__si_class_type_infoE' does > > Index: gcc/testsuite/g++.dg/lto/pr45679-2_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/pr45679-2_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/pr45679-2_0.C (working copy) > > @@ -1,6 +1,6 @@ > > // { dg-lto-do link } > > // { dg-lto-options {{-O3 -Wno-multichar}} } > > -// { dg-extra-ld-options "-flto -flto-partition=1to1 -r -nostdlib" } > > +// { dg-extra-ld-options "-flto -flto-partition=1to1 -r -nostdlib > > -flinker-output=nolto-rel" } > > extern "C" { > > typedef struct { > > union { > > Index: gcc/testsuite/g++.dg/lto/20110311-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20110311-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20110311-1_0.C (working copy) > > @@ -1,5 +1,5 @@ > > /* { dg-lto-do link } */ > > -/* { dg-extra-ld-options "-r -nostdlib" } */ > > +/* { dg-extra-ld-options "-r -nostdlib -flinker-output=nolto-rel" } */ > > > > struct NullType {}; > > > > Index: gcc/testsuite/g++.dg/lto/20090302_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20090302_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20090302_0.C (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -flto -flto-partition=1to1 -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > struct Foo { > > bool Mumble(); > > static void Bar() { if (foo_->Mumble()) foo_ = 0; } > > Index: gcc/testsuite/g++.dg/lto/20081118_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20081118_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20081118_0.C (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -flto -flto-partition=1to1 -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > /* We used to ICE because of dangling pointers. */ > > > > Index: gcc/testsuite/g++.dg/lto/20091002-2_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20091002-2_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20091002-2_0.C (working copy) > > @@ -1,7 +1,7 @@ > > // { dg-lto-do link } > > // { dg-require-effective-target fpic } > > // { dg-lto-options {{-fPIC}} } > > -// { dg-extra-ld-options "-fPIC -r -nostdlib" } > > +// { dg-extra-ld-options "-fPIC -r -nostdlib -flinker-output=nolto-rel" } > > > > class DataArray { > > int max() const { } > > Index: gcc/testsuite/g++.dg/lto/20081120-2_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20081120-2_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20081120-2_0.C (working copy) > > @@ -1,5 +1,6 @@ > > // { dg-lto-do link } > > // { dg-lto-options {{-flto -r -nostdlib}} } > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > template < typename > struct Foo > > { > > inline void rdstate() { > > Index: gcc/testsuite/g++.dg/lto/20081123_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20081123_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20081123_0.C (working copy) > > @@ -1,6 +1,7 @@ > > // { dg-lto-do link } > > // { dg-require-effective-target fpic } > > // { dg-lto-options {{-flto -flto-partition=1to1 -r -nostdlib -fPIC}} } > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > int > > f(void) > > Index: gcc/testsuite/g++.dg/lto/20090313_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20090313_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20090313_0.C (working copy) > > @@ -1,6 +1,6 @@ > > // { dg-lto-do link } > > // { dg-require-effective-target fpic } > > // { dg-lto-options {{-flto -flto-partition=1to1 -fPIC}} } > > -// { dg-extra-ld-options "-flto -flto-partition=1to1 -r -nostdlib" } > > +// { dg-extra-ld-options "-flto -flto-partition=1to1 -r -nostdlib > > -flinker-output=nolto-rel" } > > > > int X; > > Index: gcc/testsuite/g++.dg/lto/pr54625-1_0.c > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/pr54625-1_0.c (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/pr54625-1_0.c (working copy) > > @@ -1,5 +1,5 @@ > > /* { dg-lto-do link } */ > > -/* { dg-extra-ld-options { -r -nostdlib } } */ > > +/* { dg-extra-ld-options { -r -nostdlib -flinker-output=nolto-rel } } */ > > > > float a; > > double sin (); > > Index: gcc/testsuite/g++.dg/lto/pr48354-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/pr48354-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/pr48354-1_0.C (working copy) > > @@ -1,6 +1,6 @@ > > // { dg-lto-do link } > > // { dg-lto-options { { -g -flto } } } > > -// { dg-extra-ld-options "-r -nostdlib" } > > +// { dg-extra-ld-options "-r -nostdlib -flinker-output=nolto-rel" } > > > > template<typename T> struct Identity { typedef T type; }; > > struct S { > > Index: gcc/testsuite/g++.dg/lto/20081219_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20081219_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20081219_0.C (working copy) > > @@ -1,7 +1,7 @@ > > // { dg-lto-do link } > > // { dg-require-effective-target fpic } > > // { dg-lto-options {{-fPIC -flto -flto-partition=1to1 -O2}} } > > -// { dg-extra-ld-options "-O2 -fPIC -flto -flto-partition=1to1 -r > > -nostdlib" } > > +// { dg-extra-ld-options "-O2 -fPIC -flto -flto-partition=1to1 -r > > -nostdlib -flinker-output=nolto-rel" } > > > > typedef long int ptrdiff_t; > > extern "C" > > Index: gcc/testsuite/g++.dg/lto/pr48042_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/pr48042_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/pr48042_0.C (working copy) > > @@ -1,5 +1,5 @@ > > // { dg-lto-do link } > > -// { dg-extra-ld-options "-r -nostdlib -g" } > > +// { dg-extra-ld-options "-r -nostdlib -g -flinker-output=nolto-rel" } > > > > class A { > > virtual int x() = 0; > > Index: gcc/testsuite/g++.dg/lto/20101015-2_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20101015-2_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20101015-2_0.C (working copy) > > @@ -1,6 +1,6 @@ > > // { dg-lto-do link } > > // { dg-lto-options { { -flto } { -g -flto } } } > > -// { dg-extra-ld-options "-r -nostdlib" } > > +// { dg-extra-ld-options "-r -nostdlib -flinker-output=nolto-rel" } > > > > struct Base { ~Base (); }; > > void fun(void) { struct Deriv : Base { } x; } > > Index: gcc/testsuite/g++.dg/lto/pr45679-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/pr45679-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/pr45679-1_0.C (working copy) > > @@ -1,6 +1,6 @@ > > // { dg-lto-do link } > > // { dg-lto-options {{-O3 -Wno-multichar}} } > > -// { dg-extra-ld-options "-flto -flto-partition=1to1 -r -nostdlib" } > > +// { dg-extra-ld-options "-flto -flto-partition=1to1 -r -nostdlib > > -flinker-output=nolto-rel" } > > > > extern "C" { > > typedef struct __locale_struct { > > Index: gcc/testsuite/g++.dg/lto/20091026-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20091026-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20091026-1_0.C (working copy) > > @@ -1,5 +1,5 @@ > > // { dg-lto-do link } > > -// { dg-extra-ld-options "-r -nostdlib" } > > +// { dg-extra-ld-options "-r -nostdlib -flinker-output=nolto-rel" } > > > > #include "20091026-1_a.h" > > cObject *cHead::find(const char *objname) const > > Index: gcc/testsuite/g++.dg/lto/pr45621_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/pr45621_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/pr45621_0.C (working copy) > > @@ -1,5 +1,5 @@ > > // { dg-lto-do assemble } > > -// { dg-extra-ld-options "-O2 -fipa-cp-clone -flto -nostdlib -r" } > > +// { dg-extra-ld-options "-O2 -fipa-cp-clone -flto -nostdlib -r > > -flinker-output=nolto-rel" } > > #include "pr45621.h" > > > > void > > Index: gcc/testsuite/g++.dg/lto/20081119-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20081119-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20081119-1_0.C (working copy) > > @@ -1,6 +1,7 @@ > > /* { dg-lto-do link } */ > > /* { dg-require-effective-target fpic } */ > > /* { dg-lto-options {{-fPIC -flto -flto-partition=1to1 -r -nostdlib}} } */ > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > #include "20081119-1.h" > > > > Index: gcc/testsuite/g++.dg/lto/20101010-4_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20101010-4_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20101010-4_0.C (working copy) > > @@ -1,5 +1,6 @@ > > // { dg-lto-do link } > > // { dg-lto-options { { -std=c++0x -flto -r -nostdlib } { -std=c++0x -flto > > -g -r -nostdlib } } } > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > > > typedef decltype(nullptr) nullptr_t; > > class shared_ptr { > > Index: gcc/testsuite/g++.dg/lto/20081120-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20081120-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20081120-1_0.C (working copy) > > @@ -1,5 +1,6 @@ > > // { dg-lto-do link } > > // { dg-lto-options {{-flto -r -nostdlib}} } > > +/* { dg-extra-ld-options "-flinker-output=nolto-rel" } */ > > extern "C" > > { > > extern __inline __attribute__((__gnu_inline__)) int pthread_equal(int, > > int) > > Index: gcc/testsuite/g++.dg/lto/20091002-1_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20091002-1_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20091002-1_0.C (working copy) > > @@ -1,7 +1,7 @@ > > // { dg-lto-do link } > > // { dg-require-effective-target fpic } > > // { dg-lto-options {{-fPIC -flto}} } > > -// { dg-extra-ld-options "-fPIC -r -nostdlib" } > > +// { dg-extra-ld-options "-fPIC -r -nostdlib -flinker-output=nolto-rel" } > > > > namespace std __attribute__ ((__visibility__ ("default"))) > > { > > Index: gcc/testsuite/g++.dg/lto/20091002-3_0.C > > =================================================================== > > --- gcc/testsuite/g++.dg/lto/20091002-3_0.C (revision 231081) > > +++ gcc/testsuite/g++.dg/lto/20091002-3_0.C (working copy) > > @@ -1,7 +1,7 @@ > > // { dg-lto-do link } > > // { dg-require-effective-target fpic } > > // { dg-lto-options {{-fPIC}} } > > -// { dg-extra-ld-options "-fPIC -r -nostdlib" } > > +// { dg-extra-ld-options "-fPIC -r -nostdlib -flinker-output=nolto-rel" } > > > > template < class T > > > class DataArray { > > Index: gcc/testsuite/gfortran.dg/lto/20091016-1_0.f90 > > =================================================================== > > --- gcc/testsuite/gfortran.dg/lto/20091016-1_0.f90 (revision 231081) > > +++ gcc/testsuite/gfortran.dg/lto/20091016-1_0.f90 (working copy) > > @@ -1,5 +1,6 @@ > > ! { dg-lto-do link } > > ! { dg-lto-options {{-flto -g -fPIC -r -nostdlib} {-O -flto -g -fPIC -r > > -nostdlib}} } > > +! { dg-extra-ld-options "-flinker-output=nolto-rel" } > > > > FUNCTION makenumberstring(x) > > IMPLICIT NONE > > Index: gcc/testsuite/gfortran.dg/lto/pr47839_0.f90 > > =================================================================== > > --- gcc/testsuite/gfortran.dg/lto/pr47839_0.f90 (revision 231081) > > +++ gcc/testsuite/gfortran.dg/lto/pr47839_0.f90 (working copy) > > @@ -1,6 +1,6 @@ > > ! { dg-lto-do link } > > ! { dg-lto-options {{ -g -flto }} } > > -! { dg-extra-ld-options "-r -nostdlib" } > > +! { dg-extra-ld-options "-r -nostdlib -flinker-output=nolto-rel" } > > > > MODULE globalvar_mod > > integer :: xstop > > Index: gcc/testsuite/gfortran.dg/lto/pr46911_0.f > > =================================================================== > > --- gcc/testsuite/gfortran.dg/lto/pr46911_0.f (revision 231081) > > +++ gcc/testsuite/gfortran.dg/lto/pr46911_0.f (working copy) > > @@ -1,6 +1,6 @@ > > ! { dg-lto-do link } > > ! { dg-lto-options {{ -O2 -flto -g }} } > > -! { dg-extra-ld-options "-r -nostdlib" } > > +! { dg-extra-ld-options "-r -nostdlib -flinker-output=nolto-rel" } > > common/main1/ eps(2) > > call dalie6s(iqmod6,1,wx,cor6d) > > end > > Index: gcc/testsuite/gfortran.dg/lto/20091028-1_0.f90 > > =================================================================== > > --- gcc/testsuite/gfortran.dg/lto/20091028-1_0.f90 (revision 231081) > > +++ gcc/testsuite/gfortran.dg/lto/20091028-1_0.f90 (working copy) > > @@ -1,5 +1,5 @@ > > ! { dg-lto-do link } > > -! { dg-extra-ld-options "-r -nostdlib -finline-functions" } > > +! { dg-extra-ld-options "-r -nostdlib -finline-functions > > -flinker-output=nolto-rel" } > > > > SUBROUTINE int_gen_ti_header_char( hdrbuf, hdrbufsize, itypesize, & > > DataHandle, Element, VarName, Data, code ) > > Index: gcc/testsuite/gfortran.dg/lto/20091028-2_0.f90 > > =================================================================== > > --- gcc/testsuite/gfortran.dg/lto/20091028-2_0.f90 (revision 231081) > > +++ gcc/testsuite/gfortran.dg/lto/20091028-2_0.f90 (working copy) > > @@ -1,5 +1,5 @@ > > ! { dg-lto-do link } > > -! { dg-extra-ld-options "-r -nostdlib -finline-functions" } > > +! { dg-extra-ld-options "-r -nostdlib -finline-functions > > -flinker-output=nolto-rel" } > > > > SUBROUTINE int_gen_ti_header_char( hdrbuf, hdrbufsize, itypesize, & > > DataHandle, Element, VarName, Data, code ) > > -- Richard Biener <rguent...@suse.de> SUSE LINUX GmbH, GF: Felix Imendoerffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nuernberg)