diff options
author | John Brawn <john.brawn@arm.com> | 2018-09-18 13:18:21 +0000 |
---|---|---|
committer | John Brawn <john.brawn@arm.com> | 2018-09-18 13:18:21 +0000 |
commit | 83d7414e196ae9e7a6c1721c6356b5f2e8dfc919 (patch) | |
tree | 43873ac96a723195f22d9ceff0ff818a0ddb8909 /llvm/lib/CodeGen/TargetLoweringBase.cpp | |
parent | b466bb24b6f752da1098ea830277bad9c3b61209 (diff) | |
download | llvm-83d7414e196ae9e7a6c1721c6356b5f2e8dfc919.zip llvm-83d7414e196ae9e7a6c1721c6356b5f2e8dfc919.tar.gz llvm-83d7414e196ae9e7a6c1721c6356b5f2e8dfc919.tar.bz2 |
[TargetLowering] Android has sincos functions
Since Android API version 9 the Android libm has had the sincos functions, so
they should be recognised as libcalls and sincos optimisation should be applied.
Differential Revision: https://reviews.llvm.org/D52025
llvm-svn: 342471
Diffstat (limited to 'llvm/lib/CodeGen/TargetLoweringBase.cpp')
-rw-r--r-- | llvm/lib/CodeGen/TargetLoweringBase.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/TargetLoweringBase.cpp b/llvm/lib/CodeGen/TargetLoweringBase.cpp index b9cdbea..b785fdc 100644 --- a/llvm/lib/CodeGen/TargetLoweringBase.cpp +++ b/llvm/lib/CodeGen/TargetLoweringBase.cpp @@ -161,7 +161,8 @@ void TargetLoweringBase::InitLibcalls(const Triple &TT) { setLibcallName(RTLIB::FPROUND_F32_F16, "__gnu_f2h_ieee"); } - if (TT.isGNUEnvironment() || TT.isOSFuchsia()) { + if (TT.isGNUEnvironment() || TT.isOSFuchsia() || + (TT.isAndroid() && !TT.isAndroidVersionLT(9))) { setLibcallName(RTLIB::SINCOS_F32, "sincosf"); setLibcallName(RTLIB::SINCOS_F64, "sincos"); setLibcallName(RTLIB::SINCOS_F80, "sincosl"); |