[LLVMdev] Build Attributes Proposal

Duncan Sands baldrick at free.fr
Sat Nov 13 07:12:11 PST 2010


Hi Renato,

> On 13 November 2010 10:06, Duncan Sands<baldrick at free.fr>  wrote:
>>    module asm "\09.ident\09\22GCC: (GNU) 4.5.2 20101028 (prerelease) LLVM:
>> 118890\22"
>
> 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 agree that it's limited.  As for MC, it will need to handle these strings
anyway since this is an existing LLVM feature (coming from gcc originally)
that needs to be supported.

> I don't see why having a magic global would be worse than using module asm...

Because magic globals need magic treatment, i.e. special logic in the code
generators etc.  Why add all this new stuff if an existing feature will do?

Ciao,

Duncan.



More information about the llvm-dev mailing list