diff options
Diffstat (limited to 'runtime/art_method.cc')
| -rw-r--r-- | runtime/art_method.cc | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/runtime/art_method.cc b/runtime/art_method.cc index 44a5dde485..f9eedae23e 100644 --- a/runtime/art_method.cc +++ b/runtime/art_method.cc @@ -319,6 +319,21 @@ void ArtMethod::Invoke(Thread* self, uint32_t* args, uint32_t args_size, JValue* self->AssertThreadSuspensionIsAllowable(); CHECK_EQ(kRunnable, self->GetState()); CHECK_STREQ(GetInterfaceMethodIfProxy(kRuntimePointerSize)->GetShorty(), shorty); + + if (!IsNative() && + !IsObsolete() && + !IsProxyMethod() && + IsInvokable() && + ClassLinker::ShouldUseInterpreterEntrypoint(this, GetEntryPointFromQuickCompiledCode())) { + ClassLinker* cl = Runtime::Current()->GetClassLinker(); + const void* entry_point = GetEntryPointFromQuickCompiledCode(); + DCHECK(cl->IsQuickToInterpreterBridge(entry_point) || + cl->IsQuickResolutionStub(entry_point) || + entry_point == GetQuickInstrumentationEntryPoint()) + << PrettyMethod() << " is expected to be interpreted but has an unexpected entrypoint." + << " The entrypoint is " << entry_point << " (incorrect) oat entrypoint would be " + << GetOatMethodQuickCode(cl->GetImagePointerSize()); + } } // Push a transition back into managed code onto the linked list in thread. |