[LLVMdev] New TargetSpec 'llvmnote'

Chris Lattner clattner at apple.com
Wed Feb 23 22:29:51 PST 2011


On Feb 23, 2011, at 9:59 AM, Sandeep Patel wrote:

>> Remember that this isn't intended to be something users deal with, it's just an internal implementation detail of the compiler, debugger, nm implementation, etc.
> 
> Bitcode currently does not carry enough options information to handle
> LTO. For example, if you use -O1 for a particular translation unit but
> -O4 for the rest of them, that information isn't saved and provided to
> LTO when the actual optimization is happening. Similarly, some options
> like soft-float/hard-float aren't preserved. We should consider these
> issues while solving this.

That's true, but the same is also true for a huge variety of other codegen-level flags.  I don't think we want to encode every possible detail at this level.  Specific things can be solved in different ways: for example, -ffast-math is best solved by adding a flag onto individual fp ops.  Some things (like mixed versions of -mpreferred-stack-boundary) are worth just punting on, IMO.

In any case, I'm not interested in trying to tackle the long tail of weird codegen options + LTO at this point.

-Chris



More information about the llvm-dev mailing list