Directory restructuring of object.h
Break object.h into constituent files.
Reduce number of #includes in other GC header files.
Introduce -inl.h files to avoid mirror files #include-ing each other.
Check invariants of verifier RegTypes for all constructors.
Change-Id: Iecf1171c02910ac152d52947330ef456df4043bc
diff --git a/src/oat/runtime/support_invoke.cc b/src/oat/runtime/support_invoke.cc
index 7a49489..438ac8f 100644
--- a/src/oat/runtime/support_invoke.cc
+++ b/src/oat/runtime/support_invoke.cc
@@ -15,16 +15,22 @@
*/
#include "callee_save_frame.h"
+#include "dex_instruction.h"
+#include "mirror/class-inl.h"
+#include "mirror/abstract_method-inl.h"
+#include "mirror/object-inl.h"
+#include "mirror/object_array-inl.h"
#include "runtime_support.h"
namespace art {
// Determine target of interface dispatch. This object is known non-null.
-extern "C" uint64_t artInvokeInterfaceTrampoline(AbstractMethod* interface_method,
- Object* this_object, AbstractMethod* caller_method,
- Thread* self, AbstractMethod** sp)
+extern "C" uint64_t artInvokeInterfaceTrampoline(mirror::AbstractMethod* interface_method,
+ mirror::Object* this_object,
+ mirror::AbstractMethod* caller_method,
+ Thread* self, mirror::AbstractMethod** sp)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
- AbstractMethod* method;
+ mirror::AbstractMethod* method;
if (LIKELY(interface_method->GetDexMethodIndex() != DexFile::kDexNoIndex16)) {
method = this_object->GetClass()->FindVirtualMethodForInterface(interface_method);
if (UNLIKELY(method == NULL)) {
@@ -131,10 +137,13 @@
}
-static uint64_t artInvokeCommon(uint32_t method_idx, Object* this_object, AbstractMethod* caller_method,
- Thread* self, AbstractMethod** sp, bool access_check, InvokeType type)
+static uint64_t artInvokeCommon(uint32_t method_idx, mirror::Object* this_object,
+ mirror::AbstractMethod* caller_method,
+ Thread* self, mirror::AbstractMethod** sp, bool access_check,
+ InvokeType type)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
- AbstractMethod* method = FindMethodFast(method_idx, this_object, caller_method, access_check, type);
+ mirror::AbstractMethod* method = FindMethodFast(method_idx, this_object, caller_method,
+ access_check, type);
if (UNLIKELY(method == NULL)) {
FinishCalleeSaveFrameSetup(self, sp, Runtime::kRefsAndArgs);
method = FindMethodFromCode(method_idx, this_object, caller_method, self, access_check, type);
@@ -163,47 +172,47 @@
// See comments in runtime_support_asm.S
extern "C" uint64_t artInvokeInterfaceTrampolineWithAccessCheck(uint32_t method_idx,
- Object* this_object,
- AbstractMethod* caller_method,
+ mirror::Object* this_object,
+ mirror::AbstractMethod* caller_method,
Thread* self,
- AbstractMethod** sp)
+ mirror::AbstractMethod** sp)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
return artInvokeCommon(method_idx, this_object, caller_method, self, sp, true, kInterface);
}
extern "C" uint64_t artInvokeDirectTrampolineWithAccessCheck(uint32_t method_idx,
- Object* this_object,
- AbstractMethod* caller_method,
+ mirror::Object* this_object,
+ mirror::AbstractMethod* caller_method,
Thread* self,
- AbstractMethod** sp)
+ mirror::AbstractMethod** sp)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
return artInvokeCommon(method_idx, this_object, caller_method, self, sp, true, kDirect);
}
extern "C" uint64_t artInvokeStaticTrampolineWithAccessCheck(uint32_t method_idx,
- Object* this_object,
- AbstractMethod* caller_method,
- Thread* self,
- AbstractMethod** sp)
+ mirror::Object* this_object,
+ mirror::AbstractMethod* caller_method,
+ Thread* self,
+ mirror::AbstractMethod** sp)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
return artInvokeCommon(method_idx, this_object, caller_method, self, sp, true, kStatic);
}
extern "C" uint64_t artInvokeSuperTrampolineWithAccessCheck(uint32_t method_idx,
- Object* this_object,
- AbstractMethod* caller_method,
+ mirror::Object* this_object,
+ mirror::AbstractMethod* caller_method,
Thread* self,
- AbstractMethod** sp)
+ mirror::AbstractMethod** sp)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
return artInvokeCommon(method_idx, this_object, caller_method, self, sp, true, kSuper);
}
extern "C" uint64_t artInvokeVirtualTrampolineWithAccessCheck(uint32_t method_idx,
- Object* this_object,
- AbstractMethod* caller_method,
+ mirror::Object* this_object,
+ mirror::AbstractMethod* caller_method,
Thread* self,
- AbstractMethod** sp)
+ mirror::AbstractMethod** sp)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
return artInvokeCommon(method_idx, this_object, caller_method, self, sp, true, kVirtual);
}