diff options
author | James Molloy <james.molloy@arm.com> | 2015-08-29 10:49:11 +0000 |
---|---|---|
committer | James Molloy <james.molloy@arm.com> | 2015-08-29 10:49:11 +0000 |
commit | 45ee9898ecf58e759982be3da64d1c5599434ac3 (patch) | |
tree | 9fe878b8801a10088e4ccc0f70b437a69c67a2da /llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | |
parent | c378ca50439247782a87973bf876676685297854 (diff) | |
download | bcm5719-llvm-45ee9898ecf58e759982be3da64d1c5599434ac3.tar.gz bcm5719-llvm-45ee9898ecf58e759982be3da64d1c5599434ac3.zip |
[ARM] Hoist fabs/fneg above a conversion to float.
This is especially visible in softfp mode, for example in the implementation of libm fabs/fneg functions. If we have:
%1 = vmovdrr r0, r1
%2 = fabs %1
then move the fabs before the vmovdrr:
%1 = and r1, #0x7FFFFFFF
%2 = vmovdrr r0, r1
This is never a lose, and could be a serious win because the vmovdrr may be followed by a vmovrrd, which would enable us to remove the conversion into FPRs completely.
We already do this for f32, but not for f64. Tests are added for both.
llvm-svn: 246360
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp')
0 files changed, 0 insertions, 0 deletions