Disable inlining in Optimizing when --debuggable is set.
Change-Id: I6365269e606e0c176e518c06719ebdaf6a4c4b88
diff --git a/compiler/optimizing/inliner.cc b/compiler/optimizing/inliner.cc
index e22f7cc..bd9267c 100644
--- a/compiler/optimizing/inliner.cc
+++ b/compiler/optimizing/inliner.cc
@@ -38,6 +38,11 @@
static constexpr int kDepthLimit = 5;
void HInliner::Run() {
+ if (graph_->IsDebuggable()) {
+ // For simplicity, we currently never inline when the graph is debuggable. This avoids
+ // doing some logic in the runtime to discover if a method could have been inlined.
+ return;
+ }
const GrowableArray<HBasicBlock*>& blocks = graph_->GetReversePostOrder();
for (size_t i = 0; i < blocks.Size(); ++i) {
HBasicBlock* block = blocks.Get(i);