Skip to content
This repository has been archived by the owner on Mar 28, 2020. It is now read-only.
/ swift-llvm Public archive

Fix swift error throwing on non-darwin ARM platforms #55

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/Target/ARM/ARMBaseRegisterInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ ARMBaseRegisterInfo::getCalleeSavedRegs(const MachineFunction *MF) const {
}
}

if (STI.isTargetDarwin() && STI.getTargetLowering()->supportSwiftError() &&
if (STI.getTargetLowering()->supportSwiftError() &&
F->getAttributes().hasAttrSomewhere(Attribute::SwiftError))
return CSR_iOS_SwiftError_SaveList;

Expand Down Expand Up @@ -110,7 +110,7 @@ ARMBaseRegisterInfo::getCallPreservedMask(const MachineFunction &MF,
// This is academic becase all GHC calls are (supposed to be) tail calls
return CSR_NoRegs_RegMask;

if (STI.isTargetDarwin() && STI.getTargetLowering()->supportSwiftError() &&
if (STI.getTargetLowering()->supportSwiftError() &&
MF.getFunction()->getAttributes().hasAttrSomewhere(Attribute::SwiftError))
return CSR_iOS_SwiftError_RegMask;

Expand Down