Skip to content

Commit

Permalink
Fix HexagonGenExtract return status
Browse files Browse the repository at this point in the history
Differential Revision: https://reviews.llvm.org/D83460
  • Loading branch information
serge-sans-paille committed Jul 13, 2020
1 parent fefe755 commit 62881fd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions llvm/lib/Target/Hexagon/HexagonGenExtract.cpp
Expand Up @@ -221,15 +221,16 @@ bool HexagonGenExtract::convert(Instruction *In) {
}

bool HexagonGenExtract::visitBlock(BasicBlock *B) {
bool Changed = false;

// Depth-first, bottom-up traversal.
for (auto *DTN : children<DomTreeNode*>(DT->getNode(B)))
visitBlock(DTN->getBlock());
Changed |= visitBlock(DTN->getBlock());

// Allow limiting the number of generated extracts for debugging purposes.
bool HasCutoff = ExtractCutoff.getPosition();
unsigned Cutoff = ExtractCutoff;

bool Changed = false;
BasicBlock::iterator I = std::prev(B->end()), NextI, Begin = B->begin();
while (true) {
if (HasCutoff && (ExtractCount >= Cutoff))
Expand Down

0 comments on commit 62881fd

Please sign in to comment.