xref: /aosp_15_r20/external/llvm/test/CodeGen/Mips/llvm-ir/sqrt.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -march=mipsel -mcpu=mips32r2 -mattr=+micromips | FileCheck %s
2*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -march=mips -mcpu=mips32r2 -mattr=+micromips | FileCheck %s
3*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -march=mips -mcpu=mips32r6 -mattr=+micromips | FileCheck %s
4*9880d681SAndroid Build Coastguard Worker
5*9880d681SAndroid Build Coastguard Workerdefine float @sqrt_fn(float %value) #0 {
6*9880d681SAndroid Build Coastguard Workerentry:
7*9880d681SAndroid Build Coastguard Worker  %sqrtf = tail call float @sqrtf(float %value) #0
8*9880d681SAndroid Build Coastguard Worker  ret float %sqrtf
9*9880d681SAndroid Build Coastguard Worker}
10*9880d681SAndroid Build Coastguard Worker
11*9880d681SAndroid Build Coastguard Workerdeclare float @sqrtf(float)
12*9880d681SAndroid Build Coastguard Worker
13*9880d681SAndroid Build Coastguard Worker; CHECK: sqrt.s $f0, $f12
14