Re: [Boost-bugs] [Boost C++ Libraries] #1252: [pool] severe overhead with unaligned sizes.

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #1252: [pool] severe overhead with unaligned sizes.
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2008-09-23 14:52:08


#1252: [pool] severe overhead with unaligned sizes.
--------------------------------+-------------------------------------------
  Reporter: phrosty_at_[hidden] | Owner: marshall
      Type: Bugs | Status: assigned
 Milestone: Boost 1.37.0 | Component: pool
   Version: Boost 1.34.1 | Severity: Problem
Resolution: | Keywords: pool
--------------------------------+-------------------------------------------

Comment(by cnewbold):

 What is max_type?

 After some further thought, I think that a clean solution would be to
 leverage alignment_of from Boost.Typetraits.

 Change:

 {{{
 return details::pool::lcm<size_type>(requested_size, min_size);
 }}}

 to:

 {{{
 return details::pool::lcm<size_type>(alignment_of(requested_size),
 min_size);
 }}}

-- 
Ticket URL: <http://svn.boost.org/trac/boost/ticket/1252#comment:8>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:49:58 UTC