Lines Matching refs:mirror
32 inline mirror::Class* ClassLinker::FindSystemClass(Thread* self, const char* descriptor) { in FindSystemClass()
33 return FindClass(self, descriptor, NullHandle<mirror::ClassLoader>()); in FindSystemClass()
36 inline mirror::Class* ClassLinker::FindArrayClass(Thread* self, mirror::Class** element_class) { in FindArrayClass()
39 mirror::Class* array_class = find_array_class_cache_[i].Read(); in FindArrayClass()
49 Handle<mirror::ClassLoader> class_loader(hs.NewHandle((*element_class)->GetClassLoader())); in FindArrayClass()
50 HandleWrapper<mirror::Class> h_element_class(hs.NewHandleWrapper(element_class)); in FindArrayClass()
51 mirror::Class* array_class = FindClass(self, descriptor.c_str(), class_loader); in FindArrayClass()
54 find_array_class_cache_[victim_index] = GcRoot<mirror::Class>(array_class); in FindArrayClass()
59 inline mirror::String* ClassLinker::ResolveString(uint32_t string_idx, in ResolveString()
60 mirror::ArtMethod* referrer) { in ResolveString()
61 mirror::Class* declaring_class = referrer->GetDeclaringClass(); in ResolveString()
62 mirror::String* resolved_string = declaring_class->GetDexCacheStrings()->Get(string_idx); in ResolveString()
65 Handle<mirror::DexCache> dex_cache(hs.NewHandle(declaring_class->GetDexCache())); in ResolveString()
75 inline mirror::Class* ClassLinker::ResolveType(uint16_t type_idx, in ResolveType()
76 mirror::ArtMethod* referrer) { in ResolveType()
77 mirror::Class* resolved_type = referrer->GetDexCacheResolvedType(type_idx); in ResolveType()
79 mirror::Class* declaring_class = referrer->GetDeclaringClass(); in ResolveType()
81 Handle<mirror::DexCache> dex_cache(hs.NewHandle(declaring_class->GetDexCache())); in ResolveType()
82 Handle<mirror::ClassLoader> class_loader(hs.NewHandle(declaring_class->GetClassLoader())); in ResolveType()
91 inline mirror::Class* ClassLinker::ResolveType(uint16_t type_idx, mirror::ArtField* referrer) { in ResolveType()
92 mirror::Class* declaring_class = referrer->GetDeclaringClass(); in ResolveType()
93 mirror::DexCache* dex_cache_ptr = declaring_class->GetDexCache(); in ResolveType()
94 mirror::Class* resolved_type = dex_cache_ptr->GetResolvedType(type_idx); in ResolveType()
97 Handle<mirror::DexCache> dex_cache(hs.NewHandle(dex_cache_ptr)); in ResolveType()
98 Handle<mirror::ClassLoader> class_loader(hs.NewHandle(declaring_class->GetClassLoader())); in ResolveType()
107 inline mirror::ArtMethod* ClassLinker::GetResolvedMethod(uint32_t method_idx, in GetResolvedMethod()
108 mirror::ArtMethod* referrer, in GetResolvedMethod()
110 mirror::ArtMethod* resolved_method = referrer->GetDexCacheResolvedMethod(method_idx); in GetResolvedMethod()
117 inline mirror::ArtMethod* ClassLinker::ResolveMethod(Thread* self, uint32_t method_idx, in ResolveMethod()
118 mirror::ArtMethod** referrer, in ResolveMethod()
120 mirror::ArtMethod* resolved_method = GetResolvedMethod(method_idx, *referrer, type); in ResolveMethod()
124 mirror::Class* declaring_class = (*referrer)->GetDeclaringClass(); in ResolveMethod()
126 Handle<mirror::DexCache> h_dex_cache(hs.NewHandle(declaring_class->GetDexCache())); in ResolveMethod()
127 Handle<mirror::ClassLoader> h_class_loader(hs.NewHandle(declaring_class->GetClassLoader())); in ResolveMethod()
128 HandleWrapper<mirror::ArtMethod> h_referrer(hs.NewHandleWrapper(referrer)); in ResolveMethod()
137 inline mirror::ArtField* ClassLinker::GetResolvedField(uint32_t field_idx, in GetResolvedField()
138 mirror::Class* field_declaring_class) { in GetResolvedField()
142 inline mirror::ArtField* ClassLinker::ResolveField(uint32_t field_idx, mirror::ArtMethod* referrer, in ResolveField()
144 mirror::Class* declaring_class = referrer->GetDeclaringClass(); in ResolveField()
145 mirror::ArtField* resolved_field = GetResolvedField(field_idx, declaring_class); in ResolveField()
148 Handle<mirror::DexCache> dex_cache(hs.NewHandle(declaring_class->GetDexCache())); in ResolveField()
149 Handle<mirror::ClassLoader> class_loader(hs.NewHandle(declaring_class->GetClassLoader())); in ResolveField()
159 inline mirror::ObjectArray<T>* ClassLinker::AllocObjectArray(Thread* self, size_t length) { in AllocObjectArray()
160 return mirror::ObjectArray<T>::Alloc(self, GetClassRoot(kObjectArrayClass), length); in AllocObjectArray()
163 inline mirror::ObjectArray<mirror::Class>* ClassLinker::AllocClassArray(Thread* self, in AllocClassArray()
165 return mirror::ObjectArray<mirror::Class>::Alloc(self, GetClassRoot(kClassArrayClass), length); in AllocClassArray()
168 inline mirror::ObjectArray<mirror::String>* ClassLinker::AllocStringArray(Thread* self, in AllocStringArray()
170 return mirror::ObjectArray<mirror::String>::Alloc(self, GetClassRoot(kJavaLangStringArrayClass), in AllocStringArray()
174 inline mirror::ObjectArray<mirror::ArtMethod>* ClassLinker::AllocArtMethodArray(Thread* self, in AllocArtMethodArray()
176 return mirror::ObjectArray<mirror::ArtMethod>::Alloc(self, in AllocArtMethodArray()
180 inline mirror::IfTable* ClassLinker::AllocIfTable(Thread* self, size_t ifcount) { in AllocIfTable()
181 return down_cast<mirror::IfTable*>( in AllocIfTable()
182 mirror::IfTable::Alloc(self, GetClassRoot(kObjectArrayClass), in AllocIfTable()
183 ifcount * mirror::IfTable::kMax)); in AllocIfTable()
186 inline mirror::ObjectArray<mirror::ArtField>* ClassLinker::AllocArtFieldArray(Thread* self, in AllocArtFieldArray()
192 return mirror::ObjectArray<mirror::ArtField>::Alloc( in AllocArtFieldArray()
197 inline mirror::Class* ClassLinker::GetClassRoot(ClassRoot class_root) in GetClassRoot()
200 mirror::ObjectArray<mirror::Class>* class_roots = class_roots_.Read(); in GetClassRoot()
201 mirror::Class* klass = class_roots->Get(class_root); in GetClassRoot()
206 inline mirror::DexCache* ClassLinker::GetDexCache(size_t idx) { in GetDexCache()