[cfe-dev] [LLVMdev] [RFC] Encoding Compile Flags into the IR
wendling at apple.com
Mon Apr 30 16:12:47 PDT 2012
On Apr 30, 2012, at 1:00 PM, dag at cray.com wrote:
> Bill Wendling <wendling at apple.com> writes:
>> Link-Time Optimization has a problem. We need to preserve some of the
>> flags with which the modules were compiled so that the semantics of
>> the resulting program are correct. For example, a module compiled with
>> `-msoft-float' should use library calls for floating point. And that's
>> only the tip of the proverbial iceberg.
> This is an important missing feature.
>> - Named metadata would be used for those options which affect code
>> generation for the functions, but which doesn't prevent two modules
>> from being merged together. For example, `-fomit-frame-pointer'
>> applies to individual functions, but it doesn't prevent a module
>> compiled with `-fno-omit-frame-pointer' from being merged with one
>> compiled with `-fomit-frame-pointer'. We would use a named metadata
> Doesn't this violate the "no semantics" requirement of metadata? What
> happens if the metadata gets dropped?
Named metadata cannot be stripped by normal methods.
More information about the cfe-dev