mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
ARM scheduler model: Swift has varying latencies, uops for simple ALU ops
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@178842 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -4123,3 +4123,15 @@ breakPartialRegDependency(MachineBasicBlock::iterator MI,
|
||||
bool ARMBaseInstrInfo::hasNOP() const {
|
||||
return (Subtarget.getFeatureBits() & ARM::HasV6T2Ops) != 0;
|
||||
}
|
||||
|
||||
bool ARMBaseInstrInfo::isSwiftFastImmShift(const MachineInstr *MI) const {
|
||||
unsigned ShOpVal = MI->getOperand(3).getImm();
|
||||
unsigned ShImm = ARM_AM::getSORegOffset(ShOpVal);
|
||||
// Swift supports faster shifts for: lsl 2, lsl 1, and lsr 1.
|
||||
if ((ShImm == 1 && ARM_AM::getSORegShOp(ShOpVal) == ARM_AM::lsr) ||
|
||||
((ShImm == 1 || ShImm == 2) &&
|
||||
ARM_AM::getSORegShOp(ShOpVal) == ARM_AM::lsl))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
Reference in New Issue
Block a user