From e0267eeca7c993a5889007e59d9ef50ccc60cb26 Mon Sep 17 00:00:00 2001 From: pfg Date: Thu, 21 Nov 2013 16:44:36 +0000 Subject: libstdc++: merge non-abi changes from Apple's developer tools Take some changes from Apple's Developer Tools 4.0 [1]: block.patch emergency-buffer-reduction.patch test_cleanup.patch vector_copy_no_alloc.patch problem/6473222 copy-constructing a std::vector from an empty std::vector calls malloc 2008-10-27 Howard Hinnant stl_tree_system_header.patch Added #pragma GCC system_header to stl_tree.h. copy_doc.patch Corrected documentation concerning copy in stl_algobase.h. string_compare.patch Fixed basic_string.h, basic_string.tcc, incorrect 64bit to 32bit narrowing. Reference: [1] http://opensource.apple.com/source/libstdcxx/libstdcxx-39/patches-4.2.1/ Obtained from: Apple MFC after: 1 month --- contrib/libstdc++/libsupc++/eh_alloc.cc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'contrib/libstdc++/libsupc++/eh_alloc.cc') diff --git a/contrib/libstdc++/libsupc++/eh_alloc.cc b/contrib/libstdc++/libsupc++/eh_alloc.cc index 217a8cd..4233502 100644 --- a/contrib/libstdc++/libsupc++/eh_alloc.cc +++ b/contrib/libstdc++/libsupc++/eh_alloc.cc @@ -78,6 +78,14 @@ using namespace __cxxabiv1; # define EMERGENCY_OBJ_COUNT 4 #endif +/* APPLE LOCAL begin reduce emergency buffer size */ +/* 256 bytes is more than large enough for an std::bad_alloc object */ +#undef EMERGENCY_OBJ_SIZE +#undef EMERGENCY_OBJ_COUNT +#define EMERGENCY_OBJ_SIZE 256 +#define EMERGENCY_OBJ_COUNT 2 +/* APPLE LOCAL end reduce emergency buffer size */ + #if INT_MAX == 32767 || EMERGENCY_OBJ_COUNT <= 32 typedef unsigned int bitmask_type; #else -- cgit v1.1