This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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]

Re: [PATCH] Destructor support for C++11 thread_local variables


> On 10/10/2012 05:09 PM, Roland McGrath wrote:
> >> Loosely, construct on first use.
> >>
> >> IOW we need not run constructors on tls variables for a thread until a
> >> function that touches those tls variables runs on that thread.
> > 
> > That's a straightforward specification that's perfectly clear to me.
> > So what's "loose"?
> 
> One must construct all of the tls variables from a translation unit at
> the same time.

Is that a semantic requirement?  Is there a special technical reason for
it, or just "principle of least astonishment" for people who write
constructors with side effects?


Thanks,
Roland


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]