This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ 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: [v3] mutex, condition_variable


On Tue, May 6, 2008 at 5:22 PM, NightStrike <nightstrike@gmail.com> wrote:
> On 5/6/08, Benjamin Kosnik <bkoz@redhat.com> wrote:
>  >
>  > This adds in preliminary support for C++0x mutex/condition_variable, as
>  > first posted here:
>  > http://gcc.gnu.org/ml/libstdc++/2008-03/msg00059.html
>  >
>  > Large parts of mutex are taken from the existing support in
>  > ext/concurrence.h, which explains the copyright dates on that file.
>  >
>  > This is the the subset of chapter 30 that (arguably) will not require
>  > new extensions to the gthr.h interface, and so my thinking was to stage
>  > this in first.
>  >
>  > tested x86_64/linux
>  > tested x86_64/linux --disable-threads
>  >
>  > -benjamin
>  >
>  >
>  >
>
>
>  This patch breaks windows targets.  See:
>  http://gcc.gnu.org/ml/libstdc++/2008-05/msg00022.html

More information on this failure:
>From gthr.h:
     __GTHREAD_MUTEX_INIT_FUNCTION
                some systems can't initialize a mutex without a
                function call.  On such systems, define this to a
                function which looks like this:
                  void __GTHREAD_MUTEX_INIT_FUNCTION (__gthread_mutex_t *)
                Don't define __GTHREAD_MUTEX_INIT in this case

but we use it as returning an int:
      int __e = __GTHREAD_MUTEX_INIT_FUNCTION(&_M_mutex);


Thanks,
Andrew Pinski


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