This change is to fix the problem discussed here.
In short, if running -licm -loop-idiom on the c-code like this
int i, j, k; for (i = 0; i < 1; i++) { for (j = 0; j < 2; j++) { for (k = 0; k < 10; k++) { a[j][k] = 42; } } }
loop-idiom turns the store in the inner loop into a small memset in the middle loop and then the small memset into a big memset in the outer loop. But, the middle memset is already tagged by LICM as an unknown instruction in AliasSetTracker and deleting it in loop-idiom can trigger an assertion.
This patch teaches AliasSetTracker about MemSetInst. When deleting the small memset in loop-idiom, AliasSetTracker::ASTCallbackVH::deleted() can properly update the AliasSetTracker.
Is MSI->getOperand(0) right? I would think we would want to use getDest() here.