This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
On 06/24/2015 11:12 PM, Aldy Hernandez wrote:
The problem here is that we are trying to call dwarf2out_late_global_decl() on a static variable in a template which has a type of TEMPLATE_TYPE_PARM: template <typename T> class A { static __thread T a; }; We are calling late_global_decl because we are about to remove the unused static from the symbol table:
The problem here is that 'a' should never have been in the symbol table in the first place, since it's an uninstantiated template. It's there because of honza's change to store the TLS model in the symbol table, so TLS templates end up with varpool entries that, of course, will never be referenced.
I guess either we need to avoid putting these templates in the symbol table or we need to mark these fake entries somehow.
Jason
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |