Go to file
Eli Friedman 638be660d7 [ARM] Eliminate redundant "mov rN, sp" instructions in Thumb1.
This takes sequences like "mov r4, sp; str r0, [r4]", and optimizes them
to something like "str r0, [sp]".

For regular stack variables, this optimization was already implemented:
we lower loads and stores using frame indexes, which are expanded later.
However, when constructing a call frame for a call with more than four
arguments, the existing optimization doesn't apply.  We need to use
stores which are actually relative to the current value of sp, and don't
have an associated frame index.

This patch adds a special case to handle that construct.  At the DAG
level, this is an ISD::STORE where the address is a CopyFromReg from SP
(plus a small constant offset).

This applies only to Thumb1: in Thumb2 or ARM mode, a regular store
instruction can access SP directly, so the COPY gets eliminated by
existing code.

The change to ARMDAGToDAGISel::SelectThumbAddrModeSP is a related
cleanup: we shouldn't pretend that it can select anything other than
frame indexes.

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

llvm-svn: 356601
2019-03-20 19:40:45 +00:00
clang Add a __has_extension check for '#pragma clang attribute' as an external-declaration 2019-03-20 19:26:37 +00:00
clang-tools-extra [clang-tidy] Fix redundant check breaking the test on many platforms. 2019-03-20 18:37:04 +00:00
compiler-rt Make __cpu_model a hidden symbol, to match libgcc. 2019-03-20 17:37:23 +00:00
debuginfo-tests
libclc sincos: Simplify declaration headers. 2019-03-13 07:13:34 +00:00
libcxx [libc++] Use the compiler that CMake found when running lit for back-deployment tests 2019-03-20 19:12:27 +00:00
libcxxabi Revert "[runtimes] Move libunwind, libc++abi and libc++ to lib/ and include/" 2019-03-08 20:33:55 +00:00
libunwind Revert "[runtimes] Move libunwind, libc++abi and libc++ to lib/ and include/" 2019-03-08 20:33:55 +00:00
lld [TailCallElim] Update tests for LTO pipeline change 2019-03-20 19:05:05 +00:00
lldb Remove the unused return value in ASTImporter::Imported [NFC] 2019-03-20 19:00:25 +00:00
llgo Adjust documentation for git migration. 2019-01-29 16:37:27 +00:00
llvm [ARM] Eliminate redundant "mov rN, sp" instructions in Thumb1. 2019-03-20 19:40:45 +00:00
openmp [OpenMP] Fix OMPT cancellation test for GOMP 2019-03-15 21:24:45 +00:00
parallel-libs Fix typos throughout the license files that somehow I and my reviewers 2019-01-21 09:52:34 +00:00
polly [CodeGen] LLVM OpenMP Backend. 2019-03-19 03:18:21 +00:00
pstl [pstl] By default, disable the parallel policies 2019-03-14 19:33:58 +00:00
.arcconfig Update monorepo .arcconfig with new project callsign. 2019-01-31 14:34:59 +00:00
.clang-format Add .clang-tidy and .clang-format files to the toplevel of the 2019-01-29 16:43:16 +00:00
.clang-tidy Disable tidy checks with too many hits 2019-02-01 11:20:13 +00:00
README.md

README.md

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.