Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Programming Threads > Re: POD functio...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 5 of 19 Topic 4068 of 4146
Post > Topic >>

Re: POD function static initialization from function return, thread safe?

by "Chris M. Thomasson" <no@[EMAIL PROTECTED] > Oct 4, 2008 at 06:34 PM

"Thomas Richter" <thor@[EMAIL PROTECTED]
> wrote in message 
news:gc7q8k$ult$1@[EMAIL PROTECTED]
> Chris M. Thomasson wrote:
>>
>>
>> do you think that:
>>
>> PTHREAD_MUTEX_INITIALIZER
>>
>> is busted?
>
> It's the matter of the compiler vendor to ensure that this works as 
> intended.

Yes; POSIX compliant compiler along with a POSIX library is the only way
to 
ensure correctness.




> Furthermore, as long as a variable has global static storage, it might
be 
> initialized "at compile time" by placing the right data into the data 
> section of the executable, and at loading time, the problem does not 
> exist.

impl detail indeed.
 




 19 Posts in Topic:
POD function static initialization from function return, thread
Brian Cole <coleb2@[EM  2008-10-03 15:07:52 
Re: POD function static initialization from function return, thr
Thomas Richter <thor@[  2008-10-04 11:02:01 
Re: POD function static initialization from function return, thr
"Chris M. Thomasson&  2008-10-04 04:51:49 
Re: POD function static initialization from function return, thr
Thomas Richter <thor@[  2008-10-04 15:15:57 
Re: POD function static initialization from function return, thr
"Chris M. Thomasson&  2008-10-04 18:34:18 
Re: POD function static initialization from function return, thr
Anthony Williams <anth  2008-10-06 14:13:37 
Re: POD function static initialization from function return, thr
Thomas Richter <thor@[  2008-10-07 04:57:53 
Re: POD function static initialization from function return, thr
Anthony Williams <anth  2008-10-07 08:05:35 
Re: POD function static initialization from function return, thr
Thomas Richter <thor@[  2008-10-08 01:16:48 
Re: POD function static initialization from function return, thr
Hallvard B Furuseth <h  2008-10-06 19:42:02 
Re: POD function static initialization from function return, thr
David Schwartz <davids  2008-10-07 11:11:24 
Re: POD function static initialization from function return, thr
Thomas Richter <thor@[  2008-10-08 01:20:28 
Re: POD function static initialization from function return, thr
Anthony Williams <anth  2008-10-08 08:18:27 
Re: POD function static initialization from function return, thr
Brian Cole <coleb2@[EM  2008-10-07 11:31:54 
Re: POD function static initialization from function return, thr
Anthony Williams <anth  2008-10-08 08:13:53 
Re: POD function static initialization from function return, thr
David Schwartz <davids  2008-10-08 19:47:13 
Re: POD function static initialization from function return, thr
Thomas Richter <thor@[  2008-10-11 01:44:35 
Re: POD function static initialization from function return, thr
David Schwartz <davids  2008-10-08 19:50:33 
Re: POD function static initialization from function return, thr
David Schwartz <davids  2008-10-10 21:24:11 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Nov 22 8:23:56 CST 2008.