diff options
| author | David Brazdil <dbrazdil@google.com> | 2015-10-26 14:34:30 -0500 |
|---|---|---|
| committer | David Brazdil <dbrazdil@google.com> | 2015-10-29 12:07:27 -0500 |
| commit | 39fabd6bb6fcf7a712b370d3b6fd0ada83e2e5d8 (patch) | |
| tree | 09d20062204dedd87c7a7a1163bcdf6d549b39a7 /compiler/optimizing/licm.cc | |
| parent | 59cc4e8306879ee7066d51dad4cba140e58c7292 (diff) | |
| download | art-39fabd6bb6fcf7a712b370d3b6fd0ada83e2e5d8.tar.gz art-39fabd6bb6fcf7a712b370d3b6fd0ada83e2e5d8.tar.bz2 art-39fabd6bb6fcf7a712b370d3b6fd0ada83e2e5d8.zip | |
ART: Enable more passes under try/catch
LICM, BCE, LSE are all safe under try/catch. Inliner and DCE
need updating and will be enabled in follow-up CLs.
Change-Id: I86db5f811257d5e765fea91666a2a2af0fb24ec3
Diffstat (limited to 'compiler/optimizing/licm.cc')
| -rw-r--r-- | compiler/optimizing/licm.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler/optimizing/licm.cc b/compiler/optimizing/licm.cc index c38bbe3477..27442d487e 100644 --- a/compiler/optimizing/licm.cc +++ b/compiler/optimizing/licm.cc @@ -122,6 +122,9 @@ void LICM::Run() { if (instruction->NeedsEnvironment()) { UpdateLoopPhisIn(instruction->GetEnvironment(), loop_info); } + // Move instruction into the pre header. Note that this cannot move + // a throwing instruction out of its try block since these are hoisted + // only from the header block (and TryBoundary would start a new block). instruction->MoveBefore(pre_header->GetLastInstruction()); } else if (instruction->CanThrow()) { // If `instruction` can throw, we cannot move further instructions |
