diff options
author | Ian Rogers <irogers@google.com> | 2014-12-02 16:55:46 -0800 |
---|---|---|
committer | Ian Rogers <irogers@google.com> | 2014-12-02 16:55:46 -0800 |
commit | 00f1527007381a0cbf1a2b36b956cb3ddac906cb (patch) | |
tree | 23ada8c25751de12e3f4229f18885667897d05c2 /runtime/entrypoints | |
parent | 384f729a465d0ab3a76faa7ec8fa05ced82b4a85 (diff) | |
download | art-00f1527007381a0cbf1a2b36b956cb3ddac906cb.zip art-00f1527007381a0cbf1a2b36b956cb3ddac906cb.tar.gz art-00f1527007381a0cbf1a2b36b956cb3ddac906cb.tar.bz2 |
Fix artQuickResolutionTrampoline.
Mistakenly updating dex method index of the non-receiver method.
Change-Id: I42296e344a53e001bf37414852cd9f23f629ca40
Diffstat (limited to 'runtime/entrypoints')
-rw-r--r-- | runtime/entrypoints/quick/quick_trampoline_entrypoints.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/runtime/entrypoints/quick/quick_trampoline_entrypoints.cc b/runtime/entrypoints/quick/quick_trampoline_entrypoints.cc index a176a87..cb81629 100644 --- a/runtime/entrypoints/quick/quick_trampoline_entrypoints.cc +++ b/runtime/entrypoints/quick/quick_trampoline_entrypoints.cc @@ -812,7 +812,10 @@ extern "C" const void* artQuickResolutionTrampoline(mirror::ArtMethod* called, // We came here because of sharpening. Ensure the dex cache is up-to-date on the method index // of the sharpened method avoiding dirtying the dex cache if possible. - uint32_t update_dex_cache_method_index = called_method.dex_method_index; + // Note, called_method.dex_method_index references the dex method before the + // FindVirtualMethodFor... This is ok for FindDexMethodIndexInOtherDexFile that only cares + // about the name and signature. + uint32_t update_dex_cache_method_index = called->GetDexMethodIndex(); if (!called->HasSameDexCacheResolvedMethods(caller)) { // Calling from one dex file to another, need to compute the method index appropriate to // the caller's dex file. Since we get here only if the original called was a runtime |