Skip to content

Commit

Permalink
[bolt] Remove redundaunt control-flow statements (NFC)
Browse files Browse the repository at this point in the history
Identified with readability-redundant-control-flow.
  • Loading branch information
kazutakahirata committed Jul 30, 2022
1 parent 60db8d9 commit b498a89
Show file tree
Hide file tree
Showing 6 changed files with 0 additions and 9 deletions.
1 change: 0 additions & 1 deletion bolt/include/bolt/Core/BinaryFunction.h
Original file line number Diff line number Diff line change
Expand Up @@ -1652,7 +1652,6 @@ class BinaryFunction {
}
OffsetToCFI.emplace(Offset, FrameInstructions.size());
FrameInstructions.emplace_back(std::forward<MCCFIInstruction>(Inst));
return;
}

BinaryBasicBlock::iterator addCFIInstruction(BinaryBasicBlock *BB,
Expand Down
1 change: 0 additions & 1 deletion bolt/lib/Core/BinaryFunction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2614,7 +2614,6 @@ bool BinaryFunction::replayCFIInstrs(int32_t FromState, int32_t ToState,
// so we might as well fall-through here.
}
NewCFIs.push_back(CurState);
continue;
}

// Replay instructions while avoiding duplicates
Expand Down
2 changes: 0 additions & 2 deletions bolt/lib/Core/BinaryFunctionProfile.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -339,8 +339,6 @@ void BinaryFunction::inferFallThroughCounts() {
}
}
}

return;
}

void BinaryFunction::clearProfile() {
Expand Down
2 changes: 0 additions & 2 deletions bolt/lib/Passes/MCF.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ void updateEdgeWeight<BinaryBasicBlock *>(EdgeWeightMap &EdgeWeights,
const BinaryBasicBlock *B,
double Weight) {
EdgeWeights[std::make_pair(A, B)] = Weight;
return;
}

template <>
Expand All @@ -95,7 +94,6 @@ void updateEdgeWeight<Inverse<BinaryBasicBlock *>>(EdgeWeightMap &EdgeWeights,
const BinaryBasicBlock *B,
double Weight) {
EdgeWeights[std::make_pair(B, A)] = Weight;
return;
}

template <class NodeT>
Expand Down
1 change: 0 additions & 1 deletion bolt/lib/Passes/ReorderAlgorithm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,6 @@ void PHGreedyClusterAlgorithm::initQueue(std::vector<EdgeTy> &Queue,
void PHGreedyClusterAlgorithm::adjustQueue(std::vector<EdgeTy> &Queue,
const BinaryFunction &BF) {
// Nothing to do.
return;
}

bool PHGreedyClusterAlgorithm::areClustersCompatible(const ClusterTy &Front,
Expand Down
2 changes: 0 additions & 2 deletions bolt/lib/Profile/DataAggregator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -316,8 +316,6 @@ void DataAggregator::processFileBuildID(StringRef FileBuildID) {
} else {
outs() << "PERF2BOLT: matched build-id and file name\n";
}

return;
}

bool DataAggregator::checkPerfDataMagic(StringRef FileName) {
Expand Down

0 comments on commit b498a89

Please sign in to comment.