mirror of
https://github.com/boostorg/smart_ptr.git
synced 2025-07-30 20:57:21 +02:00
Enabled lwm_linux.hpp in lightweight_mutex.hpp.
[SVN r12834]
This commit is contained in:
@ -38,8 +38,8 @@
|
||||
# include <boost/detail/lwm_nop.hpp>
|
||||
#elif defined(WIN32) || defined(_WIN32) || defined(__WIN32__)
|
||||
# include <boost/detail/lwm_win32.hpp>
|
||||
//#elif defined(linux) || defined(__linux) || defined(__linux__)
|
||||
//# include <boost/detail/lwm_linux.hpp>
|
||||
#elif defined(linux) || defined(__linux) || defined(__linux__)
|
||||
# include <boost/detail/lwm_linux.hpp>
|
||||
#elif defined(BOOST_HAS_PTHREADS)
|
||||
# include <boost/detail/lwm_pthreads.hpp>
|
||||
#else
|
||||
|
@ -17,6 +17,7 @@
|
||||
//
|
||||
|
||||
#include <asm/atomic.h>
|
||||
#include <sched.h>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
@ -60,7 +61,7 @@ public:
|
||||
while( !atomic_dec_and_test(&m_.a_) )
|
||||
{
|
||||
atomic_inc(&m_.a_);
|
||||
// sched_yield();
|
||||
sched_yield();
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user