Don't allow JIT to compile native methods
Change-Id: I12722309ba52c430e23ab862b29f7a48383f00d2
diff --git a/runtime/jit/jit_instrumentation.cc b/runtime/jit/jit_instrumentation.cc
index e2f9cec..3232674 100644
--- a/runtime/jit/jit_instrumentation.cc
+++ b/runtime/jit/jit_instrumentation.cc
@@ -77,7 +77,7 @@
ScopedObjectAccessUnchecked soa(self);
// Since we don't have on-stack replacement, some methods can remain in the interpreter longer
// than we want resulting in samples even after the method is compiled.
- if (method->IsClassInitializer() ||
+ if (method->IsClassInitializer() || method->IsNative() ||
Runtime::Current()->GetJit()->GetCodeCache()->ContainsMethod(method)) {
return;
}