This is the mail archive of the gcc-bugs@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]

[Bug libstdc++/51296] Several 30_threads tests FAIL on Tru64 UNIX


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51296

--- Comment #25 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-01-13 10:37:52 UTC ---
Nice digging.  POSIX does say the INIT macro is for use when the mutex is
statically-allocated:

"In cases where default mutex attributes are appropriate, the macro
PTHREAD_MUTEX_INITIALIZER can be used to initialize mutexes that are statically
allocated."


For most platforms it works fine for automatic variables and in C++ for member
variables too.

Maybe something scans the BSS segment at startup to find mutexes?!  In any
case, it looks as though we should definitely use the init function instead of
the macro on Tru64.


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