Changeset View
Changeset View
Standalone View
Standalone View
llvm/trunk/lib/Target/ARM/ARMBaseInstrInfo.cpp
Show First 20 Lines • Show All 2,819 Lines • ▼ Show 20 Lines | if (Instr.modifiesRegister(ARM::CPSR, TRI) || | ||||
return false; | return false; | ||||
} while (I != B); | } while (I != B); | ||||
// Return false if no candidates exist. | // Return false if no candidates exist. | ||||
if (!MI && !SubAdd) | if (!MI && !SubAdd) | ||||
return false; | return false; | ||||
// The single candidate is called MI. | // If we found a SubAdd, use it as it will be closer to the CMP | ||||
if (!MI) MI = SubAdd; | if (SubAdd) { | ||||
MI = SubAdd; | |||||
IsThumb1 = false; | |||||
} | |||||
// We can't use a predicated instruction - it doesn't always write the flags. | // We can't use a predicated instruction - it doesn't always write the flags. | ||||
if (isPredicated(*MI)) | if (isPredicated(*MI)) | ||||
return false; | return false; | ||||
// Scan forward for the use of CPSR | // Scan forward for the use of CPSR | ||||
// When checking against MI: if it's a conditional code that requires | // When checking against MI: if it's a conditional code that requires | ||||
// checking of the V bit or C bit, then this is not safe to do. | // checking of the V bit or C bit, then this is not safe to do. | ||||
▲ Show 20 Lines • Show All 2,267 Lines • Show Last 20 Lines |