diff options
author | Jeremy Morse <jeremy.morse@sony.com> | 2025-06-11 16:35:55 +0100 |
---|---|---|
committer | Jeremy Morse <jeremy.morse@sony.com> | 2025-06-11 17:35:29 +0100 |
commit | 459475020aeff15d0f886ab99c59d66b744d3e17 (patch) | |
tree | d16e4a84e71cc75e3183cb6d0a68a86453722d84 /llvm/lib/IR/DebugInfo.cpp | |
parent | fe7bf4b90b1a835418bddd2b2aa63b4977a9f6d2 (diff) | |
download | llvm-459475020aeff15d0f886ab99c59d66b744d3e17.zip llvm-459475020aeff15d0f886ab99c59d66b744d3e17.tar.gz llvm-459475020aeff15d0f886ab99c59d66b744d3e17.tar.bz2 |
Reapply 76197ea6f91f after removing an assertion
Specifically this is the assertion in BasicBlock.cpp. Now that we're not
examining or setting that flag consistently (because it'll be deleted in
about an hour) there's no need to keep this assertion.
Original commit title:
[DebugInfo][RemoveDIs] Remove some debug intrinsic-only codepaths (#143451)
Diffstat (limited to 'llvm/lib/IR/DebugInfo.cpp')
-rw-r--r-- | llvm/lib/IR/DebugInfo.cpp | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/llvm/lib/IR/DebugInfo.cpp b/llvm/lib/IR/DebugInfo.cpp index 7db9891..2a84e7b 100644 --- a/llvm/lib/IR/DebugInfo.cpp +++ b/llvm/lib/IR/DebugInfo.cpp @@ -2123,22 +2123,11 @@ static void emitDbgAssign(AssignmentInfo Info, Value *Val, Value *Dest, Expr = *R; } DIExpression *AddrExpr = DIExpression::get(StoreLikeInst.getContext(), {}); - if (StoreLikeInst.getParent()->IsNewDbgInfoFormat) { - auto *Assign = DbgVariableRecord::createLinkedDVRAssign( - &StoreLikeInst, Val, VarRec.Var, Expr, Dest, AddrExpr, VarRec.DL); - (void)Assign; - LLVM_DEBUG(if (Assign) errs() << " > INSERT: " << *Assign << "\n"); - return; - } - auto Assign = DIB.insertDbgAssign(&StoreLikeInst, Val, VarRec.Var, Expr, Dest, - AddrExpr, VarRec.DL); + auto *Assign = DbgVariableRecord::createLinkedDVRAssign( + &StoreLikeInst, Val, VarRec.Var, Expr, Dest, AddrExpr, VarRec.DL); (void)Assign; - LLVM_DEBUG(if (!Assign.isNull()) { - if (const auto *Record = dyn_cast<DbgRecord *>(Assign)) - errs() << " > INSERT: " << *Record << "\n"; - else - errs() << " > INSERT: " << *cast<Instruction *>(Assign) << "\n"; - }); + LLVM_DEBUG(if (Assign) errs() << " > INSERT: " << *Assign << "\n"); + return; } #undef DEBUG_TYPE // Silence redefinition warning (from ConstantsContext.h). |