Re: STL vector debugging
Re: STL vector debugging
- Subject: Re: STL vector debugging
- From: Dair Grant <email@hidden>
- Date: Tue, 7 Feb 2006 19:35:29 +0000
Chris Espinosa wrote:
> To enable STL debugging mode, compile your application with the -
> D_GLIBCXX_DEBUG compile flag.
...
> STL debugging mode is recommended during developent or when you
> suspect an error caused by incorrect use of the C++ standard
> library.
One caveat to using these flags is that the gcc 3.3 implementation is
not thread safe (rdar://4417672, "Closed").
I think this was fixed for 3.4 (and 4.x), but if you need to use gcc 3.3
for pre-10.3.9 compatibility then you can't turn these on if you use STL
classes in more than one thread.
Even if each thread uses distinct objects, the extra debug code uses
some global state without locking (i.e., you would need your own global
lock around any STL usage to avoid a crash).
-dair
___________________________________________________
mailto:email@hidden http://www.zonic.co.uk/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden