[PATCH] D147506: [DebugLine] save one debug line entry for empty prologue
ChenZheng via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Apr 23 19:47:56 PDT 2023
shchenz added a comment.
Hi @dblaikie , in the MCStreamer when debug line is handled in `DwarfDebug::beginInstruction()`, it already ignores the case for zero length entries, see https://github.com/llvm/llvm-project/blob/main/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp#L2020-L2024 . `DwarfDebug::beginInstruction()` is called for each instruction and if the instruction is not a "real" instruction on the platform(which means there will be zero length entry in the debug line section), no debug line entry will be added. If the instruction is a "real" instruction, then the address must be changed. So, seems `emitInitialLocDirective()` is the only place where zero length entry may be generated. What do you think? Thank you!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D147506/new/
https://reviews.llvm.org/D147506
More information about the llvm-commits
mailing list