gcc/libcpp/include
Tom Tromey b9bd6f7438 Reduce memory waste due to non-power-of-2 allocs
This patch basically arranges for the allocation size of line_map
buffers to be as close as possible to a power of two.  This
*significantly* decreases peak memory consumption as (macro) maps are
numerous and stay live during all the compilation.

The patch adds a new ggc_round_alloc_size interface to the ggc
allocator.  In each of the two main allocator implementations ('page'
and 'zone') the function has been extracted from the main allocation
function code and returns the actual size of the allocated memory
region, thus giving a chance to the caller to maximize the amount of
memory it actually uses from the allocated memory region.  In the
'none' allocator implementation (that uses xmalloc) the
ggc_round_alloc_size just returns the requested allocation size.

Co-Authored-By: Dodji Seketeli <dodji@redhat.com>

From-SVN: r180086
2011-10-17 12:00:07 +02:00
..
cpp-id-data.h directives.c (do_linemarker, do_line): Use CPP_STRING for ignored enum value. 2009-07-18 03:22:16 +00:00
cpplib.h Support -fdebug-cpp option 2011-10-17 11:59:40 +02:00
line-map.h Reduce memory waste due to non-power-of-2 allocs 2011-10-17 12:00:07 +02:00
mkdeps.h directives.c (do_linemarker, do_line): Use CPP_STRING for ignored enum value. 2009-07-18 03:22:16 +00:00
symtab.h Update Copyright years for files modified in 2010. 2011-01-03 21:52:22 +01:00