mirror of
https://gcc.gnu.org/git/gcc.git
synced 2024-11-27 22:03:57 +08:00
2c390a483b
The epiphany-elf target aligns structs to 8 bytes, which causes the static_assert(alignof(_Chunk) == 1) to fail. Instead of requiring _Chunks to be positionable at any alignment, ensure new buffers are aligned to alignof(_Chunk). Because the buffer size is a power of two, we know that both the buffer size and sizeof(_Chunk) are multiples of alignof(_Chunk). So is p is aligned to alignof(_Chunk) then so is (p + size - sizeof(_Chunk)). So just ensure the new buffer is aligned to at least alignof(_Chunk), which should already be true because the caller requests at least alignof(max_align_t). PR libstdc++/90046 * src/c++17/memory_resource.cc (monotonic_buffer_resource::_Chunk::allocate): Increase alignment if needed to allow placing a _Chunk at the end of the buffer. (monotonic_buffer_resource::_M_new_buffer): Remove static_assert. From-SVN: r270291 |
||
---|---|---|
.. | ||
config | ||
doc | ||
include | ||
libsupc++ | ||
po | ||
python | ||
scripts | ||
src | ||
testsuite | ||
acinclude.m4 | ||
aclocal.m4 | ||
ChangeLog | ||
ChangeLog-1998 | ||
ChangeLog-1999 | ||
ChangeLog-2000 | ||
ChangeLog-2001 | ||
ChangeLog-2002 | ||
ChangeLog-2003 | ||
ChangeLog-2004 | ||
ChangeLog-2005 | ||
ChangeLog-2006 | ||
ChangeLog-2007 | ||
ChangeLog-2008 | ||
ChangeLog-2009 | ||
ChangeLog-2010 | ||
ChangeLog-2011 | ||
ChangeLog-2012 | ||
ChangeLog-2013 | ||
ChangeLog-2014 | ||
ChangeLog-2015 | ||
ChangeLog-2016 | ||
ChangeLog-2017 | ||
ChangeLog-2018 | ||
config.h.in | ||
configure | ||
configure.ac | ||
configure.host | ||
crossconfig.m4 | ||
fragment.am | ||
linkage.m4 | ||
Makefile.am | ||
Makefile.in | ||
README |
file: libstdc++-v3/README New users may wish to point their web browsers to the file index.html in the 'doc/html' subdirectory. It contains brief building instructions and notes on how to configure the library in interesting ways.