[LLVMbugs] [Bug 21231] use fsel to avoid branch and compare (PPC, fast-math)
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Fri Oct 10 13:00:40 PDT 2014
http://llvm.org/bugs/show_bug.cgi?id=21231
Hal Finkel <hfinkel at anl.gov> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |INVALID
--- Comment #2 from Hal Finkel <hfinkel at anl.gov> ---
The problem here is that using fsel for the select_cc nodes here is safe only
if we assume no-NaNs and no-Infs. If you run the test with
-enable-no-infs-fp-math -enable-no-nans-fp-math also, then you'll see:
.L.goo3:
# BB#0:
frsqrtes 0, 1
addis 3, 2, .LCPI0_0 at toc@ha
fneg 13, 1
lfs 2, .LCPI0_0 at toc@l(3)
addis 3, 2, .LCPI0_1 at toc@ha
lfs 12, .LCPI0_1 at toc@l(3)
fnmsubs 3, 1, 2, 1
fmuls 4, 0, 0
fmadds 2, 3, 4, 2
fmuls 0, 0, 2
fmuls 0, 1, 0
fsel 2, 1, 12, 0
fsel 1, 13, 2, 0
blr
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20141010/86eac090/attachment.html>
More information about the llvm-bugs
mailing list