ART: Only call CalculateBasicBlockInformation once
CalculateBasicBlockInformation gets called twice now when dirty is true.
Change-Id: I8aa0569e4c00ea884a45ecea957a4ae06a328969
Signed-off-by: Jean Christophe Beyler <jean.christophe.beyler@intel.com>
diff --git a/compiler/dex/pass_driver_me_opts.cc b/compiler/dex/pass_driver_me_opts.cc
index ed2c2d2..6281062 100644
--- a/compiler/dex/pass_driver_me_opts.cc
+++ b/compiler/dex/pass_driver_me_opts.cc
@@ -88,11 +88,9 @@
// Now we care about flags.
if ((pass_me->GetFlag(kOptimizationBasicBlockChange) == true) ||
(pass_me->GetFlag(kOptimizationDefUsesChange) == true)) {
- CompilationUnit* c_unit = pass_me_data_holder->c_unit;
- c_unit->mir_graph.get()->CalculateBasicBlockInformation();
-
// Is it dirty at least?
if (pass_me_data_holder->dirty == true) {
+ CompilationUnit* c_unit = pass_me_data_holder->c_unit;
c_unit->mir_graph.get()->CalculateBasicBlockInformation();
}
}