This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] remove unused __gthread_cond_timedwait_recursive
- From: Ian Lance Taylor <iant at google dot com>
- To: Jonathan Wakely <jwakely dot gcc at gmail dot com>
- Cc: gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 17 Dec 2012 21:53:52 -0800
- Subject: Re: [patch] remove unused __gthread_cond_timedwait_recursive
- References: <CAH6eHdRVpSX9uZaY8fRj9NFmQOR2fCMQe=Xjzyr0x4m9NoOBkQ@mail.gmail.com>
On Mon, Dec 17, 2012 at 3:41 PM, Jonathan Wakely <jwakely.gcc@gmail.com> wrote:
> libgcc/ghtr.h claims that __gthread_cond_timedwait_recursive should be
> defined to support the c++0x thread library, but that function isn't
> used or needed anywhere by libstdc++: std::condition_variable can
> only be used with std::mutex (i.e. a non-recursive mutex) and
> std::condition_variable_any uses a std::mutex internally so only ever
> waits on a non-recursive mutex.
>
> This patch removes the comment saying its required and the unused
> gthr-posix.h implementation.
>
> * gthr.h (__gthread_cond_timedwait_recursive): Do not require.
> * gthr-posix.h (__gthread_cond_timedwait_recursive): Remove.
>
> Tested x86_64-linux, OK for trunk, or should this wait for stage 1?
This is OK now.
Thanks.
Ian