[LLVMdev] __used__ attributes in llvm-gcc's crtstuff.c

Dimitry Andric
Wed, 15 Dec 2010 10:19:09 -0000

On 2010-12-14 12:26, Woongsik Choi wrote:
> My question is that why some global static variables, such as
> __frame_dummy_init_array_entry
> and __do_global_dtors_aux_fini_array_entry, are not given __used__
> attributes.
...
> I tried to give __used__ attribute to every global static variable in
> crtstuff.c and
> it caused no problem for me so far.

Note that upstream gcc has already marked more globals in crtstuff.c as