OSDN Git Service

ART: Fix NullCheckElimination, BBCombine, and SplitBlock
authorRazvan A Lupusoru <razvan.a.lupusoru@intel.com>
Thu, 30 Oct 2014 01:42:27 +0000 (18:42 -0700)
committerRazvan A Lupusoru <razvan.a.lupusoru@intel.com>
Sat, 22 Nov 2014 02:13:40 +0000 (18:13 -0800)
commitc7a77bfecb77c7a4538775411049e76eb853641c
treefe440bcee0a60ab96e6ca6ae446381d63feed385
parent124cd8f768436e082ca0dfed8f1e4f4713220e44
ART: Fix NullCheckElimination, BBCombine, and SplitBlock

NullCheckElimination had one issue and one assumption that could be
broken:
-It ignored that compiler temps may hold references.
-Assumed there are no phi nodes even though algorithm can be run even
after phi nodes are inserted.

BBCombine also had issue in that it did not properly maintain the
instruction links. The logic has been updated to use utility methods.

SplitBlock has an issue with being called after extended instructions
are inserted. Namely, in the case in question, it was called after
SpecialMethodInliner was through and although it was doing semantically
correct thing, it was hitting dcheck due to the kMirOpNullCheck.

Change-Id: Id5863ddb0762064e74bf1d9173b8db5cb47cf3b9
Signed-off-by: Razvan A Lupusoru <razvan.a.lupusoru@intel.com>
compiler/dex/mir_graph.cc
compiler/dex/mir_optimization.cc