diff --git a/bolt/lib/Core/BinaryBasicBlock.cpp b/bolt/lib/Core/BinaryBasicBlock.cpp --- a/bolt/lib/Core/BinaryBasicBlock.cpp +++ b/bolt/lib/Core/BinaryBasicBlock.cpp @@ -328,6 +328,7 @@ } } assert(Erased && "Pred is not a predecessor of this block!"); + (void)Erased; } void BinaryBasicBlock::removeDuplicateConditionalSuccessor(MCInst *CondBranch) { diff --git a/bolt/lib/Core/BinaryContext.cpp b/bolt/lib/Core/BinaryContext.cpp --- a/bolt/lib/Core/BinaryContext.cpp +++ b/bolt/lib/Core/BinaryContext.cpp @@ -809,6 +809,7 @@ break; } assert(Found && "Label not found"); + (void)Found; MCSymbol *NewLabel = Ctx->createNamedTempSymbol("duplicatedJT"); JumpTable *NewJT = new JumpTable(*NewLabel, JT->getAddress(), JT->EntrySize, JT->Type, @@ -1172,6 +1173,7 @@ } } assert(Valid); + (void)Valid; generateSymbolHashes(); } diff --git a/bolt/lib/Rewrite/RewriteInstance.cpp b/bolt/lib/Rewrite/RewriteInstance.cpp --- a/bolt/lib/Rewrite/RewriteInstance.cpp +++ b/bolt/lib/Rewrite/RewriteInstance.cpp @@ -4048,6 +4048,7 @@ if (BSec->getAllocAddress()) { assert(!DataWritten && "Writing section twice."); + (void)DataWritten; SectionData = BSec->getOutputData(); LLVM_DEBUG(dbgs() << "BOLT-DEBUG: " << (Size ? "appending" : "writing")