]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/boost/lockfree/detail/prefix.hpp
update ceph source to reef 18.1.2
[ceph.git] / ceph / src / boost / boost / lockfree / detail / prefix.hpp
1 // Copyright (C) 2009, 2016 Tim Blechmann
2 //
3 // Distributed under the Boost Software License, Version 1.0. (See
4 // accompanying file LICENSE_1_0.txt or copy at
5 // http://www.boost.org/LICENSE_1_0.txt)
6
7 #ifndef BOOST_LOCKFREE_PREFIX_HPP_INCLUDED
8 #define BOOST_LOCKFREE_PREFIX_HPP_INCLUDED
9
10 /* this file defines the following macros:
11 BOOST_LOCKFREE_CACHELINE_BYTES: size of a cache line
12 BOOST_LOCKFREE_PTR_COMPRESSION: use tag/pointer compression to utilize parts
13 of the virtual address space as tag (at least 16bit)
14 */
15
16 #if defined(__s390__) || defined(__s390x__)
17 #define BOOST_LOCKFREE_CACHELINE_BYTES 256
18 #elif defined(powerpc) || defined(__powerpc__) || defined(__ppc__)
19 #define BOOST_LOCKFREE_CACHELINE_BYTES 128
20 #else
21 #define BOOST_LOCKFREE_CACHELINE_BYTES 64
22 #endif
23
24 #include <boost/predef.h>
25
26 #if BOOST_ARCH_X86_64 || ( (BOOST_ARCH_ARM >= BOOST_VERSION_NUMBER(8,0,0)) && !BOOST_PLAT_ANDROID )
27 #define BOOST_LOCKFREE_PTR_COMPRESSION 1
28 #endif
29
30 #endif /* BOOST_LOCKFREE_PREFIX_HPP_INCLUDED */