Re: [Boost-bugs] [Boost C++ Libraries] #8695: boost::polygon faillure with optimizations enabled on g++-4.7.2

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #8695: boost::polygon faillure with optimizations enabled on g++-4.7.2
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-05-07 23:49:46


#8695: boost::polygon faillure with optimizations enabled on g++-4.7.2
-------------------------------+------------------------
  Reporter: hodevel@… | Owner: asydorchuk
      Type: Bugs | Status: closed
 Milestone: To Be Determined | Component: polygon
   Version: Boost 1.53.0 | Severity: Problem
Resolution: worksforme | Keywords:
-------------------------------+------------------------

Comment (by asydorchuk):

 I've found the defect in the optimizer. Only one edge (instead of four) is
 inserted into the resulting polygon_data_set inside the
 polygon_set_data.hpp:insert_vertex_sequence call. [[BR]][[BR]]

 Using binary search I've figured out, that this behavior is caused by the
 following g++ compilation option: -f-inline-small-functions.[[BR]][[BR]]

 It would be great if you could confirm that adding flag -fno-inline-small-
 functions to your prompt fixes the issue with trapezoids.[[BR]]
 [[BR]]

 Polygon code is in places quite convoluted. I rewrote
 insert_vertex_sequence so that it's more readable for humans and less
 confusing for compiler. Please find the patch attached. It will be
 automatically released with the next version of Boost.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/8695#comment:10>
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:16 UTC