Lines Matching refs:art

97   art::ArtMethod* FindObsoleteVersion(art::ArtMethod* original) const  in FindObsoleteVersion()
98 REQUIRES(art::Locks::mutator_lock_, art::Roles::uninterruptible_) { in FindObsoleteVersion()
101 art::ArtMethod* res = obsolete_methods_->GetElementPtrSize<art::ArtMethod*>( in FindObsoleteVersion()
102 method_pair->second, art::kRuntimePointerSize); in FindObsoleteVersion()
110 void RecordObsolete(art::ArtMethod* original, art::ArtMethod* obsolete) in RecordObsolete()
111 REQUIRES(art::Locks::mutator_lock_, art::Roles::uninterruptible_) { in RecordObsolete()
117 obsolete_methods_->GetElementPtrSize<art::ArtMethod*>(slot, art::kRuntimePointerSize)); in RecordObsolete()
119 obsolete_methods_->SetElementPtrSize(slot, obsolete, art::kRuntimePointerSize); in RecordObsolete()
124 ObsoleteMap(art::ObjPtr<art::mirror::PointerArray> obsolete_methods, in ObsoleteMap()
125 art::ObjPtr<art::mirror::ObjectArray<art::mirror::DexCache>> obsolete_dex_caches, in ObsoleteMap()
126 art::ObjPtr<art::mirror::DexCache> original_dex_cache) in ObsoleteMap()
132 while (obsolete_methods_->GetElementPtrSize<art::ArtMethod*>( in ObsoleteMap()
133 next_free_slot_, art::kRuntimePointerSize) != nullptr) { in ObsoleteMap()
142 art::ArtMethod* old_method;
143 art::ArtMethod* obsolete_method;
149 REQUIRES(art::Locks::mutator_lock_, art::Roles::uninterruptible_) { in operator *()
150 art::ArtMethod* obsolete = map_->FindObsoleteVersion(iter_->first); in operator *()
176 std::unordered_map<art::ArtMethod*, int32_t>::const_iterator iter) in ObsoleteMapIter()
180 mutable std::unordered_map<art::ArtMethod*, int32_t>::const_iterator iter_;
195 std::unordered_map<art::ArtMethod*, int32_t> id_map_;
198 art::ObjPtr<art::mirror::PointerArray> obsolete_methods_;
199 art::ObjPtr<art::mirror::ObjectArray<art::mirror::DexCache>> obsolete_dex_caches_;
200 art::ObjPtr<art::mirror::DexCache> original_dex_cache_;
205 class ObsoleteMethodStackVisitor : public art::StackVisitor {
208 art::Thread* thread, in ObsoleteMethodStackVisitor()
209 art::LinearAlloc* allocator, in ObsoleteMethodStackVisitor()
210 const std::unordered_set<art::ArtMethod*>& obsoleted_methods, in ObsoleteMethodStackVisitor()
226 art::Thread* thread, in UpdateObsoleteFrames()
227 art::LinearAlloc* allocator, in UpdateObsoleteFrames()
228 const std::unordered_set<art::ArtMethod*>& obsoleted_methods, in UpdateObsoleteFrames()
230 REQUIRES(art::Locks::mutator_lock_) { in UpdateObsoleteFrames()
238 bool VisitFrame() override REQUIRES(art::Locks::mutator_lock_) { in VisitFrame()
239 art::ScopedAssertNoThreadSuspension snts("Fixing up the stack for obsolete methods."); in VisitFrame()
240 art::ArtMethod* old_method = GetMethod(); in VisitFrame()
247 art::ArtMethod* new_obsolete_method = obsolete_maps_->FindObsoleteVersion(old_method); in VisitFrame()
250 art::Runtime* runtime = art::Runtime::Current(); in VisitFrame()
251 art::ClassLinker* cl = runtime->GetClassLinker(); in VisitFrame()
253 const size_t method_size = art::ArtMethod::Size(ptr_size); in VisitFrame()
254 auto* method_storage = allocator_->Alloc(art::Thread::Current(), method_size); in VisitFrame()
257 new_obsolete_method = new (method_storage) art::ArtMethod(); in VisitFrame()
273 art::LinearAlloc* allocator_;
275 const std::unordered_set<art::ArtMethod*>& obsoleted_methods_;
285 art::Thread* self = art::Thread::Current(); in IsModifiableClass()
286 art::ScopedObjectAccess soa(self); in IsModifiableClass()
287 art::StackHandleScope<1> hs(self); in IsModifiableClass()
288 art::ObjPtr<art::mirror::Object> obj(self->DecodeJObject(klass)); in IsModifiableClass()
292 art::Handle<art::mirror::Class> h_klass(hs.NewHandle(obj->AsClass())); in IsModifiableClass()
301 art::Thread* self = art::Thread::Current(); in GetClassRedefinitionError()
302 art::ScopedObjectAccess soa(self); in GetClassRedefinitionError()
303 art::StackHandleScope<1> hs(self); in GetClassRedefinitionError()
304 art::ObjPtr<art::mirror::Object> obj(self->DecodeJObject(klass)); in GetClassRedefinitionError()
308 art::Handle<art::mirror::Class> h_klass(hs.NewHandle(obj->AsClass())); in GetClassRedefinitionError()
312 jvmtiError Redefiner::GetClassRedefinitionError(art::Handle<art::mirror::Class> klass, in GetClassRedefinitionError()
318 if (klass->GetLockOwnerThreadId() == art::Thread::Current()->GetThreadId()) { in GetClassRedefinitionError()
345 for (jclass c : art::NonDebuggableClasses::GetNonDebuggableClasses()) { in GetClassRedefinitionError()
346 if (klass.Get() == art::Thread::Current()->DecodeJObject(c)->AsClass()) { in GetClassRedefinitionError()
356 art::MemMap Redefiner::MoveDataToMemMap(const std::string& original_location, in MoveDataToMemMap()
357 art::ArrayRef<const unsigned char> data, in MoveDataToMemMap()
359 art::MemMap map = art::MemMap::MapAnonymous( in MoveDataToMemMap()
377 const art::DexFile* redefined_dex_file, in ClassRedefinition()
379 art::ArrayRef<const unsigned char> orig_dex_file) : in ClassRedefinition()
396 art::Runtime* runtime, in RedefineClasses()
397 art::Thread* self, in RedefineClasses()
440 art::Runtime* runtime, in RedefineClassesDirect()
441 art::Thread* self, in RedefineClassesDirect()
451 art::jit::ScopedJitSuspend suspend_jit; in RedefineClassesDirect()
453 art::ScopedObjectAccess soa(self); in RedefineClassesDirect()
482 art::MemMap map = MoveDataToMemMap(original_dex_location, def.GetDexData(), error_msg_); in AddRedefinition()
490 if (map.Size() < sizeof(art::DexFile::Header)) { in AddRedefinition()
495 uint32_t checksum = reinterpret_cast<const art::DexFile::Header*>(map.Begin())->checksum_; in AddRedefinition()
496 const art::ArtDexFileLoader dex_file_loader; in AddRedefinition()
497 std::unique_ptr<const art::DexFile> dex_file(dex_file_loader.Open(name, in AddRedefinition()
517 art::ObjPtr<art::mirror::Class> Redefiner::ClassRedefinition::GetMirrorClass() { in GetMirrorClass()
521 art::ObjPtr<art::mirror::ClassLoader> Redefiner::ClassRedefinition::GetClassLoader() { in GetClassLoader()
525 art::mirror::DexCache* Redefiner::ClassRedefinition::CreateNewDexCache( in CreateNewDexCache()
526 art::Handle<art::mirror::ClassLoader> loader) { in CreateNewDexCache()
527 art::StackHandleScope<2> hs(driver_->self_); in CreateNewDexCache()
528 art::ClassLinker* cl = driver_->runtime_->GetClassLinker(); in CreateNewDexCache()
529 art::Handle<art::mirror::DexCache> cache(hs.NewHandle( in CreateNewDexCache()
530 art::ObjPtr<art::mirror::DexCache>::DownCast( in CreateNewDexCache()
531 art::GetClassRoot<art::mirror::DexCache>(cl)->AllocObject(driver_->self_)))); in CreateNewDexCache()
536 art::Handle<art::mirror::String> location(hs.NewHandle( in CreateNewDexCache()
542 art::WriterMutexLock mu(driver_->self_, *art::Locks::dex_lock_); in CreateNewDexCache()
543 art::mirror::DexCache::InitializeDexCache(driver_->self_, in CreateNewDexCache()
549 art::kRuntimePointerSize); in CreateNewDexCache()
562 art::mirror::Object* Redefiner::ClassRedefinition::AllocateOrGetOriginalDexFile() { in AllocateOrGetOriginalDexFile()
565 return art::mirror::ByteArray::AllocateAndFill( in AllocateOrGetOriginalDexFile()
572 art::ObjPtr<art::mirror::ClassExt> ext(GetMirrorClass()->GetExtData()); in AllocateOrGetOriginalDexFile()
574 art::ObjPtr<art::mirror::Object> old_original_dex_file(ext->GetOriginalDexFile()); in AllocateOrGetOriginalDexFile()
582 art::ObjPtr<art::mirror::DexCache> current_dex_cache(GetMirrorClass()->GetDexCache()); in AllocateOrGetOriginalDexFile()
593 art::LinearAlloc* allocator;
594 std::unordered_set<art::ArtMethod*> obsolete_methods;
596 explicit CallbackCtx(ObsoleteMap* map, art::LinearAlloc* alloc) in CallbackCtx()
600 void DoAllocateObsoleteMethodsCallback(art::Thread* t, void* vdata) NO_THREAD_SAFETY_ANALYSIS { in DoAllocateObsoleteMethodsCallback()
612 art::ObjPtr<art::mirror::Class> art_klass) { in FindAndAllocateObsoleteMethods()
613 art::ScopedAssertNoThreadSuspension ns("No thread suspension during thread stack walking"); in FindAndAllocateObsoleteMethods()
614 art::ObjPtr<art::mirror::ClassExt> ext = art_klass->GetExtData(); in FindAndAllocateObsoleteMethods()
616 art::ClassLinker* linker = driver_->runtime_->GetClassLinker(); in FindAndAllocateObsoleteMethods()
621 for (auto& m : art_klass->GetDeclaredMethods(art::kRuntimePointerSize)) { in FindAndAllocateObsoleteMethods()
637 art::MutexLock mu(driver_->self_, *art::Locks::thread_list_lock_); in FindAndAllocateObsoleteMethods()
638 art::ThreadList* list = art::Runtime::Current()->GetThreadList(); in FindAndAllocateObsoleteMethods()
641 art::jit::Jit* jit = art::Runtime::Current()->GetJit(); in FindAndAllocateObsoleteMethods()
654 static art::ArtMethod* FindMethod(art::Handle<art::mirror::Class> klass, in FindMethod()
656 art::Signature sig) REQUIRES_SHARED(art::Locks::mutator_lock_) { in FindMethod()
658 for (art::ArtMethod& m : klass->GetDeclaredMethodsSlice(art::kRuntimePointerSize)) { in FindMethod()
667 art::StackHandleScope<1> hs(driver_->self_); in CheckSameMethods()
668 art::Handle<art::mirror::Class> h_klass(hs.NewHandle(GetMirrorClass())); in CheckSameMethods()
672 art::ClassAccessor accessor(*dex_file_, dex_file_->GetClassDef(0)); in CheckSameMethods()
674 uint32_t num_old_method = h_klass->GetDeclaredMethodsSlice(art::kRuntimePointerSize).size(); in CheckSameMethods()
688 for (const art::ClassAccessor::Method& method : accessor.GetMethods()) { in CheckSameMethods()
690 const art::dex::MethodId& new_method_id = dex_file_->GetMethodId(method.GetIndex()); in CheckSameMethods()
692 art::Signature new_method_signature = dex_file_->GetMethodSignature(new_method_id); in CheckSameMethods()
693 art::ArtMethod* old_method = FindMethod(h_klass, new_method_name, new_method_signature); in CheckSameMethods()
708 if (new_flags != (old_method->GetAccessFlags() & art::kAccValidMethodFlags)) { in CheckSameMethods()
720 art::StackHandleScope<1> hs(driver_->self_); in CheckSameFields()
721 art::Handle<art::mirror::Class> h_klass(hs.NewHandle(GetMirrorClass())); in CheckSameFields()
723 art::ClassAccessor new_accessor(*dex_file_, dex_file_->GetClassDef(0)); in CheckSameFields()
725 const art::DexFile& old_dex_file = h_klass->GetDexFile(); in CheckSameFields()
726 art::ClassAccessor old_accessor(old_dex_file, *h_klass->GetClassDef()); in CheckSameFields()
731 for (const art::ClassAccessor::Field& new_field : new_accessor.GetFields()) { in CheckSameFields()
733 const art::dex::FieldId& new_field_id = dex_file_->GetFieldId(new_field.GetIndex()); in CheckSameFields()
746 const art::dex::FieldId& old_field_id = old_dex_file.GetFieldId(old_iter->GetIndex()); in CheckSameFields()
787 art::StackHandleScope<1> hs(driver_->self_); in CheckClass()
797 const art::dex::ClassDef& def = dex_file_->GetClassDef(0); in CheckClass()
799 art::Handle<art::mirror::Class> current_class(hs.NewHandle(GetMirrorClass())); in CheckClass()
802 if (def.GetJavaAccessFlags() != (current_class->GetAccessFlags() & art::kAccValidClassFlags)) { in CheckClass()
810 DCHECK_NE(def.class_idx_, art::dex::TypeIndex::Invalid()) << "Invalid type index"; in CheckClass()
822 if (def.superclass_idx_ != art::dex::TypeIndex::Invalid()) { in CheckClass()
834 const art::dex::TypeList* interfaces = dex_file_->GetInterfacesList(def); in CheckClass()
842 const art::dex::TypeList* current_interfaces = current_class->GetInterfaceTypeList(); in CheckClass()
848 const art::DexFile& orig_dex_file = current_class->GetDexFile(); in CheckClass()
864 art::StackHandleScope<1> hs(driver_->self_); in CheckRedefinable()
866 art::Handle<art::mirror::Class> h_klass(hs.NewHandle(GetMirrorClass())); in CheckRedefinable()
907 RedefinitionDataHolder(art::StackHandleScope<1>* hs, in RedefinitionDataHolder()
908 art::Runtime* runtime, in RedefinitionDataHolder()
909 art::Thread* self, in RedefinitionDataHolder()
911 REQUIRES_SHARED(art::Locks::mutator_lock_) : in RedefinitionDataHolder()
912 arr_(hs->NewHandle(art::mirror::ObjectArray<art::mirror::Object>::Alloc( in RedefinitionDataHolder()
914 art::GetClassRoot<art::mirror::ObjectArray<art::mirror::Object>>(runtime->GetClassLinker()), in RedefinitionDataHolder()
918 bool IsNull() const REQUIRES_SHARED(art::Locks::mutator_lock_) { in IsNull()
922 art::ObjPtr<art::mirror::ClassLoader> GetSourceClassLoader(jint klass_index) const in GetSourceClassLoader()
923 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetSourceClassLoader()
924 return art::ObjPtr<art::mirror::ClassLoader>::DownCast( in GetSourceClassLoader()
927 art::ObjPtr<art::mirror::Object> GetJavaDexFile(jint klass_index) const in GetJavaDexFile()
928 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetJavaDexFile()
931 art::ObjPtr<art::mirror::LongArray> GetNewDexFileCookie(jint klass_index) const in GetNewDexFileCookie()
932 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetNewDexFileCookie()
933 return art::ObjPtr<art::mirror::LongArray>::DownCast( in GetNewDexFileCookie()
936 art::ObjPtr<art::mirror::DexCache> GetNewDexCache(jint klass_index) const in GetNewDexCache()
937 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetNewDexCache()
938 return art::ObjPtr<art::mirror::DexCache>::DownCast(GetSlot(klass_index, kSlotNewDexCache)); in GetNewDexCache()
940 art::ObjPtr<art::mirror::Class> GetMirrorClass(jint klass_index) const in GetMirrorClass()
941 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetMirrorClass()
942 return art::ObjPtr<art::mirror::Class>::DownCast(GetSlot(klass_index, kSlotMirrorClass)); in GetMirrorClass()
945 art::ObjPtr<art::mirror::Object> GetOriginalDexFile(jint klass_index) const in GetOriginalDexFile()
946 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetOriginalDexFile()
947 return art::ObjPtr<art::mirror::Object>::DownCast(GetSlot(klass_index, kSlotOrigDexFile)); in GetOriginalDexFile()
950 art::ObjPtr<art::mirror::PointerArray> GetOldObsoleteMethods(jint klass_index) const in GetOldObsoleteMethods()
951 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetOldObsoleteMethods()
952 return art::ObjPtr<art::mirror::PointerArray>::DownCast( in GetOldObsoleteMethods()
956 art::ObjPtr<art::mirror::ObjectArray<art::mirror::DexCache>> GetOldDexCaches( in GetOldDexCaches()
957 jint klass_index) const REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetOldDexCaches()
958 return art::ObjPtr<art::mirror::ObjectArray<art::mirror::DexCache>>::DownCast( in GetOldDexCaches()
962 void SetSourceClassLoader(jint klass_index, art::ObjPtr<art::mirror::ClassLoader> loader) in SetSourceClassLoader()
963 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetSourceClassLoader()
966 void SetJavaDexFile(jint klass_index, art::ObjPtr<art::mirror::Object> dexfile) in SetJavaDexFile()
967 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetJavaDexFile()
970 void SetNewDexFileCookie(jint klass_index, art::ObjPtr<art::mirror::LongArray> cookie) in SetNewDexFileCookie()
971 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetNewDexFileCookie()
974 void SetNewDexCache(jint klass_index, art::ObjPtr<art::mirror::DexCache> cache) in SetNewDexCache()
975 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetNewDexCache()
978 void SetMirrorClass(jint klass_index, art::ObjPtr<art::mirror::Class> klass) in SetMirrorClass()
979 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetMirrorClass()
982 void SetOriginalDexFile(jint klass_index, art::ObjPtr<art::mirror::Object> bytes) in SetOriginalDexFile()
983 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetOriginalDexFile()
986 void SetOldObsoleteMethods(jint klass_index, art::ObjPtr<art::mirror::PointerArray> methods) in SetOldObsoleteMethods()
987 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetOldObsoleteMethods()
991 art::ObjPtr<art::mirror::ObjectArray<art::mirror::DexCache>> caches) in SetOldDexCaches()
992 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetOldDexCaches()
996 int32_t Length() const REQUIRES_SHARED(art::Locks::mutator_lock_) { in Length()
1001 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetRedefinitions()
1006 REQUIRES_SHARED(art::Locks::mutator_lock_) { in operator ==()
1011 REQUIRES_SHARED(art::Locks::mutator_lock_) { in operator !=()
1015 RedefinitionDataIter begin() REQUIRES_SHARED(art::Locks::mutator_lock_);
1016 RedefinitionDataIter end() REQUIRES_SHARED(art::Locks::mutator_lock_);
1019 mutable art::Handle<art::mirror::ObjectArray<art::mirror::Object>> arr_;
1022 art::ObjPtr<art::mirror::Object> GetSlot(jint klass_index, DataSlot slot) const in GetSlot()
1023 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetSlot()
1030 art::ObjPtr<art::mirror::Object> obj) REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetSlot()
1031 DCHECK(!art::Runtime::Current()->IsActiveTransaction()); in SetSlot()
1049 REQUIRES_SHARED(art::Locks::mutator_lock_) { in operator ==()
1054 REQUIRES_SHARED(art::Locks::mutator_lock_) { in operator !=()
1080 Redefiner::ClassRedefinition& GetRedefinition() REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetRedefinition()
1088 art::ObjPtr<art::mirror::ClassLoader> GetSourceClassLoader() const in GetSourceClassLoader()
1089 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetSourceClassLoader()
1092 art::ObjPtr<art::mirror::Object> GetJavaDexFile() const in GetJavaDexFile()
1093 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetJavaDexFile()
1096 art::ObjPtr<art::mirror::LongArray> GetNewDexFileCookie() const in GetNewDexFileCookie()
1097 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetNewDexFileCookie()
1100 art::ObjPtr<art::mirror::DexCache> GetNewDexCache() const in GetNewDexCache()
1101 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetNewDexCache()
1104 art::ObjPtr<art::mirror::Class> GetMirrorClass() const in GetMirrorClass()
1105 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetMirrorClass()
1108 art::ObjPtr<art::mirror::Object> GetOriginalDexFile() const in GetOriginalDexFile()
1109 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetOriginalDexFile()
1112 art::ObjPtr<art::mirror::PointerArray> GetOldObsoleteMethods() const in GetOldObsoleteMethods()
1113 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetOldObsoleteMethods()
1116 art::ObjPtr<art::mirror::ObjectArray<art::mirror::DexCache>> GetOldDexCaches() const in GetOldDexCaches()
1117 REQUIRES_SHARED(art::Locks::mutator_lock_) { in GetOldDexCaches()
1125 void SetSourceClassLoader(art::mirror::ClassLoader* loader) in SetSourceClassLoader()
1126 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetSourceClassLoader()
1129 void SetJavaDexFile(art::ObjPtr<art::mirror::Object> dexfile) in SetJavaDexFile()
1130 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetJavaDexFile()
1133 void SetNewDexFileCookie(art::ObjPtr<art::mirror::LongArray> cookie) in SetNewDexFileCookie()
1134 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetNewDexFileCookie()
1137 void SetNewDexCache(art::ObjPtr<art::mirror::DexCache> cache) in SetNewDexCache()
1138 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetNewDexCache()
1141 void SetMirrorClass(art::ObjPtr<art::mirror::Class> klass) in SetMirrorClass()
1142 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetMirrorClass()
1145 void SetOriginalDexFile(art::ObjPtr<art::mirror::Object> bytes) in SetOriginalDexFile()
1146 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetOriginalDexFile()
1149 void SetOldObsoleteMethods(art::ObjPtr<art::mirror::PointerArray> methods) in SetOldObsoleteMethods()
1150 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetOldObsoleteMethods()
1153 void SetOldDexCaches(art::ObjPtr<art::mirror::ObjectArray<art::mirror::DexCache>> caches) in SetOldDexCaches()
1154 REQUIRES_SHARED(art::Locks::mutator_lock_) { in SetOldDexCaches()
1173 art::StackHandleScope<2> hs(driver_->self_); in CheckVerification()
1176 art::verifier::FailureKind failure = in CheckVerification()
1177 art::verifier::ClassVerifier::VerifyClass(driver_->self_, in CheckVerification()
1185 art::verifier::HardFailLogMode::kLogWarning, in CheckVerification()
1186 art::Runtime::Current()->GetTargetSdkVersion(), in CheckVerification()
1189 case art::verifier::FailureKind::kNoFailure: in CheckVerification()
1190 case art::verifier::FailureKind::kSoftFailure: in CheckVerification()
1192 case art::verifier::FailureKind::kHardFailure: { in CheckVerification()
1203 art::Handle<art::mirror::ClassLoader> source_class_loader, in AllocateAndRememberNewDexFileCookie()
1204 art::Handle<art::mirror::Object> dex_file_obj, in AllocateAndRememberNewDexFileCookie()
1206 art::StackHandleScope<2> hs(driver_->self_); in AllocateAndRememberNewDexFileCookie()
1207 art::MutableHandle<art::mirror::LongArray> old_cookie( in AllocateAndRememberNewDexFileCookie()
1208 hs.NewHandle<art::mirror::LongArray>(nullptr)); in AllocateAndRememberNewDexFileCookie()
1227 art::Handle<art::mirror::LongArray> in AllocateAndRememberNewDexFileCookie()
1254 art::ScopedObjectAccessUnchecked soa(driver_->self_); in FinishRemainingAllocations()
1255 art::StackHandleScope<2> hs(driver_->self_); in FinishRemainingAllocations()
1258 art::Handle<art::mirror::ClassLoader> loader(hs.NewHandle(GetClassLoader())); in FinishRemainingAllocations()
1260 if (!art::ClassLinker::IsBootClassLoader(soa, loader.Get())) { in FinishRemainingAllocations()
1262 art::Handle<art::mirror::Object> dex_file_obj(hs.NewHandle( in FinishRemainingAllocations()
1301 if (LIKELY(!art::Dbg::IsDebuggerActive())) { in UnregisterBreakpoints()
1304 art::JDWP::JdwpState* state = art::Dbg::GetJdwpState(); in UnregisterBreakpoints()
1372 ScopedDisableConcurrentAndMovingGc(art::gc::Heap* heap, art::Thread* self) in ScopedDisableConcurrentAndMovingGc()
1385 art::gc::Heap* heap_;
1386 art::Thread* self_;
1390 art::StackHandleScope<1> hs(self_); in Run()
1415 art::ClassLinker* cl = runtime_->GetClassLinker(); in Run()
1430 art::ScopedThreadSuspension sts(self_, art::ThreadState::kNative); in Run()
1431 art::ScopedSuspendAll ssa("Final installation of redefined Classes!", /*long_suspend=*/true); in Run()
1433 art::ScopedAssertNoThreadSuspension nts("Updating runtime objects for redefinition"); in Run()
1438 art::ObjPtr<art::mirror::Class> klass = data.GetMirrorClass(); in Run()
1454 void Redefiner::ClassRedefinition::UpdateMethods(art::ObjPtr<art::mirror::Class> mclass, in UpdateMethods()
1455 const art::dex::ClassDef& class_def) { in UpdateMethods()
1456 art::ClassLinker* linker = driver_->runtime_->GetClassLinker(); in UpdateMethods()
1457 art::PointerSize image_pointer_size = linker->GetImagePointerSize(); in UpdateMethods()
1458 const art::dex::TypeId& declaring_class_id = dex_file_->GetTypeId(class_def.class_idx_); in UpdateMethods()
1459 const art::DexFile& old_dex_file = mclass->GetDexFile(); in UpdateMethods()
1461 for (art::ArtMethod& method : mclass->GetDeclaredMethods(image_pointer_size)) { in UpdateMethods()
1462 const art::dex::StringId* new_name_id = dex_file_->FindStringId(method.GetName()); in UpdateMethods()
1463 art::dex::TypeIndex method_return_idx = in UpdateMethods()
1466 std::vector<art::dex::TypeIndex> new_type_list; in UpdateMethods()
1475 const art::dex::ProtoId* proto_id = dex_file_->FindProtoId(method_return_idx, new_type_list); in UpdateMethods()
1477 const art::dex::MethodId* method_id = dex_file_->FindMethodId(declaring_class_id, in UpdateMethods()
1490 void Redefiner::ClassRedefinition::UpdateFields(art::ObjPtr<art::mirror::Class> mclass) { in UpdateFields()
1493 for (art::ArtField& field : fields_iter) { in UpdateFields()
1495 const art::dex::TypeId* new_declaring_id = in UpdateFields()
1497 const art::dex::StringId* new_name_id = dex_file_->FindStringId(field.GetName()); in UpdateFields()
1498 const art::dex::TypeId* new_type_id = dex_file_->FindTypeId(field.GetTypeDescriptor()); in UpdateFields()
1500 const art::dex::FieldId* new_field_id = in UpdateFields()
1511 art::ObjPtr<art::mirror::Class> mclass, in UpdateClass()
1512 art::ObjPtr<art::mirror::DexCache> new_dex_cache, in UpdateClass()
1513 art::ObjPtr<art::mirror::Object> original_dex_file) { in UpdateClass()
1515 const art::dex::ClassDef& class_def = dex_file_->GetClassDef(0); in UpdateClass()
1519 art::ObjPtr<art::mirror::ClassExt> ext(mclass->GetExtData()); in UpdateClass()
1542 art::jit::Jit* jit = driver_->runtime_->GetJit(); in UpdateClass()
1544 art::PointerSize image_pointer_size = in UpdateClass()
1549 for (art::ArtMethod& method : mclass->GetDeclaredMethods(image_pointer_size)) { in UpdateClass()
1561 art::ObjPtr<art::mirror::Class> klass = GetMirrorClass(); in RestoreObsoleteMethodMapsIfUnneeded()
1562 art::ObjPtr<art::mirror::ClassExt> ext = klass->GetExtData(); in RestoreObsoleteMethodMapsIfUnneeded()
1563 art::ObjPtr<art::mirror::PointerArray> methods = ext->GetObsoleteMethods(); in RestoreObsoleteMethodMapsIfUnneeded()
1564 art::ObjPtr<art::mirror::PointerArray> old_methods = cur_data->GetOldObsoleteMethods(); in RestoreObsoleteMethodMapsIfUnneeded()
1571 art::ArtMethod* expected = nullptr; in RestoreObsoleteMethodMapsIfUnneeded()
1573 expected = old_methods->GetElementPtrSize<art::ArtMethod*>(i, art::kRuntimePointerSize); in RestoreObsoleteMethodMapsIfUnneeded()
1575 if (methods->GetElementPtrSize<art::ArtMethod*>(i, art::kRuntimePointerSize) != expected) { in RestoreObsoleteMethodMapsIfUnneeded()
1590 art::StackHandleScope<2> hs(driver_->self_); in EnsureClassAllocationsFinished()
1591 art::Handle<art::mirror::Class> klass(hs.NewHandle( in EnsureClassAllocationsFinished()
1598 art::Handle<art::mirror::ClassExt> ext(hs.NewHandle(klass->EnsureExtDataPresent(driver_->self_))); in EnsureClassAllocationsFinished()
1614 driver_->self_, klass->GetDeclaredMethodsSlice(art::kRuntimePointerSize).size())) { in EnsureClassAllocationsFinished()