[LLVMdev] Build Attributes Proposal

Chris Lattner clattner at apple.com
Wed Nov 17 15:00:42 PST 2010


On Nov 17, 2010, at 2:55 PM, Rafael EspĂ­ndola wrote:

>> Hi Duncan,
>> 
>> This could work, but it's very limited. Besides, there's already an MC
>> build attribute infrastructure, one would have to interpret those
>> strings in the back-end to an MC construct then back again to ASM and
>> ELF.
>> 
>> I don't see why having a magic global would be worse than using module asm...
> 
> So, you mentioned that there should be no attributes that were not
> requested by the users, right? If that is so, can't you produce the
> asm in clang or you FE and have llvm never introduce new ones? LLVM
> itself doesn't use the attributes, so it doesn't need to interpret
> them.

Right, we do similar things for Objective-C metadata that there is no reason to represent in IR, the objc frontend (like clang) just produces module-level inline assembly blobs.

-Chris



More information about the llvm-dev mailing list