This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFA: Set default optimization level to -O2 for -flto


Hi Basile,

but my personal feeling is
that make a warning -or perhaps even an error- at link time if the
optimization is less than at compile time.

I think that a warning would be better than an error because the user might deliberately wish to use a lower optimization level. (For example because they suspect that there is a bug in the optimizer and they are trying to prove this).


Also I think that it would be best to only issue the warning if *no* -O<n> or -Os switch is specified on the command line. This is again because the user may have a good reason for selecting a low optimization level.

Cheers
  Nick


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]