diff --git a/llvm/lib/CodeGen/TargetInstrInfo.cpp b/llvm/lib/CodeGen/TargetInstrInfo.cpp index fbb7c81fa1f86..b88bb9a8a0c41 100644 --- a/llvm/lib/CodeGen/TargetInstrInfo.cpp +++ b/llvm/lib/CodeGen/TargetInstrInfo.cpp @@ -1463,7 +1463,7 @@ bool TargetInstrInfo::hasLowDefLatency(const TargetSchedModel &SchedModel, unsigned DefClass = DefMI.getDesc().getSchedClass(); std::optional DefCycle = ItinData->getOperandCycle(DefClass, DefIdx); - return DefCycle <= 1; + return DefCycle <= 1U; } bool TargetInstrInfo::isFunctionSafeToSplit(const MachineFunction &MF) const {