Re: [Boost-bugs] [Boost C++ Libraries] #3030: [crc] optimization of crc_optimal::process_block

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #3030: [crc] optimization of crc_optimal::process_block
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2011-12-16 05:59:16


#3030: [crc] optimization of crc_optimal::process_block
-------------------------------+--------------------------------------------
  Reporter: qehgt0@… | Owner: dlwalker
      Type: Patches | Status: new
 Milestone: Boost 1.40.0 | Component: crc
   Version: Boost 1.39.0 | Severity: Optimization
Resolution: | Keywords: crc
-------------------------------+--------------------------------------------

Comment (by Vasily Titskiy <qehgt0@…>):

 Compiler is assuming (and it is correct assumption from compiler's point
 of view) that memory location of member variable 'this->rem' can be
 between 'bytes_begin' and 'bytes_end'.

 So, compiler _must_ generate non-optimal code for this loop that always
 stores temporary value of 'rem' variable into memory before processing
 every next byte.

 It should be same or faster on every system.

 I can check it on msvc2008, armv7-gcc3.2/gcc4.6, intel x86/amd64 later, if
 it needed.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/3030#comment:3>
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:50:08 UTC