1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 18:54:02 +01:00
Go to file
Heejin Ahn 68b600d025 [WebAssembly] Fix subregion relationship in CFGSort
Summary:
The previous code for determining the innermost region in CFGSort was
not correct. We determine subregion relationship by domination of their
headers, i.e., if region A's header dominates region B's header, B is a
subregion of A. Previously we assumed that if a BB belongs to both a
loop and an exception, the region with fewer number of BBs is the
innermost one. This may not be true, because while WebAssemblyException
contains BBs in all its subregions (loops or exceptions), MachineLoop
may not, because MachineLoop does not contain BBs that don't have a path
to its header even if they are dominated by its header.

                Loop header  <---|
                    |            |
              Exception header   |
                    | \          |
                    A  B         |
                    |   \        |
                    |    C       |
                    |            |
                Loop latch       |
                    |            |
                    -------------|

For example, in this CFG, the loop does not contain B and C, because
they don't have a path back to the loops header. But for CFGSort we
consider the exception here belongs to the loop and the exception should
be a subregion of the loop and scheduled together.

So here we should use `WE->contains(ML->getHeader())` (but not
`ML->contains(WE->getHeader())`, for the stated region above).

This also fixes some comments and deletes `Regions` vector in
`RegionInfo` class, which was not used anywere.

Reviewers: dschuff

Subscribers: sbc100, jgravelle-google, hiraditya, sunfish, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D77181
2020-04-01 08:12:41 -07:00
benchmarks
bindings Add an SDK attribute to DICompileUnit 2020-03-11 14:14:06 -07:00
cmake Do export symbols when LLVM_EXPORT_SYMBOLS_FOR_PLUGINS is on. 2020-03-26 09:07:02 +00:00
docs [docs] Make llvm-addr2line documentation more explicit about which 2020-03-31 12:44:45 -07:00
examples [examples] Fixes for BUILD_SHARED_LIBS=on 2020-03-23 15:21:45 -07:00
include [LegalizeTypes][RISCV] Correctly sign-extend comparison for ATOMIC_CMP_XCHG 2020-04-01 15:51:26 +01:00
lib [WebAssembly] Fix subregion relationship in CFGSort 2020-04-01 08:12:41 -07:00
projects
resources
runtimes [runtimes] When COMPILER_RT is enabled, consider SANITIZER prefixes 2020-03-11 14:22:20 -07:00
test [WebAssembly] Fix subregion relationship in CFGSort 2020-04-01 08:12:41 -07:00
tools [llvm-readobj] - Do not crash when SHT_HASH table is broken. 2020-04-01 18:03:02 +03:00
unittests [RISCV] Support RISC-V ELF attributes sections in llvm-readobj. 2020-04-01 21:50:11 +08:00
utils [lit] Refine adoption of argparse --version action 2020-03-31 16:02:16 -07:00
.clang-format
.clang-tidy
.gitattributes
.gitignore Continue removing llgo. 2020-02-10 10:33:58 -08:00
CMakeLists.txt [cmake] Fix -stripped for umbrella library install targets 2020-03-20 18:46:48 -07:00
CODE_OWNERS.TXT Remove myself from CODE_OWNERS. 2020-02-25 11:59:29 +00:00
configure
CREDITS.TXT
LICENSE.TXT
llvm.spec.in
LLVMBuild.txt
README.txt Test commit. 2020-03-14 18:08:26 -07:00
RELEASE_TESTERS.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.