New AIX libstdc++ testsuite regression 20_util/allocator_members

David Edelsohn dje@watson.ibm.com
Mon Apr 22 15:28:00 GMT 2002


	I have done a little more investigating and the cause of the
problem is the single line in stl_alloc.h:

extern template class __default_alloc_template<true, 0>;

If I remove that line from stl_alloc.h, the testcase succeeds.  If I add
that line, the testcase fails.

	Comparing the assembly files, the working version has a lot of
additional code, but no other "differences".

The broken executable references:

std::__default_alloc_template<(bool)1, (int)0>::allocate(unsigned long)
std::__default_alloc_template<(bool)1, (int)0>::deallocate(void*, unsigned long)

The working version externally references:

std::__default_alloc_template<(bool)1, (int)0>::_S_start_free
std::__default_alloc_template<(bool)1, (int)0>::_S_end_free
std::__default_alloc_template<(bool)1, (int)0>::_S_heap_size
std::__default_alloc_template<(bool)1, (int)0>::_S_node_allocator_lock

and provides its own definitions of

std::__default_alloc_template<(bool)1, (int)0>::allocate(unsigned long)
std::__default_alloc_template<(bool)1, (int)0>::deallocate(void*, unsigned long)
std::__default_alloc_template<(bool)1, (int)0>::_S_freelist_index(unsigned long)
std::__default_alloc_template<(bool)1, (int)0>::_Lock::_Lock[in-charge]()
std::__default_alloc_template<(bool)1, (int)0>::_Lock::~_Lock [in-charge]()
std::__default_alloc_template<(bool)1, (int)0>::_S_round_up(unsigned long)
std::__default_alloc_template<(bool)1, (int)0>::_S_refill(unsigned long)
std::__default_alloc_template<(bool)1, (int)0>::_S_chunk_alloc(unsigned long, int&)
std::_STL_mutex_lock::_M_acquire_lock()
std::_STL_mutex_lock::_M_release_lock()
std::__new_alloc::allocate(unsigned long)
std::__new_alloc::deallocate(void*, unsigned long)

which get tightly bound.

David



More information about the Libstdc++ mailing list