1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 04:02:41 +01:00

[Transforms/Utils] Drop unnecessary const from a return type (NFC)

Identified with const-return-type.
This commit is contained in:
Kazu Hirata 2021-02-08 22:33:49 -08:00
parent bb158b4a47
commit cde67518ef

View File

@ -77,8 +77,7 @@ static Instruction *getBranchTerminator(const PredicateBase *PB) {
// Given a predicate info that is a type of branching terminator, get the
// edge this predicate info represents
const std::pair<BasicBlock *, BasicBlock *>
getBlockEdge(const PredicateBase *PB) {
std::pair<BasicBlock *, BasicBlock *> getBlockEdge(const PredicateBase *PB) {
assert(isa<PredicateWithEdge>(PB) &&
"Not a predicate info type we know how to get an edge from.");
const auto *PEdge = cast<PredicateWithEdge>(PB);
@ -158,8 +157,7 @@ struct ValueDFS_Compare {
}
// For a phi use, or a non-materialized def, return the edge it represents.
const std::pair<BasicBlock *, BasicBlock *>
getBlockEdge(const ValueDFS &VD) const {
std::pair<BasicBlock *, BasicBlock *> getBlockEdge(const ValueDFS &VD) const {
if (!VD.Def && VD.U) {
auto *PHI = cast<PHINode>(VD.U->getUser());
return std::make_pair(PHI->getIncomingBlock(*VD.U), PHI->getParent());