[PATCH] D15600: AArch64: Add option to use shared epilogues in compiler-rt

Matthias Braun via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 16 19:25:17 PST 2015


MatzeB created this revision.
MatzeB added reviewers: t.p.northover, jmolloy, mcrosier, aadg.
MatzeB added subscribers: llvm-commits, ab.
MatzeB set the repository for this revision to rL LLVM.
Herald added subscribers: rengolin, aemerson.

Most aarch64 function epilogues look the same: A series of ldp
instructions followed by a ret. In fact about all epilogues fall in 1 of
16 patterns. These 16 epilogues are put into compiler-rt to be shared
and the epilogue code is replaced with a jump to these epilogues.

In a testsuite compiled with -Os sharing the epilogues gives a 1.7% percent
code size reduction.

This patch adds the -aarch64-shared-epilogues switch I will perform more
benchmarking to decide whether this is a candidate for -Os or -Oz.

Related to rdar://23082514

Repository:
  rL LLVM

http://reviews.llvm.org/D15600

Files:
  lib/Target/AArch64/AArch64AsmPrinter.cpp
  lib/Target/AArch64/AArch64FrameLowering.cpp
  lib/Target/AArch64/AArch64FrameLowering.h
  lib/Target/AArch64/AArch64InstrInfo.td
  test/CodeGen/AArch64/shared_epilogues.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15600.43096.patch
Type: text/x-patch
Size: 10888 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151217/d399a125/attachment-0001.bin>


More information about the llvm-commits mailing list