[SimplifyCFG] mergeConditionalStoreToAddress(): try to pacify MSAN

MSAN bot complains that there is use-of-uninitialized-value
of this FreeStores later in IsWorthwhile().
Perhaps FreeStores needs to be stored in a vector?

llvm-svn: 372262
This commit is contained in:
Roman Lebedev 2019-09-18 21:04:39 +00:00
parent ab8b456ce5
commit feea722cf3
1 changed files with 1 additions and 1 deletions

View File

@ -3022,7 +3022,7 @@ static bool mergeConditionalStoreToAddress(BasicBlock *PTB, BasicBlock *PFB,
return true;
};
ArrayRef<StoreInst *> FreeStores = {PStore, QStore};
const SmallVector<StoreInst *, 2> FreeStores = {PStore, QStore};
if (!MergeCondStoresAggressively &&
(!IsWorthwhile(PTB, FreeStores) || !IsWorthwhile(PFB, FreeStores) ||
!IsWorthwhile(QTB, FreeStores) || !IsWorthwhile(QFB, FreeStores)))