[clang] [RemoveDIs] Update Clang front end to handle DbgRecords (PR #84756)
Stephen Tozer via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 11 10:56:03 PDT 2024
================
@@ -4746,20 +4746,32 @@ void CodeGenFunction::EmitOMPTaskBasedDirective(
if (CGF.CGM.getCodeGenOpts().hasReducedDebugInfo())
(void)DI->EmitDeclareOfAutoVariable(SharedVar, ContextValue,
CGF.Builder, false);
- llvm::Instruction &Last = CGF.Builder.GetInsertBlock()->back();
// Get the call dbg.declare instruction we just created and update
// its DIExpression to add offset to base address.
- if (auto DDI = dyn_cast<llvm::DbgVariableIntrinsic>(&Last)) {
+ auto UpdateExpr = [](llvm::LLVMContext &Ctx, auto *DDI,
----------------
SLTozer wrote:
Super nit, but in situations like this I prefer to change things like `DDI` to `Declare`; subjective, so non-blocking.
https://github.com/llvm/llvm-project/pull/84756
More information about the cfe-commits
mailing list