[IRBuilder] Fix -Wunused-variable in non-assertion build. NFC

This commit is contained in:
Fangrui Song 2022-09-14 22:14:36 -07:00
parent 839ac62c50
commit 057fb8153a
1 changed files with 2 additions and 0 deletions

View File

@ -716,6 +716,7 @@ CallInst *IRBuilderBase::CreateMaskedExpandLoad(Type *Ty, Value *Ptr,
assert(PtrTy->isOpaqueOrPointeeTypeMatches(
cast<FixedVectorType>(Ty)->getElementType()) &&
"Wrong element type");
(void)PtrTy;
assert(Mask && "Mask should not be all-ones (null)");
if (!PassThru)
PassThru = UndefValue::get(Ty);
@ -738,6 +739,7 @@ CallInst *IRBuilderBase::CreateMaskedCompressStore(Value *Val, Value *Ptr,
assert(PtrTy->isOpaqueOrPointeeTypeMatches(
cast<FixedVectorType>(DataTy)->getElementType()) &&
"Wrong element type");
(void)PtrTy;
assert(Mask && "Mask should not be all-ones (null)");
Type *OverloadedTypes[] = {DataTy};
Value *Ops[] = {Val, Ptr, Mask};