This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ping -- Re: merge branch profile-stdlib


2009/6/8 Silvius Rus:
>> - Uglified names.  I did this by placing all diagnostic implementation
>> under namespace __cxxprof_impl.  (Is this sufficient?)

Users are allowed to say
#define turn_on 1
#include <vector>

It looks like this would cause an error if profiled.


>> - We are using vector and unordered_map in the implementation, with
>> default allocators.  This can cause infinite cycles if say the
>> application code uses libstdc++ containers to gather allocation
>> statistics.

That seems problematic to me - does it mean that users wanting to
improve their use of standard containers must use (and possibly write)
non-standard containers?

Would it be possible to expose the standard containers via a different
namespace, so they can be used to gather statistics?

e.g.__gnucxx_not_profiled::vector would be a std::vector-compatible
type (based on the same code) without profiling support, that could be
used to gather statistics about std::vector use - is that possible, or
have I misunderstood what you meant?

Just my two (not a libstdc++ maintainer) cents,

Jonathan


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]