diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2018-08-07 12:31:16 +0100 |
---|---|---|
committer | Jonathan Wakely <redi@gcc.gnu.org> | 2018-08-07 12:31:16 +0100 |
commit | ea2329d170827cf9d321324844035a4a2dcfec96 (patch) | |
tree | 62957004c39724b8ca85a29f12c56aa450b58fae /libcpp | |
parent | 4c9291262affd31e66dec1c8af607e07a8ce2904 (diff) | |
download | gcc-ea2329d170827cf9d321324844035a4a2dcfec96.zip gcc-ea2329d170827cf9d321324844035a4a2dcfec96.tar.gz gcc-ea2329d170827cf9d321324844035a4a2dcfec96.tar.bz2 |
Define monotonic_buffer_resource members out-of-line
Move the allocation logic into libstdc++.so so that it can be changed
without worrying about inlined code in existing binaries.
Leave do_allocate inline so that calls to it can be devirtualized, and
only the slow path needs to call into the library.
* config/abi/pre/gnu.ver: Export monotonic_buffer_resource members.
* include/std/memory_resource (monotonic_buffer_resource::release):
Call _M_release_buffers to free buffers.
(monotonic_buffer_resource::do_allocate): Call _M_new_buffer to
allocate a new buffer from upstream.
(monotonic_buffer_resource::_M_new_buffer): Declare.
(monotonic_buffer_resource::_M_release_buffers): Declare.
(monotonic_buffer_resource::_Chunk): Replace definition with
declaration as opaque type.
* src/c++17/memory_resource.cc (monotonic_buffer_resource::_Chunk):
Define.
(monotonic_buffer_resource::_M_new_buffer): Define.
(monotonic_buffer_resource::_M_release_buffers): Define.
From-SVN: r263354
Diffstat (limited to 'libcpp')
0 files changed, 0 insertions, 0 deletions