[lto] Read options from all the IL files
Michael Meissner
meissner@linux.vnet.ibm.com
Wed Feb 11 20:42:00 GMT 2009
On Tue, Feb 10, 2009 at 03:24:44PM -0500, Diego Novillo wrote:
> This patch is a crude attempt at merging options from multiple
> files in the same command line. Instead of applying the options
> found in the first file, it applies the options found in all the
> files, effectively merging them.
>
> The problem here is that it applies the same options to all the
> files, which may not be appropriate in all cases. Specifically:
>
> $ gcc -flto -fPIC -c f1.c
> $ gcc -flto -c f2.c
> $ gcc -flto -o f f2.o f1.o
>
> In this case, final code generation for all the functions in f2.o
> will be done with PIC enabled. The long-term solution for this
> should probably be applying the options to the individual
> functions in each file instead of applying them globally.
>
> Tested on x86_64.
Well on the x86_64 at least, you should be able to use the function specific
option support that I put in when I worked at AMD.
--
Michael Meissner, IBM
4 Technology Place Drive, MS 2203A, Westford, MA, 01886, USA
meissner@linux.vnet.ibm.com
More information about the Gcc-patches
mailing list