public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [v3]  pb_ds fixes for debug mode, valgrind
@ 2011-05-24  9:38 Benjamin Kosnik
  0 siblings, 0 replies; only message in thread
From: Benjamin Kosnik @ 2011-05-24  9:38 UTC (permalink / raw)
  To: libstdc++, gcc-patches

[-- Attachment #1: Type: text/plain, Size: 1516 bytes --]


This aims to fix several longstanding memory issues in ext/pb_ds, and
the rest of the -D_GLIBCXX_DEBUG fails. I believe PR libstdc++/37144
and PR libstdc++/28457 apply. 

In a nutshell, these fixes were

1) ov_tree_map/join, remove debug join, adjust dtor
2) trie/rec_split, move to opportunistic interator usage
3) binary_heap/pop, adjust pop_heap usage, be caseful
about make_heap.

Anyway. This extension code is the last part of the docs not expressed
in doxygen and docbook. The docbook parts are in motion but the
conversion is not yet complete. Here's the doxygen part and some
refactoring based on it. There are several transformations and
reductions (null_type consolidation, template parameter reductions in
pat_trie, etc, etc, etc.) Perhaps I went too far with some
of the reductions and replacements in pat_trie_base, where I stripped
out the _Alloc parameter in a fit of pique. Enough with the rebinding!!!
It can be re-added, but it seems like the smarter ploy is to integrate
this with the trie traits class as a base in a more streamlined manner
with conscious attention being paid to minimizing the rebinds....

I'll be curious to see/do this as part of C++0x allocator work. 

There is a known issue WRT doxygen and figuring out
template-metaprogrammed base types, discussed here:
https://svn.boost.org/trac/boost/wiki/Guidelines/DoxygenGuidelines

Unfortunately this exists in abundance with this design.

tested x86_64/linux
make check
make check-debug
make check-performance
valgrind

-benjamin

[-- Attachment #2: 20110523-4.patch.bz2 --]
[-- Type: application/x-bzip, Size: 107610 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-05-24  2:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-24  9:38 [v3] pb_ds fixes for debug mode, valgrind Benjamin Kosnik

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).