[PATCH] D133376: Allow epilogue_begin to be emitted when generating DWARF

Ariel Burton via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 6 14:05:21 PDT 2022


Ariel-Burton created this revision.
Herald added subscribers: frasercrmck, luismarques, apazos, sameer.abuasal, pengfei, s.egerton, Jim, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, niosHD, sabuasal, simoncook, johnrusso, rbar, asb, hiraditya.
Herald added a project: All.
Ariel-Burton requested review of this revision.
Herald added subscribers: llvm-commits, pcwang-thead, MaskRay.
Herald added a project: LLVM.

We identify epilogue code by looking for instructions tagged
with FrameDestroy.

A function may have more than one epilogue, e.g., because of early
returns or code duplicated during optimization.  We need only track
the current block, and emit epilogie_begin at most once per block.

We reduce the number of entries in the line table by combining
epilogue_begin with other flags instead of emitting a separate
entry just for epilogue_begin.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D133376

Files:
  llvm/include/llvm/CodeGen/DebugHandlerBase.h
  llvm/lib/CodeGen/AsmPrinter/DebugHandlerBase.cpp
  llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
  llvm/test/CodeGen/X86/dbg-line-0-no-discriminator.ll
  llvm/test/DebugInfo/AArch64/line-header.ll
  llvm/test/DebugInfo/Generic/extended-loc-directive.ll
  llvm/test/DebugInfo/Generic/multiline.ll
  llvm/test/DebugInfo/RISCV/dwarf-riscv-relocs.ll
  llvm/test/DebugInfo/X86/basic-block-sections_1.ll
  llvm/test/DebugInfo/X86/multiple-epilogue.ll
  llvm/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D133376.458275.patch
Type: text/x-patch
Size: 13314 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220906/44d19573/attachment.bin>


More information about the llvm-commits mailing list