PR debug/66653
* decl2.c (is_late_template_attribute): True for tls_model.
From-SVN: r225193
2015-06-30 Jason Merrill <jason@redhat.com>
+ PR debug/66653
+ * decl2.c (is_late_template_attribute): True for tls_model.
+
PR debug/66653
* cp-tree.h (CP_DECL_THREAD_LOCAL_P): New.
(DECL_GNU_TLS_P): Use DECL_LANG_SPECIFIC field.
if (is_attribute_p ("unused", name))
return false;
+ /* Attribute tls_model wants to modify the symtab. */
+ if (is_attribute_p ("tls_model", name))
+ return true;
+
/* #pragma omp declare simd attribute needs to be always deferred. */
if (flag_openmp
&& is_attribute_p ("omp declare simd", name))
--- /dev/null
+// { dg-require-effective-target tls }
+// { dg-options "-g" }
+
+template <class T>
+void f()
+{
+ static __thread int i __attribute ((tls_model ("local-exec")));
+}