[vlc-devel] [PATCH] [RFC] Configure: enable LTO if present

Jean-Baptiste Kempf jb at videolan.org
Tue Aug 1 08:35:40 CEST 2017


Hello,

On Tue, 1 Aug 2017, at 08:32, Rémi Denis-Courmont wrote:
> Le 1 août 2017 00:41:50 GMT+03:00, Jean-Baptiste Kempf <jb at videolan.org> a écrit :>> ---
>> 
>>  configure.ac | 6 ++++++
>> 
>>  1 file changed, 6 insertions(+)
>> 
>> 
>> 
>> diff --git a/configure.ac b/configure.ac
>> 
>> index e303715514..fe7e273ea0 100644
>> 
>> --- a/configure.ac
>> 
>> +++ b/configure.ac
>> 
>> @@ -1049,6 +1049,12 @@ AS_IF([test "${enable_optimizations}" != "no"], [
>> >>    RDC_PROG_CXX_FFLAGS([no-math-errno unsafe-math-optimizations no-rounding-math no-signaling-nans cx-limited-range])
>> >>    AC_LANG_POP
>> 
>>  
>> 
>> +  dnl Check for LTO
>> 
>> +  RDC_PROG_CC_FFLAGS([lto])
>> 
>> +  AC_LANG_PUSH(C++)
>> 
>> +  RDC_PROG_CXX_FFLAGS([lto])
>> 
>> +  AC_LANG_POP
>> 
>> +
>> 
>>  AH_BOTTOM([
>> 
>>  #if defined(_MSC_VER) && !defined(__clang__)
>> 
>>  # pragma fenv_access(off)
>> 
> 
> ODR violations should be fixed before LTO is enabled.

Sure. I thought we destroyed most of them.

>  And this breaks distcc and ccache, which will infuriate some devs, most probably.
Then they can override the flags, or disable optimizations.
But seriously, VLC is now quite fast to compile on a reasonably fast machine. Contribs are not.
--
Jean-Baptiste Kempf -  President
+33 672 704 734
 


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20170801/8b6bb74b/attachment.html>


More information about the vlc-devel mailing list