Boost logo

Boost :

Subject: Re: [boost] [xint] Fourth release, requesting preliminary review again
From: Chad Nelson (chad.thecomfychair_at_[hidden])
Date: 2010-06-10 17:22:59


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 06/10/2010 05:06 PM, David Abrahams wrote:

>>> I assume you wanted to use stack-based memory for speed, but due
>>> to the above, it would likely be slower than the equivalent
>>> heap-based integer. Especially with a good caching allocator.
>>
>> In my experience, stack allocated memory easily beat heap allocation
>> even for large buffer sizes. In the past I have used a fixed string
>> type with a ridiculously large size for some specialized application
>> and it outperformed the heap based string type it replaced (I didn't
>> try to manually optimize copies away).
>
> I assume that we're going to be using the infamous “small string
> optimization” at some point, which amounts to something like
>
> boost::variant< unique_ptr<char[]>, boost::array<char, 6> >
>
> right?

I had something like that in earlier versions of the library (the
"quickdigits"). I've eliminated them from more recent versions; I figure
I can re-add them later if they prove to be useful. Until then, with all
the rewriting I've been doing on it, it was just one more place things
could go wrong.
- --
Chad Nelson
Oak Circle Software, Inc.
*
*
*
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkwRV7AACgkQp9x9jeZ9/wT8GwCgr7CjwiycgCV8ZmL/mDZmA1i8
KF4Anj+2HYo8lk89lXjKX3CbPLY4hwuT
=4N4Q
-----END PGP SIGNATURE-----


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk