[PATCH] D42720: [CodeGen] Switch non-SJLJ EH encoding to uleb128

Ryan Prichard via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 30 16:06:14 PST 2018


rprichard created this revision.
Herald added subscribers: llvm-commits, JDevlieghere, javed.absar, aprantl.

With this commit, LLVM emits a DWARF EH table using GCC-style assembly by
default. Offsets in the EH table (code offsets in the call site table,
the call site table size, and the offset to TTBase) are calculated in the
assembler rather than in the compiler. Doing so allows switching the
encoding of code offsets in the call site table from udata4 to uleb128,
which can reduce the size of the EH table by half.

This behavior is on by default. The old behavior can be restored with
-mllvm -layout-eh-table-in-assembler=0.


Repository:
  rL LLVM

https://reviews.llvm.org/D42720

Files:
  include/llvm/CodeGen/AsmPrinter.h
  include/llvm/MC/MCObjectStreamer.h
  include/llvm/MC/MCStreamer.h
  lib/CodeGen/AsmPrinter/ARMException.cpp
  lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp
  lib/CodeGen/AsmPrinter/DwarfException.h
  lib/CodeGen/AsmPrinter/EHStreamer.cpp
  lib/CodeGen/AsmPrinter/EHStreamer.h
  lib/MC/MCAsmStreamer.cpp
  lib/MC/MCObjectStreamer.cpp
  lib/MC/MCStreamer.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D42720.132079.patch
Type: text/x-patch
Size: 21907 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180131/7100c6ce/attachment.bin>


More information about the llvm-commits mailing list