Change FieldHelper to use a handle.
Fixed compaction bugs related to FieldHelper::GetType in:
artSet32InstanceFromCode
SetFieldValueImpl
CheckReceiver
Field_set
interpreter::DoFieldPut
MethodVerifier::VerifyISGet
MethodVerifier::VerifyISPut
MethodVerifier::VerifyIGetQuick
Bug: 13077697
Change-Id: I7de9ded2893b5568d43e4daa86fd135bf5508b72
diff --git a/compiler/driver/compiler_driver-inl.h b/compiler/driver/compiler_driver-inl.h
index 45abfcc..324f717 100644
--- a/compiler/driver/compiler_driver-inl.h
+++ b/compiler/driver/compiler_driver-inl.h
@@ -135,8 +135,10 @@
} else {
// Search dex file for localized ssb index, may fail if field's class is a parent
// of the class mentioned in the dex file and there is no dex cache entry.
+ StackHandleScope<1> hs(Thread::Current());
const DexFile::StringId* string_id =
- dex_file->FindStringId(FieldHelper(resolved_field).GetDeclaringClassDescriptor());
+ dex_file->FindStringId(
+ FieldHelper(hs.NewHandle(resolved_field)).GetDeclaringClassDescriptor());
if (string_id != nullptr) {
const DexFile::TypeId* type_id =
dex_file->FindTypeId(dex_file->GetIndexForStringId(*string_id));