summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/common/runtime_state.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/test/common/runtime_state.cc b/test/common/runtime_state.cc
index 298a2f0033..2203bdca01 100644
--- a/test/common/runtime_state.cc
+++ b/test/common/runtime_state.cc
@@ -152,7 +152,14 @@ extern "C" JNIEXPORT jboolean JNICALL Java_Main_isAotCompiled(JNIEnv* env,
CHECK(chars.c_str() != nullptr);
ArtMethod* method = soa.Decode<mirror::Class>(cls)->FindDeclaredDirectMethodByName(
chars.c_str(), kRuntimePointerSize);
- return method->GetOatMethodQuickCode(kRuntimePointerSize) != nullptr;
+ const void* oat_code = method->GetOatMethodQuickCode(kRuntimePointerSize);
+ if (oat_code == nullptr) {
+ return false;
+ }
+ const void* actual_code = method->GetEntryPointFromQuickCompiledCodePtrSize(kRuntimePointerSize);
+ bool interpreter =
+ Runtime::Current()->GetClassLinker()->ShouldUseInterpreterEntrypoint(method, actual_code);
+ return !interpreter;
}
extern "C" JNIEXPORT jboolean JNICALL Java_Main_hasJitCompiledEntrypoint(JNIEnv* env,