forked from OSchip/llvm-project
For some targets pointer and int are 16-bits. Allow 16-bits as a valid index
in such cases. llvm-svn: 58505
This commit is contained in:
parent
98bb1fa69e
commit
e3ba47b71b
|
@ -1516,7 +1516,8 @@ void PointerType::typeBecameConcrete(const DerivedType *AbsTy) {
|
|||
|
||||
bool SequentialType::indexValid(const Value *V) const {
|
||||
if (const IntegerType *IT = dyn_cast<IntegerType>(V->getType()))
|
||||
return IT->getBitWidth() == 32 || IT->getBitWidth() == 64;
|
||||
return IT->getBitWidth() == 16 ||
|
||||
IT->getBitWidth() == 32 || IT->getBitWidth() == 64;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue