Skip to content

Commit e8f8b89

Browse files
committed
[NFC] Ignore unused vars in no-asserts builds
1 parent 92e1723 commit e8f8b89

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

llvm/lib/IR/DebugInfo.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1762,6 +1762,7 @@ static CallInst *emitDbgAssign(AssignmentInfo Info, Value *Val, Value *Dest,
17621762
const VarRecord &VarRec, DIBuilder &DIB) {
17631763
auto *ID = StoreLikeInst.getMetadata(LLVMContext::MD_DIAssignID);
17641764
assert(ID && "Store instruction must have DIAssignID metadata");
1765+
(void)ID;
17651766

17661767
DIExpression *Expr = DIExpression::get(StoreLikeInst.getContext(), None);
17671768
if (!Info.StoreToWholeAlloca) {
@@ -1911,6 +1912,7 @@ void AssignmentTrackingPass::runOnFunction(Function &F) {
19111912
for (auto &P : DbgDeclares) {
19121913
const AllocaInst *Alloca = P.first;
19131914
auto Markers = at::getAssignmentMarkers(Alloca);
1915+
(void)Markers;
19141916
for (DbgDeclareInst *DDI : P.second) {
19151917
// Assert that the alloca that DDI uses is now linked to a dbg.assign
19161918
// describing the same variable (i.e. check that this dbg.declare

0 commit comments

Comments
 (0)