From 080820c8e7a25bc3fb28d7c5a1524b0e5537c7a9 Mon Sep 17 00:00:00 2001 From: Aart Bik Date: Thu, 19 Apr 2018 04:02:36 +0000 Subject: Revert "Deopt does not throw" This reverts commit 2905de1c0e5b6a0c995be474b3f0efdfdc6a41c4. Reason for revert: test breaks on git_master-art-host; art-test-javac (linux) Change-Id: Ic39d442776858c74d2163683c78bd3a8072ad45e --- compiler/optimizing/nodes.cc | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'compiler/optimizing/nodes.cc') diff --git a/compiler/optimizing/nodes.cc b/compiler/optimizing/nodes.cc index 79bb70b9aa..f784f8f7f3 100644 --- a/compiler/optimizing/nodes.cc +++ b/compiler/optimizing/nodes.cc @@ -1916,6 +1916,15 @@ const HTryBoundary* HBasicBlock::ComputeTryEntryOfSuccessors() const { } } +bool HBasicBlock::HasThrowingInstructions() const { + for (HInstructionIterator it(GetInstructions()); !it.Done(); it.Advance()) { + if (it.Current()->CanThrow()) { + return true; + } + } + return false; +} + static bool HasOnlyOneInstruction(const HBasicBlock& block) { return block.GetPhis().IsEmpty() && !block.GetInstructions().IsEmpty() -- cgit v1.2.3-59-g8ed1b