mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-27 00:21:03 +00:00
Convert InsertValueInst and ExtractValueInst APIs to use ArrayRef.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135040 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -592,8 +592,7 @@ Value *Lint::findValueImpl(Value *V, bool OffsetOk,
|
||||
return findValueImpl(CI->getOperand(0), OffsetOk, Visited);
|
||||
} else if (ExtractValueInst *Ex = dyn_cast<ExtractValueInst>(V)) {
|
||||
if (Value *W = FindInsertedValue(Ex->getAggregateOperand(),
|
||||
Ex->idx_begin(),
|
||||
Ex->idx_end()))
|
||||
Ex->getIndices()))
|
||||
if (W != V)
|
||||
return findValueImpl(W, OffsetOk, Visited);
|
||||
} else if (ConstantExpr *CE = dyn_cast<ConstantExpr>(V)) {
|
||||
@@ -607,9 +606,7 @@ Value *Lint::findValueImpl(Value *V, bool OffsetOk,
|
||||
return findValueImpl(CE->getOperand(0), OffsetOk, Visited);
|
||||
} else if (CE->getOpcode() == Instruction::ExtractValue) {
|
||||
ArrayRef<unsigned> Indices = CE->getIndices();
|
||||
if (Value *W = FindInsertedValue(CE->getOperand(0),
|
||||
Indices.begin(),
|
||||
Indices.end()))
|
||||
if (Value *W = FindInsertedValue(CE->getOperand(0), Indices))
|
||||
if (W != V)
|
||||
return findValueImpl(W, OffsetOk, Visited);
|
||||
}
|
||||
|
Reference in New Issue
Block a user