
On Thu, Sep 4, 2008 at 10:26 AM, Peter Dimov <pdimov@pdimov.com> wrote:
Feature: <checked-iterators> 'on' --> _SECURE_SCL=1 'off' (default) --> _SECURE_SCL=0
I believe that the default should match the VC default, which is 1.
This has no performance implications. [snip]
I wouldn't say that it has *no* performance implications. Default settings often have large impact since many people don't take the time to learn the meaning of the various settings or tune them. In my experience, this is especially true with a complex tool like boost build. I expect this would result in a large number of executables that are needlessly slow, as is the case today. Vendors are not infallible--I believe that Microsoft made a mistake in defaulting the flag to 'on' for release builds, and that most users just assume that they are not paying a release price for this "security". We have an opportunity to employ to follow conventional best-practices with boost build defaults, and I still lean in favor of doing so. Of course there are dangers. Mixing and matching a component built with the IDE defaults with a component built with (different) boost build defaults is a recipe for disaster. Then again, it is no great thing to ship a product with slow generic inner loops. In the end, I suppose that one could make the argument that one way or another users must be educated. Nonetheless, I think we should preserve the spirit of C++ by avoiding needless release performance tax on user-written generic algorithms. - Mat