|
||||
File indexing completed on 2025-01-18 09:30:14
0001 ////////////////////////////////////////////////////////////////////////////// 0002 // 0003 // (C) Copyright Ion Gaztanaga 2015-2015. Distributed under the Boost 0004 // Software License, Version 1.0. (See accompanying file 0005 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 0006 // 0007 // See http://www.boost.org/libs/container for documentation. 0008 // 0009 ////////////////////////////////////////////////////////////////////////////// 0010 0011 #ifndef BOOST_CONTAINER_PMR_POOL_OPTIONS_HPP 0012 #define BOOST_CONTAINER_PMR_POOL_OPTIONS_HPP 0013 0014 #if defined (_MSC_VER) 0015 # pragma once 0016 #endif 0017 0018 #include <cstddef> 0019 0020 namespace boost { 0021 namespace container { 0022 namespace pmr { 0023 0024 //! The members of pool_options comprise a set of constructor options for pool resources. 0025 //! The effect of each option on the pool resource behavior is described below: 0026 //! 0027 //! - `std::size_t max_blocks_per_chunk`: The maximum number of blocks that will be allocated 0028 //! at once from the upstream memory resource to replenish a pool. If the value of 0029 //! `max_blocks_per_chunk` is zero or is greater than an implementation-defined limit, 0030 //! that limit is used instead. The implementation may choose to use a smaller value 0031 //! than is specified in this field and may use different values for different pools. 0032 //! 0033 //! - `std::size_t largest_required_pool_block`: The largest allocation size that is required 0034 //! to be fulfilled using the pooling mechanism. Attempts to allocate a single block 0035 //! larger than this threshold will be allocated directly from the upstream memory 0036 //! resource. If largest_required_pool_block is zero or is greater than an 0037 //! implementation-defined limit, that limit is used instead. The implementation may 0038 //! choose a pass-through threshold larger than specified in this field. 0039 struct pool_options 0040 { 0041 pool_options() 0042 : max_blocks_per_chunk(0u), largest_required_pool_block(0u) 0043 {} 0044 std::size_t max_blocks_per_chunk; 0045 std::size_t largest_required_pool_block; 0046 }; 0047 0048 } //namespace pmr { 0049 } //namespace container { 0050 } //namespace boost { 0051 0052 #endif //BOOST_CONTAINER_PMR_POOL_OPTIONS_HPP
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |