mirror of
https://github.com/RPCSX/llvm.git
synced 2025-03-03 18:37:56 +00:00
[JumpThreading] Change a return of ComputeValueKnownInPredecessors()
Change a return statement of ComputeValueKnownInPredecessors() to be the same as the rest return statements of the function. Otherwise, it might return true with an empty Result when the current basic block has no predecessors and trigger the first assert of JumpThreading::ProcessThreadableEdges(). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@260110 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
98d69cc318
commit
b21e2903ef
@ -415,7 +415,7 @@ ComputeValueKnownInPredecessors(Value *V, BasicBlock *BB, PredValueInfo &Result,
|
||||
for (BasicBlock *Pred : predecessors(BB))
|
||||
Result.push_back(std::make_pair(KC, Pred));
|
||||
|
||||
return true;
|
||||
return !Result.empty();
|
||||
}
|
||||
|
||||
// If V is a non-instruction value, or an instruction in a different block,
|
||||
|
Loading…
x
Reference in New Issue
Block a user