Home
last modified time | relevance | path

Searched refs:string_idx (Results 1 – 24 of 24) sorted by relevance

/art/runtime/mirror/
Ddex_cache-inl.h79 inline uint32_t DexCache::StringSlotIndex(dex::StringIndex string_idx) { in StringSlotIndex() argument
80 DCHECK_LT(string_idx.index_, GetDexFile()->NumStringIds()); in StringSlotIndex()
81 const uint32_t slot_idx = string_idx.index_ % kDexCacheStringCacheSize; in StringSlotIndex()
86 inline String* DexCache::GetResolvedString(dex::StringIndex string_idx) { in GetResolvedString() argument
93 DCHECK_LT(string_idx.index_, num_preresolved_strings); in GetResolvedString()
95 mirror::String* string = preresolved_strings[string_idx.index_].Read(); in GetResolvedString()
101 return GetStrings()[StringSlotIndex(string_idx)].load( in GetResolvedString()
102 std::memory_order_relaxed).GetObjectForIndex(string_idx.index_); in GetResolvedString()
105 inline void DexCache::SetResolvedString(dex::StringIndex string_idx, ObjPtr<String> resolved) { in SetResolvedString() argument
107 GetStrings()[StringSlotIndex(string_idx)].store( in SetResolvedString()
[all …]
Ddex_cache.h274 String* GetResolvedString(dex::StringIndex string_idx) ALWAYS_INLINE
277 void SetResolvedString(dex::StringIndex string_idx, ObjPtr<mirror::String> resolved) ALWAYS_INLINE
280 void SetPreResolvedString(dex::StringIndex string_idx,
290 void ClearString(dex::StringIndex string_idx) REQUIRES_SHARED(Locks::mutator_lock_);
470 uint32_t StringSlotIndex(dex::StringIndex string_idx) REQUIRES_SHARED(Locks::mutator_lock_);
/art/libdexfile/dex/
Ddex_instruction.cc204 uint32_t string_idx = VRegB_21c(); in DumpString() local
205 if (string_idx < file->NumStringIds()) { in DumpString()
209 PrintableString(file->StringDataByIdx(dex::StringIndex(string_idx))).c_str(), in DumpString()
210 string_idx); in DumpString()
214 string_idx, in DumpString()
215 string_idx); in DumpString()
346 uint32_t string_idx = VRegB_31c(); in DumpString() local
348 if (string_idx < file->NumStringIds()) { in DumpString()
353 PrintableString(file->StringDataByIdx(dex::StringIndex(string_idx))).c_str(), in DumpString()
354 string_idx); in DumpString()
[all …]
Dtest_dex_file_builder.h105 uint32_t string_idx = 0u; in Build() local
107 entry.second.idx = string_idx; in Build()
108 string_idx += 1u; in Build()
Ddex_file.cc348 const TypeId* DexFile::FindTypeId(dex::StringIndex string_idx) const { in FindTypeId()
354 if (string_idx > type_id.descriptor_idx_) { in FindTypeId()
356 } else if (string_idx < type_id.descriptor_idx_) { in FindTypeId()
Ddex_file_verifier.cc665 uint32_t string_idx = method_id.name_idx_.index_; in CheckClassDataItemMethod() local
666 if (!CheckIndex(string_idx, header_->string_ids_size_, "method flags verification")) { in CheckClassDataItemMethod()
669 if (UNLIKELY(string_idx < angle_bracket_end_index_) && in CheckClassDataItemMethod()
670 string_idx >= angle_bracket_start_index_) { in CheckClassDataItemMethod()
671 if (string_idx == angle_clinit_angle_index_) { in CheckClassDataItemMethod()
673 } else if (string_idx == angle_init_angle_index_) { in CheckClassDataItemMethod()
3056 dex::StringIndex string_idx) { in GetStringOrError() argument
3058 if (header->string_ids_size_ <= string_idx.index_) { in GetStringOrError()
3063 reinterpret_cast<const dex::StringId*>(begin + header->string_ids_off_) + string_idx.index_; in GetStringOrError()
Ddex_file.h305 const dex::TypeId* FindTypeId(dex::StringIndex string_idx) const;
/art/runtime/
Dclass_linker-inl.h66 inline ObjPtr<mirror::String> ClassLinker::ResolveString(dex::StringIndex string_idx, in ResolveString() argument
73 referrer->GetDexCache<kWithoutReadBarrier>()->GetResolvedString(string_idx); in ResolveString()
75 resolved = DoResolveString(string_idx, referrer->GetDexCache()); in ResolveString()
80 inline ObjPtr<mirror::String> ClassLinker::ResolveString(dex::StringIndex string_idx, in ResolveString() argument
87 referrer->GetDexCache<kWithoutReadBarrier>()->GetResolvedString(string_idx); in ResolveString()
89 resolved = DoResolveString(string_idx, referrer->GetDexCache()); in ResolveString()
94 inline ObjPtr<mirror::String> ClassLinker::ResolveString(dex::StringIndex string_idx, in ResolveString() argument
98 ObjPtr<mirror::String> resolved = dex_cache->GetResolvedString(string_idx); in ResolveString()
100 resolved = DoResolveString(string_idx, dex_cache); in ResolveString()
105 inline ObjPtr<mirror::String> ClassLinker::LookupString(dex::StringIndex string_idx, in LookupString() argument
[all …]
Dtransaction_test.cc502 dex::StringIndex string_idx = dex_file->GetIndexForStringId(*string_id); in TEST_F() local
503 ASSERT_TRUE(string_idx.IsValid()); in TEST_F()
505 EXPECT_TRUE(class_linker_->LookupString(string_idx, h_dex_cache.Get()) == nullptr); in TEST_F()
506 EXPECT_TRUE(h_dex_cache->GetResolvedString(string_idx) == nullptr); in TEST_F()
515 class_linker_->LookupString(string_idx, h_dex_cache.Get()); in TEST_F()
518 EXPECT_OBJ_PTR_EQ(s, h_dex_cache->GetResolvedString(string_idx)); in TEST_F()
522 EXPECT_TRUE(class_linker_->LookupString(string_idx, h_dex_cache.Get()) == nullptr); in TEST_F()
523 EXPECT_TRUE(h_dex_cache->GetResolvedString(string_idx) == nullptr); in TEST_F()
Dtransaction.cc231 dex::StringIndex string_idx) { in RecordResolveString() argument
233 DCHECK_LT(string_idx.index_, dex_cache->GetDexFile()->NumStringIds()); in RecordResolveString()
235 resolve_string_logs_.emplace_back(dex_cache, string_idx); in RecordResolveString()
594 dex::StringIndex string_idx) in ResolveStringLog() argument
596 string_idx_(string_idx) { in ResolveStringLog()
Dtransaction.h125 void RecordResolveString(ObjPtr<mirror::DexCache> dex_cache, dex::StringIndex string_idx)
257 ResolveStringLog(ObjPtr<mirror::DexCache> dex_cache, dex::StringIndex string_idx);
Dclass_linker.h225 ObjPtr<mirror::String> ResolveString(dex::StringIndex string_idx,
228 ObjPtr<mirror::String> ResolveString(dex::StringIndex string_idx,
234 ObjPtr<mirror::String> ResolveString(dex::StringIndex string_idx,
240 ObjPtr<mirror::String> LookupString(dex::StringIndex string_idx,
936 ObjPtr<mirror::String> DoResolveString(dex::StringIndex string_idx,
939 ObjPtr<mirror::String> DoResolveString(dex::StringIndex string_idx,
944 ObjPtr<mirror::String> DoLookupString(dex::StringIndex string_idx,
Druntime.h537 void RecordResolveString(ObjPtr<mirror::DexCache> dex_cache, dex::StringIndex string_idx) const
Druntime.cc2505 dex::StringIndex string_idx) const { in RecordResolveString()
2508 GetTransaction()->RecordResolveString(dex_cache, string_idx); in RecordResolveString()
Dclass_linker.cc8393 ObjPtr<mirror::String> ClassLinker::DoResolveString(dex::StringIndex string_idx, in DoResolveString() argument
8397 return DoResolveString(string_idx, h_dex_cache); in DoResolveString()
8400 ObjPtr<mirror::String> ClassLinker::DoResolveString(dex::StringIndex string_idx, in DoResolveString() argument
8404 const char* utf8_data = dex_file.StringDataAndUtf16LengthByIdx(string_idx, &utf16_length); in DoResolveString()
8407 dex_cache->SetResolvedString(string_idx, string); in DoResolveString()
8412 ObjPtr<mirror::String> ClassLinker::DoLookupString(dex::StringIndex string_idx, in DoLookupString() argument
8417 const char* utf8_data = dex_file.StringDataAndUtf16LengthByIdx(string_idx, &utf16_length); in DoLookupString()
8421 dex_cache->SetResolvedString(string_idx, string); in DoLookupString()
/art/cmdline/
Dtoken_range.h276 size_t string_idx = 0; in MatchSubstrings() local
283 size_t wildcard_length = string_idx - wildcard_idx; in MatchSubstrings()
296 wildcard_idx = string_idx; in MatchSubstrings()
304 } else if (next_token_idx != string_idx && wildcard_idx == std::string::npos) { in MatchSubstrings()
312 string_idx += tok.size(); in MatchSubstrings()
315 size_t remaining = string.size() - string_idx; in MatchSubstrings()
325 string_idx += remaining; in MatchSubstrings()
/art/runtime/entrypoints/quick/
Dquick_dexcache_entrypoints.cc96 dex::StringIndex string_idx, in StoreStringInBss() argument
104 string_idx.index_, in StoreStringInBss()
205 extern "C" mirror::String* artResolveStringFromCode(int32_t string_idx, Thread* self) in artResolveStringFromCode() argument
212 Runtime::Current()->GetClassLinker()->ResolveString(dex::StringIndex(string_idx), caller); in artResolveStringFromCode()
214 StoreStringInBss(caller_and_outer.outer_method, dex::StringIndex(string_idx), result); in artResolveStringFromCode()
/art/tools/dexanalyze/
Ddexanalyze_strings.cc92 std::string GetString(uint32_t string_idx) const { in GetString()
93 const size_t offset = string_offsets_[string_idx]; in GetString()
108 ALWAYS_INLINE bool Equal(uint32_t string_idx, const uint8_t* data, size_t len) const { in Equal() argument
109 const size_t offset = string_offsets_[string_idx]; in Equal()
162 std::string GetString(uint32_t string_idx) const { in GetString()
163 const size_t offset = string_offsets_[string_idx]; in GetString()
169 ALWAYS_INLINE bool Equal(uint32_t string_idx, const uint8_t* data, size_t len) const { in Equal() argument
170 const size_t offset = string_offsets_[string_idx]; in Equal()
/art/runtime/utils/
Ddex_cache_arrays_layout-inl.h111 inline size_t DexCacheArraysLayout::StringOffset(uint32_t string_idx) const { in StringOffset() argument
112 uint32_t string_hash = string_idx % mirror::DexCache::kDexCacheStringCacheSize; in StringOffset()
Ddex_cache_arrays_layout.h88 size_t StringOffset(uint32_t string_idx) const;
/art/runtime/native/
Ddalvik_system_VMRuntime.cc376 ObjPtr<mirror::DexCache> dex_cache, dex::StringIndex string_idx, StringTable& strings) in PreloadDexCachesResolveString() argument
378 uint32_t slot_idx = dex_cache->StringSlotIndex(string_idx); in PreloadDexCachesResolveString()
384 const char* utf8 = dex_file->StringDataByIdx(string_idx); in PreloadDexCachesResolveString()
390 dex_cache->SetResolvedString(string_idx, string); in PreloadDexCachesResolveString()
/art/runtime/interpreter/
Dinterpreter_common.h402 dex::StringIndex string_idx) in ResolveString() argument
416 Runtime::Current()->GetClassLinker()->ResolveString(string_idx, method); in ResolveString()
/art/dexdump/
Ddexdump.cc1753 dex::StringIndex string_idx = static_cast<dex::StringIndex>(it.GetJavaValue().i); in dumpCallSite() local
1754 value = pDexFile->StringDataByIdx(string_idx); in dumpCallSite()
/art/dex2oat/linker/
Dimage_writer.cc1737 dex::StringIndex string_idx(i); in PreloadDexCache() local
1738 uint32_t slot_idx = dex_cache->StringSlotIndex(string_idx); in PreloadDexCache()
1744 string = class_linker->LookupString(string_idx, dex_cache); in PreloadDexCache()
1745 DCHECK(string == nullptr || dex_cache->GetResolvedString(string_idx) == string); in PreloadDexCache()