diff options
author | Chris Fairles <cfairles@gcc.gnu.org> | 2009-01-15 14:01:04 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2009-01-15 14:01:04 +0000 |
commit | 959d14e166813ae53bfc2e0bb5c2953bce764702 (patch) | |
tree | a3d0a02869ac2d4272d8edb67dd33bc6a37b3633 /libstdc++-v3/src/thread.cc | |
parent | 52535a64bf7645528bea628863a96a1588de0ac7 (diff) | |
download | gcc-959d14e166813ae53bfc2e0bb5c2953bce764702.zip gcc-959d14e166813ae53bfc2e0bb5c2953bce764702.tar.gz gcc-959d14e166813ae53bfc2e0bb5c2953bce764702.tar.bz2 |
acinclude.m4 ([GLIBCXX_ENABLE_CLOCK_GETTIME], [...]): Remove.
2009-01-15 Chris Fairles <cfairles@gcc.gnu.org>
Paolo Carlini <paolo.carlini@oracle.com>
* acinclude.m4 ([GLIBCXX_ENABLE_CLOCK_GETTIME],
[GLIBCXX_CHECK_NANOSLEEP]): Remove.
([GLIBCXX_ENABLE_LIBSTDCXX_TIME]): Add.
* configure.ac: Adjust.
* doc/xml/manual/configure.xml: Update.
* testsuite/lib/libstdc++.exp (check_v3_target_sched_yield): Add.
* testsuite/lib/dg-options.exp (dg-require-sched-yield): Add.
* testsuite/30_threads/thread/this_thread/2.cc: Use the latter.
* configure: Regenerate.
* config.h.in: Likewise.
* src/thread.cc (thread::thread(), thread::~thread, thread::get_id,
thread::joinable, thread::swap, this_thread::get_id,
this_thread::yield): Define inline...
* include/std/thread: ... here.
* config/abi/pre/gnu.ver: Adjust.
Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com>
From-SVN: r143397
Diffstat (limited to 'libstdc++-v3/src/thread.cc')
-rw-r--r-- | libstdc++-v3/src/thread.cc | 40 |
1 files changed, 1 insertions, 39 deletions
diff --git a/libstdc++-v3/src/thread.cc b/libstdc++-v3/src/thread.cc index b869e07..b7a4f83 100644 --- a/libstdc++-v3/src/thread.cc +++ b/libstdc++-v3/src/thread.cc @@ -1,6 +1,6 @@ // thread -*- C++ -*- -// Copyright (C) 2008 Free Software Foundation, Inc. +// Copyright (C) 2008, 2009 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -58,27 +58,6 @@ namespace std } } - thread::thread() - { } - - thread::~thread() - { - detach(); - } - - thread::id - thread::get_id() const - { - if(_M_thread_data) - return thread::id(_M_thread_data->_M_thread_handle); - else - return thread::id(); - } - - bool - thread::joinable() const - { return get_id() != id(); } - void thread::join() { @@ -108,12 +87,6 @@ namespace std } } - void - thread::swap(thread&& __t) - { - std::swap(_M_thread_data, __t._M_thread_data); - } - void thread::__start_thread() { @@ -123,17 +96,6 @@ namespace std if(__e) __throw_system_error(__e); } - - namespace this_thread - { - thread::id - get_id() - { return thread::id(__gthread_self()); } - - void - yield() - { __gthread_yield(); } - } } #endif // _GLIBCXX_HAS_GTHREADS && _GLIBCXX_USE_C99_STDINT_TR1 |