Jim Grosbach | e516549 | 2009-11-09 00:11:35 +0000 | [diff] [blame] | 1 | ; RUN: llc < %s -march=arm -mattr=+vfp2 | grep -E {vabs.f32\\W*s\[0-9\]+,\\W*s\[0-9\]+} | count 1 |
David Goodwin | 9843a93 | 2009-10-01 22:19:57 +0000 | [diff] [blame] | 2 | ; RUN: llc < %s -march=arm -mattr=+neon -arm-use-neon-fp=1 | grep -E {vabs.f32\\W*d\[0-9\]+,\\W*d\[0-9\]+} | count 1 |
Jim Grosbach | e516549 | 2009-11-09 00:11:35 +0000 | [diff] [blame] | 3 | ; RUN: llc < %s -march=arm -mattr=+neon -arm-use-neon-fp=0 | grep -E {vabs.f32\\W*s\[0-9\]+,\\W*s\[0-9\]+} | count 1 |
Dan Gohman | fce288f | 2009-09-09 00:09:15 +0000 | [diff] [blame] | 4 | ; RUN: llc < %s -march=arm -mcpu=cortex-a8 | grep -E {vabs.f32\\W*d\[0-9\]+,\\W*d\[0-9\]+} | count 1 |
Jim Grosbach | e516549 | 2009-11-09 00:11:35 +0000 | [diff] [blame] | 5 | ; RUN: llc < %s -march=arm -mcpu=cortex-a9 | grep -E {vabs.f32\\W*s\[0-9\]+,\\W*s\[0-9\]+} | count 1 |
David Goodwin | 53e4471 | 2009-08-04 20:39:05 +0000 | [diff] [blame] | 6 | |
| 7 | define float @test(float %a, float %b) { |
| 8 | entry: |
| 9 | %dum = fadd float %a, %b |
| 10 | %0 = tail call float @fabsf(float %dum) |
| 11 | %dum1 = fadd float %0, %b |
| 12 | ret float %dum1 |
| 13 | } |
| 14 | |
| 15 | declare float @fabsf(float) |