From 673ed3d8aedc5462a47ded827c99f35d46525457 Mon Sep 17 00:00:00 2001 From: Mathieu Chartier Date: Fri, 28 Aug 2015 14:56:43 -0700 Subject: Revert "Revert "Change dex caches to be weak roots"" This reverts commit 81a9087f0df0518c39405b7d18ba5858a6d8b77b. Boot.oat creation time goes from 4.7s to 4.9s on host due to extra locking. Will try to improve this in another CL. Bug: 23602225 Bug: 22720414 Change-Id: I7e25b75cfb63faa196c7b0f60e46cce50bf12021 --- compiler/dex/mir_method_info.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'compiler/dex/mir_method_info.cc') diff --git a/compiler/dex/mir_method_info.cc b/compiler/dex/mir_method_info.cc index be913fe634..31c3808197 100644 --- a/compiler/dex/mir_method_info.cc +++ b/compiler/dex/mir_method_info.cc @@ -105,7 +105,8 @@ void MirMethodLoweringInfo::Resolve(CompilerDriver* compiler_driver, // Don't devirt if we are in a different dex file since we can't have direct invokes in // another dex file unless we always put a direct / patch pointer. devirt_target = nullptr; - current_dex_cache.Assign(runtime->GetClassLinker()->FindDexCache(*it->target_dex_file_)); + current_dex_cache.Assign(runtime->GetClassLinker()->FindDexCache( + soa.Self(), *it->target_dex_file_)); CHECK(current_dex_cache.Get() != nullptr); DexCompilationUnit cu( mUnit->GetCompilationUnit(), mUnit->GetClassLoader(), mUnit->GetClassLinker(), -- cgit v1.2.3-59-g8ed1b