[SCCP] Remove unused toLatticeValue helper (NFC).

LatticeVal is an alias for ValueLatticeElement and the function is not
used any longer.
This commit is contained in:
Florian Hahn 2020-03-28 15:18:12 +00:00
parent 9619c2cc9a
commit a44bf59c93
1 changed files with 0 additions and 18 deletions

View File

@ -441,24 +441,6 @@ private:
return LV;
}
LatticeVal toLatticeVal(const ValueLatticeElement &V, Type *T) {
LatticeVal Res;
if (V.isUnknownOrUndef())
return Res;
if (V.isConstant()) {
Res.markConstant(V.getConstant());
return Res;
}
if (V.isConstantRange() && V.getConstantRange().isSingleElement()) {
Res.markConstant(
ConstantInt::get(T, *V.getConstantRange().getSingleElement()));
return Res;
}
Res.markOverdefined();
return Res;
}
/// getStructValueState - Return the LatticeVal object that corresponds to the
/// value/field pair. This function handles the case when the value hasn't
/// been seen yet by properly seeding constants etc.