<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Sep 9, 2016, at 3:27 PM, Steve Canon via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" class="">llvm-dev@lists.llvm.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="content-type" content="text/html; charset=utf-8" class=""><div dir="auto" class=""><div class=""><div style="direction: inherit;" class=""><br class=""></div><br class="">Sent from my iPhone</div><div class=""><br class="">On Sep 9, 2016, at 6:21 PM, Abe Skolnik <<a href="mailto:a.skolnik@samsung.com" class="">a.skolnik@samsung.com</a>> wrote:<br class=""><br class=""></div><blockquote type="cite" class=""><div class=""><span class="">On 09/09/2016 04:31 PM, Stephen Canon wrote:</span><br class=""><span class=""></span><br class=""><blockquote type="cite" class=""><span class="">Gating this on -Owhatever is dangerous, .  We should simply default to the pragma “on” state universally.</span><br class=""></blockquote><span class=""></span><br class=""><span class="">Why so?  [honestly asking, not arguing]</span><br class=""><span class=""></span><br class=""><span class="">My guess: b/c we don`t want programs to give different results when compiled at different "-O<...>" settings with the exception of "-Ofast".</span></div></blockquote><div style="direction: inherit;" class=""><br class=""></div><div style="direction: inherit;" class="">Pretty much.  In particular, imagine a user trying to debug an unexpected floating point result caused by conversion of a*b + c into fma(a, b, c).</div></div></div></blockquote><br class=""></div><div>I think that’s unavoidable, because of the way the optimization levels work.  Even fma contraction is on by default (something I’d like to see), at -O0, we wouldn't be doing contraction for:</div><div><br class=""></div><div>auto x = a*b;</div><div>auto y = x+c;</div><div><br class=""></div><div>but we would do that at -O2 since we do mem2reg on x.</div><div><br class=""></div><div>-Chris</div><br class=""></body></html>