]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/coroutine/performance/bind_processor_windows.cpp
2 // Copyright Oliver Kowalke 2009.
3 // Distributed under the Boost Software License, Version 1.0.
4 // (See accompanying file LICENSE_1_0.txt or copy at
5 // http://www.boost.org/LICENSE_1_0.txt)
7 #include "bind_processor.hpp"
16 #include <boost/config/abi_prefix.hpp>
18 void bind_to_processor( unsigned int n
)
20 if ( ::SetThreadAffinityMask( ::GetCurrentThread(), ( DWORD_PTR
)1 << n
) == 0)
21 throw std::runtime_error("::SetThreadAffinityMask() failed");
24 #include <boost/config/abi_suffix.hpp>