diff options
author | 2025-02-04 10:26:33 +0000 | |
---|---|---|
committer | 2025-02-07 07:06:12 -0800 | |
commit | 08f1b58976bae5514a0d6877b4e8f68ff15bcafb (patch) | |
tree | cda31472d1a3367f730fa77a06c876c35a2ce250 /runtime/class_linker.cc | |
parent | 95cebecfa36d6275ae078b649aae3d6ed7622716 (diff) |
Remove cdex support from `ArtMethod`...
... and a few other places in `runtime/`.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Bug: 325430813
Change-Id: Ied837bffed78b1fe4c4d381772b8c1933b76f6c0
Diffstat (limited to 'runtime/class_linker.cc')
-rw-r--r-- | runtime/class_linker.cc | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/runtime/class_linker.cc b/runtime/class_linker.cc index 57eb72dea5..c2c2e2c928 100644 --- a/runtime/class_linker.cc +++ b/runtime/class_linker.cc @@ -2278,6 +2278,10 @@ bool ClassLinker::AddImageSpace(gc::space::ImageSpace* space, }, space->Begin(), image_pointer_size_); } + for (auto dex_cache : dex_caches.Iterate<mirror::DexCache>()) { + CHECK(!dex_cache->GetDexFile()->IsCompactDexFile()); + } + ScopedTrace trace("AppImage:UpdateCodeItemAndNterp"); bool can_use_nterp = interpreter::CanRuntimeUseNterp(); uint16_t hotness_threshold = runtime->GetJITOptions()->GetWarmupThreshold(); @@ -2287,7 +2291,7 @@ bool ClassLinker::AddImageSpace(gc::space::ImageSpace* space, if (method.HasCodeItem()) { const dex::CodeItem* code_item = method.GetDexFile()->GetCodeItem( reinterpret_cast32<uint32_t>(method.GetDataPtrSize(image_pointer_size_))); - method.SetCodeItem(code_item, method.GetDexFile()->IsCompactDexFile()); + method.SetCodeItem(code_item); // The hotness counter may have changed since we compiled the image, so // reset it with the runtime value. method.ResetCounter(hotness_threshold); @@ -4025,7 +4029,7 @@ void ClassLinker::LoadMethod(const DexFile& dex_file, if (Runtime::Current()->IsAotCompiler()) { dst->SetDataPtrSize(reinterpret_cast32<void*>(code_item_offset), image_pointer_size_); } else { - dst->SetCodeItem(dex_file.GetCodeItem(code_item_offset), dex_file.IsCompactDexFile()); + dst->SetCodeItem(dex_file.GetCodeItem(code_item_offset)); } } @@ -4081,6 +4085,7 @@ void ClassLinker::LoadClass(Thread* self, const DexFile& dex_file, const dex::ClassDef& dex_class_def, Handle<mirror::Class> klass) { + CHECK(!dex_file.IsCompactDexFile()); ClassAccessor accessor(dex_file, dex_class_def, /* parse_hiddenapi_class_data= */ klass->IsBootStrapClassLoaded()); @@ -5200,8 +5205,7 @@ void ClassLinker::ResolveMethodExceptionHandlerTypes(ArtMethod* method) { CHECK(method->GetDexFile()->IsInDataSection(handlers_ptr)) << method->PrettyMethod() << "@" << method->GetDexFile()->GetLocation() - << "@" << reinterpret_cast<const void*>(handlers_ptr) - << " is_compact_dex=" << method->GetDexFile()->IsCompactDexFile(); + << "@" << reinterpret_cast<const void*>(handlers_ptr); uint32_t handlers_size = DecodeUnsignedLeb128(&handlers_ptr); for (uint32_t idx = 0; idx < handlers_size; idx++) { |