Opened 7 years ago
#12018 new Bugs
rounded_arith_opp doesn't work in Release configuration under msvc 14
Reported by: | Owned by: | Boris Gubenko | |
---|---|---|---|
Milestone: | To Be Determined | Component: | interval |
Version: | Boost 1.60.0 | Severity: | Showstopper |
Keywords: | Cc: |
Description
Interval calculations with rounded_arith_opp
in Release under msvc 14 result in zero-size intervals.
It seems that compiler optimizes too much, e.g. in
BOOST_UP_NEG(x / (-y));
it moves minus operation and calculates something like
BOOST_UP_NEG(-(x / y));
which returns the same result as
BOOST_UP(x / y);
It looks more like compiler bug. Attached patch is a workaround which solves the issue.
Tested on x64 platform with /fp:strict and /fp:precise under MS Visual Studio Community 2015 Version 14.0.24720.00 Update 1.
Attachments (1)
Note:
See TracTickets
for help on using tickets.