2013-06-11 22:21:44 +00:00
|
|
|
; RUN: llc -march=mipsel < %s | FileCheck %s -check-prefix=32
|
2014-04-14 16:00:28 +00:00
|
|
|
; RUN: llc -march=mips64el -mcpu=mips4 < %s | FileCheck %s -check-prefix=64
|
2013-06-11 22:21:44 +00:00
|
|
|
; RUN: llc -march=mips64el -mcpu=mips64 < %s | FileCheck %s -check-prefix=64
|
|
|
|
|
2013-07-13 20:38:47 +00:00
|
|
|
; 32-LABEL: test_sqrtf_float_:
|
2013-06-11 22:21:44 +00:00
|
|
|
; 32: sqrt.s $f[[R0:[0-9]+]], $f{{[0-9]+}}
|
|
|
|
; 32: c.un.s $f[[R0]], $f[[R0]]
|
2013-07-13 20:38:47 +00:00
|
|
|
; 64-LABEL: test_sqrtf_float_:
|
2013-06-11 22:21:44 +00:00
|
|
|
; 64: sqrt.s $f[[R0:[0-9]+]], $f{{[0-9]+}}
|
|
|
|
; 64: c.un.s $f[[R0]], $f[[R0]]
|
|
|
|
|
|
|
|
define float @test_sqrtf_float_(float %a) {
|
|
|
|
entry:
|
|
|
|
%call = tail call float @sqrtf(float %a)
|
|
|
|
ret float %call
|
|
|
|
}
|
|
|
|
|
|
|
|
declare float @sqrtf(float)
|
|
|
|
|
2013-07-13 20:38:47 +00:00
|
|
|
; 32-LABEL: test_sqrt_double_:
|
2013-06-11 22:21:44 +00:00
|
|
|
; 32: sqrt.d $f[[R0:[0-9]+]], $f{{[0-9]+}}
|
|
|
|
; 32: c.un.d $f[[R0]], $f[[R0]]
|
2013-07-13 20:38:47 +00:00
|
|
|
; 64-LABEL: test_sqrt_double_:
|
2013-06-11 22:21:44 +00:00
|
|
|
; 64: sqrt.d $f[[R0:[0-9]+]], $f{{[0-9]+}}
|
|
|
|
; 64: c.un.d $f[[R0]], $f[[R0]]
|
|
|
|
|
|
|
|
define double @test_sqrt_double_(double %a) {
|
|
|
|
entry:
|
|
|
|
%call = tail call double @sqrt(double %a)
|
|
|
|
ret double %call
|
|
|
|
}
|
|
|
|
|
|
|
|
declare double @sqrt(double)
|