Skip to content
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion llvm/include/llvm/MC/MCInstrItineraries.h
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ class InstrItineraryData {
return std::nullopt;

UseCycle = *DefCycle - *UseCycle + 1;
if (UseCycle > 0 &&
if (UseCycle > 0u &&
hasPipelineForwarding(DefClass, DefIdx, UseClass, UseIdx))
// FIXME: This assumes one cycle benefit for every pipeline forwarding.
UseCycle = *UseCycle - 1;
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4110,7 +4110,7 @@ std::optional<unsigned> ARMBaseInstrInfo::getOperandLatency(
return std::nullopt;

UseCycle = *DefCycle - *UseCycle + 1;
if (UseCycle > 0) {
if (UseCycle > 0u) {
if (LdmBypass) {
// It's a variable_ops instruction so we can't use DefIdx here. Just use
// first def operand.
Expand Down