Boost logo

Boost Users :

From: Victor A. Wagner Jr. (vawjr_at_[hidden])
Date: 2005-12-14 20:18:15


At 17:20 2005-12-14, Delfin Rojas wrote:
> > Neither is defined in any way AFAIK. They aren't even present in
> > Boost.Build. There also not present in Boost.Config, so I would think
> > they aren't touched in any way by Boost code.
> >
> >
> > ...Not that I know what those do, I just know how to do a text search ;-)
> >
>
>Thanks for checking. FYI, _SECURE_SCL, which is 1 by default, turns on the
>"secure" version of the C/C++ libraries. This version, among other things,
>includes extra checks in some functions. MSFT claims these checks should not
>slow down functions but I wanted to know if somebody had noticed a slowdown
>in boost libraries compiled with this option.
>
>As far as _HAS_ITERATOR_DEBUGGING, which is also 1 by default, turns on some
>extra checks inside STL _in debug mode only_. These checks are pretty heavy,

yes, and they've already found at least one bug in a boost library.

>to the point of changing the complexity of STL algorithms. For example,
>std::lower_bound(it_begin, it_end, val, pred) will execute pred(it_current,
>val) when appropriate. If _HAS_ITERATOR_DEBUGGING is 1, MSFT calls pred
>_twice_, once like pred(it_current, val) and once like (val, it_current).
>This, besides slowing down lower_bound, prohibits the use of a predicate
>that takes different argument types.

I don't see how this changes the complexity n pred calls or 2n pred
calls <shrug>

>Anyway, I think something like this could be in the boost docs, so that
>users compiling boost libraries in debug mode define it, or at least know of
>the possible effects. Opinions?

I think the "secure" library in vc2005 is worthless.
No, harmful, since it gives the illusion of providing safety were none exists.
have you actually _looked_ at the "secure" additions?

as for documenting possible debug features in different
compilers? have at it. write 'em up.

>Thanks
>
>Delfin Rojas
>
>_______________________________________________
>Boost-users mailing list
>Boost-users_at_[hidden]
>http://lists.boost.org/mailman/listinfo.cgi/boost-users

Victor A. Wagner Jr. http://rudbek.com
The five most dangerous words in the English language:
               "There oughta be a law"


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net