Skip to content

Commit d1db176

Browse files
authored
ARM: Stop setting sincos_stret calling convention (#147457)
This was going out of its way to explicitly mark these as ARM_AAPCS_VFP. This has been explicitly set since 8b40366, where the commit message states that "sincos" (not sincos_stret) has a special calling convention. However, that commit also sets the calling convention for all libcalls to ARM_AAPCS_VFP, and getEffectiveCallingConv returns the same for CCC anyway in tests using isWatchABI triples. The net result of this appears to be a change in behavior when using -float-abi=soft with isWatchABI, which have no tests so I assume this is a theoretical combination. If I assert ``` if (getTargetMachine().getTargetTriple().isWatchABI()) { assert(!useSoftFloat()); assert(getEffectiveCallingConv(CallingConv::C, false) == CallingConv::ARM_AAPCS_VFP); } ``` Only 2 tests fail the second condition, which look like copy paste accidents using v7k triples with linux and only needed a filler triple. This is a consequence of strangely using the target architecture in place of the OS ABI check, as was done in 042a6c1
1 parent 085e8f1 commit d1db176

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

llvm/lib/IR/RuntimeLibcalls.cpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -169,12 +169,6 @@ void RuntimeLibcallsInfo::initLibcalls(const Triple &TT,
169169
if (darwinHasSinCosStret(TT)) {
170170
setLibcallImpl(RTLIB::SINCOS_STRET_F32, RTLIB::__sincosf_stret);
171171
setLibcallImpl(RTLIB::SINCOS_STRET_F64, RTLIB::__sincos_stret);
172-
if (TT.isWatchABI()) {
173-
setLibcallImplCallingConv(RTLIB::__sincosf_stret,
174-
CallingConv::ARM_AAPCS_VFP);
175-
setLibcallImplCallingConv(RTLIB::__sincos_stret,
176-
CallingConv::ARM_AAPCS_VFP);
177-
}
178172
}
179173

180174
if (darwinHasExp10(TT)) {

0 commit comments

Comments
 (0)