diff --git a/lib/Target/AArch64/AArch64A57FPLoadBalancing.cpp b/lib/Target/AArch64/AArch64A57FPLoadBalancing.cpp index f298e118210..361963b962b 100644 --- a/lib/Target/AArch64/AArch64A57FPLoadBalancing.cpp +++ b/lib/Target/AArch64/AArch64A57FPLoadBalancing.cpp @@ -662,6 +662,10 @@ maybeKillChain(MachineOperand &MO, unsigned Idx, // determine if a chain should be ended and remove from ActiveChains. MachineInstr *MI = MO.getParent(); + if (MO.isReg() && MO.isDef()) + // We don't care about defs. We see them before uses, so reject them early. + return; + if (MO.isReg()) { // If this is a KILL of a current chain, record it.