If a store address has no definition, it must be a pointer argument.
Unlike stores to alloca's, these are not dead.
Change-Id: I66e50b14ffea1cfc61fc756b5545ab8ae28b4bf8
Reviewed-on: https://swiftshader-review.googlesource.com/8573
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
{
Ice::Inst *def = definition[address];
- if(!def || llvm::isa<Ice::InstAlloca>(def))
+ if(def && llvm::isa<Ice::InstAlloca>(def))
{
return uses[address].size() == 1; // Dead if this store is the only use
}