[LLVMdev] [RFC] Overhauling Attributes

Bill Wendling wendling at apple.com
Tue Jan 1 03:50:36 PST 2013

On Dec 30, 2012, at 11:35 AM, Rafael EspĂ­ndola <rafael.espindola at gmail.com> wrote:

> On 29 December 2012 21:21, Bill Wendling <wendling at apple.com> wrote:
>> Hi Rafael,
>> Sorry, I forgot to respond to this. They can be arbitrary strings that are known only to the specific back-end. It may be beneficial to define them inside of the LangRef document though.
> But then, what are the semantics that the middle end should use? Can a
> non thumb function be inlined in a thumb one for example? If we merge
> two functions, how should we combine the attributes? Or should this
> not be a valid optimization at all?
All good questions. The initial implementation will be a very conservative "if the attributes don't match, then we won't inline them." Yes, that's horribly bad in general, but shouldn't be too much of a problem in non-LTO cases. This can be relaxed later on. For target-specific attributes, we will have to rely upon the back-end to tell us if it's okay to inline them.


More information about the llvm-dev mailing list