1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-22 20:43:44 +02:00
Go to file
Wei Mi 4f28dc3b0c [LSR] Recommit: Allow formula containing Reg for SCEVAddRecExpr related with outerloop.
The recommit includes some changes of testcases. No functional change to the patch.

In RateRegister of existing LSR, if a formula contains a Reg which is a SCEVAddRecExpr,
and this SCEVAddRecExpr's loop is an outerloop, the formula will be marked as Loser
and dropped.

Suppose we have an IR that %for.body is outerloop and %for.body2 is innerloop. LSR only
handle inner loop now so only %for.body2 will be handled.

Using the logic above, formula like
reg(%array) + reg({1,+, %size}<%for.body>) + 1*reg({0,+,1}<%for.body2>) will be dropped
no matter what because reg({1,+, %size}<%for.body>) is a SCEVAddRecExpr type reg related
with outerloop. Only formula like
reg(%array) + 1*reg({{1,+, %size}<%for.body>,+,1}<nuw><nsw><%for.body2>) will be kept
because the SCEVAddRecExpr related with outerloop is folded into the initial value of the
SCEVAddRecExpr related with current loop.

But in some cases, we do need to share the basic induction variable
reg{0 ,+, 1}<%for.body2> among LSR Uses to reduce the final total number of induction
variables used by LSR, so we don't want to drop the formula like
reg(%array) + reg({1,+, %size}<%for.body>) + 1*reg({0,+,1}<%for.body2>) unconditionally.

From the existing comment, it tries to avoid considering multiple level loops at the same time.
However, existing LSR only handles innermost loop, so for any SCEVAddRecExpr with a loop other
than current loop, it is an invariant and will be simple to handle, and the formula doesn't have
to be dropped.

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

llvm-svn: 294814
2017-02-11 00:50:23 +00:00
bindings Fix go bindings after r289702 (hopefully, don't really know how to build 2016-12-15 06:54:29 +00:00
cmake config-ix.cmake: Search for CMAKE_XCRUN before using it. 2017-02-11 00:14:01 +00:00
docs Encode duplication factor from loop vectorization and loop unrolling to discriminator. 2017-02-10 21:09:07 +00:00
examples [CMake] Fix pthread handling for out-of-tree builds 2017-02-10 01:59:20 +00:00
include [MC] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2017-02-11 00:27:28 +00:00
lib [LSR] Recommit: Allow formula containing Reg for SCEVAddRecExpr related with outerloop. 2017-02-11 00:50:23 +00:00
projects [CMake] Correct configuration order of the sub-projects based on ther dependancies 2016-10-09 20:38:29 +00:00
resources In MSVC builds embed a VERSIONINFO resource in our exe and DLL files. 2015-06-12 15:58:29 +00:00
runtimes [CMake] Handle common options for runtimes build 2017-01-10 19:47:05 +00:00
test [LSR] Recommit: Allow formula containing Reg for SCEVAddRecExpr related with outerloop. 2017-02-11 00:50:23 +00:00
tools IR: Function summary extensions for whole-program devirtualization pass. 2017-02-10 22:29:38 +00:00
unittests [XRay][graph] Disambiguate name of type from member name 2017-02-10 06:59:25 +00:00
utils vim: add returned keyword 2017-02-10 23:57:11 +00:00
.arcconfig project_id is from another era in phabricator land and does not provide any value. 2016-09-27 15:47:29 +00:00
.clang-format
.clang-tidy .clang-tidy: correct style name is 'camelBack' not 'lowerCase'. 2016-09-13 19:04:26 +00:00
.gitignore [AVR] Add the integrated testing tool to the .gitignore 2016-12-14 11:47:14 +00:00
CMakeLists.txt [CMake] Allow overriding CMAKE_LIBTOOL 2017-02-07 23:32:56 +00:00
CODE_OWNERS.TXT CODE_OWNERS: Update email address 2017-02-09 21:29:12 +00:00
configure Remove autoconf support 2016-01-26 21:29:08 +00:00
CREDITS.TXT Revert r294228 2017-02-06 19:40:56 +00:00
LICENSE.TXT Bump year to 2017 in LICENSE.txt 2017-01-12 18:02:42 +00:00
llvm.spec.in [Sparc] Implement i64 load/store support for 32-bit sparc. 2015-08-10 19:11:39 +00:00
LLVMBuild.txt
README.txt Test commit: remove a blank line. 2017-02-03 10:56:57 +00:00
RELEASE_TESTERS.TXT Update the release tester for MIPS. NFC. 2017-01-17 11:00:28 +00:00

Low Level Virtual Machine (LLVM)
================================

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.