Skip to content

Commit 317e79f

Browse files
committed
MSP430: Move libcall CC setting to RuntimeLibcallsInfo
As a temporary step configure the calling convention here. This can't be moved into tablegen until RuntimeLibcallsInfo is split into a separate lowering component.
1 parent 2bbe9b3 commit 317e79f

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

llvm/lib/IR/RuntimeLibcalls.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -364,6 +364,11 @@ void RuntimeLibcallsInfo::initLibcalls(const Triple &TT,
364364
RTLIB::HEXAGON_MEMCPY_LIKELY_ALIGNED_MIN32BYTES_MULT8BYTES,
365365
RTLIB::__hexagon_memcpy_likely_aligned_min32bytes_mult8bytes);
366366
}
367+
368+
if (TT.getArch() == Triple::ArchType::msp430) {
369+
setLibcallImplCallingConv(RTLIB::__mspabi_mpyll,
370+
CallingConv::MSP430_BUILTIN);
371+
}
367372
}
368373

369374
bool RuntimeLibcallsInfo::darwinHasExp10(const Triple &TT) {

llvm/lib/Target/MSP430/MSP430ISelLowering.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -208,8 +208,6 @@ MSP430TargetLowering::MSP430TargetLowering(const TargetMachine &TM,
208208
for (const auto &LC : LibraryCalls) {
209209
setLibcallImpl(LC.Op, LC.Impl);
210210
}
211-
setLibcallImplCallingConv(RTLIB::__mspabi_mpyll,
212-
CallingConv::MSP430_BUILTIN);
213211
}
214212

215213
setMinFunctionAlignment(Align(2));

0 commit comments

Comments
 (0)