diff options
| author | 2017-04-04 18:54:04 +0000 | |
|---|---|---|
| committer | 2017-04-04 18:54:04 +0000 | |
| commit | f6e11e9e218e5e70463b5b3a94c89309936601d7 (patch) | |
| tree | 17a9787015f0ed75ff7336b2ca2e26d84510cacf | |
| parent | 04d66f1add623476b9fa7d2529a179efb2029133 (diff) | |
| parent | d66def32a2d7ee5e7c5225dce52b980b63bce91c (diff) | |
Merge "ART: Fix preloaded dex cache expectations"
| -rw-r--r-- | runtime/native/dalvik_system_VMRuntime.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/runtime/native/dalvik_system_VMRuntime.cc b/runtime/native/dalvik_system_VMRuntime.cc index 6ca951fd53..11f850524d 100644 --- a/runtime/native/dalvik_system_VMRuntime.cc +++ b/runtime/native/dalvik_system_VMRuntime.cc @@ -451,8 +451,12 @@ static void PreloadDexCachesStatsFilled(DexCacheStats* filled) Thread* const self = Thread::Current(); for (const DexFile* dex_file : class_linker->GetBootClassPath()) { CHECK(dex_file != nullptr); + // In fallback mode, not all boot classpath components might be registered, yet. + if (!class_linker->IsDexFileRegistered(self, *dex_file)) { + continue; + } ObjPtr<mirror::DexCache> const dex_cache = class_linker->FindDexCache(self, *dex_file); - CHECK(dex_cache != nullptr); // Boot class path dex caches are never unloaded. + DCHECK(dex_cache != nullptr); // Boot class path dex caches are never unloaded. for (size_t j = 0; j < dex_cache->NumStrings(); j++) { ObjPtr<mirror::String> string = dex_cache->GetResolvedString(dex::StringIndex(j)); if (string != nullptr) { |