llvm-project/llvm
Francis Visoiu Mistrih 7a6d7672c1 [X86][Darwin] Emit compact-unwind for register-sized stack adjustments
For stack frames on the size of a register in x86, a code size optimization
emits "push rax/eax" instead of "sub" for stack allocation. For example:

foo:
  .cfi_startproc
BB#0:
  pushq %rax
Ltmp0:
  .cfi_def_cfa_offset 16
  ...
  .cfi_endproc

However, we are falling back to DWARF in this case because we cannot
encode %rax as a saved register.

This requirement is wrong, since we don't care about the contents of
%rax, it is the equivalent of a sub.

In order to specify that we care about the contents of %rax, we would
need a .cfi_offset %rax, <offset>.

It's also overzealous in the case where there are pushes for callee saved
registers followed by a "push rax/eax" instead of "sub", in which case we should
also be able to encode the callee saved regs and everything else using compact
unwind.

Patch authored by Bruno Cardoso Lopes.

Differential Revision: https://reviews.llvm.org/D13793

llvm-svn: 350623
2019-01-08 13:53:15 +00:00
..
benchmarks
bindings Python compat - iterator protocol 2019-01-03 15:43:14 +00:00
cmake [CMake] Use XCODE_ATTRIBUTE properties for code signing and entitlements in Xcode 2019-01-04 09:22:32 +00:00
docs [PGO] Use SourceFileName rather module name in PGOFuncName 2019-01-07 23:25:56 +00:00
examples Python compat - print statement 2019-01-03 14:11:33 +00:00
include Revert "Revert "Resubmit rL345008 "Split MachinePipeliner code into header and cpp files""" 2019-01-08 13:30:36 +00:00
lib [X86][Darwin] Emit compact-unwind for register-sized stack adjustments 2019-01-08 13:53:15 +00:00
projects [pstl] Initial integration with LLVM's CMake 2018-12-21 15:59:04 +00:00
resources
runtimes
test [X86][Darwin] Emit compact-unwind for register-sized stack adjustments 2019-01-08 13:53:15 +00:00
tools [llvm-readobj] Don't print '@' at end of unversioned dynsym names 2019-01-08 10:58:05 +00:00
unittests [AArch64] Add command-line option predres 2019-01-04 11:04:18 +00:00
utils gn build: Stop passing -o to ar. 2019-01-08 04:00:22 +00:00
.arcconfig
.clang-format
.clang-tidy
.gitattributes
.gitignore Git ignore CLion project configuration files. NFC 2019-01-02 19:58:07 +00:00
CMakeLists.txt [CMake] Add libunwind when 'all' is being passed as LLVM_ENABLE_PROJECTS 2018-12-20 18:39:47 +00:00
CODE_OWNERS.TXT [llvm-mca] Move llvm-mca library to llvm/lib/MCA. 2018-12-17 08:08:31 +00:00
CREDITS.TXT add Kang Zhang(shkzhang@cn.ibm.com) to the CREDITS.TXT 2018-11-25 02:56:49 +00:00
LICENSE.TXT
LLVMBuild.txt
README.txt
RELEASE_TESTERS.TXT Update the list of platforms & archs 2018-12-16 14:47:16 +00:00
configure
llvm.spec.in

README.txt

The LLVM Compiler Infrastructure
================================

This directory and its subdirectories contain source code for LLVM,
a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the documentation provided in docs/ for further
assistance with LLVM, and in particular docs/GettingStarted.rst for getting
started with LLVM and docs/README.txt for an overview of LLVM's
documentation setup.

If you are writing a package for LLVM, see docs/Packaging.rst for our
suggestions.