Home
last modified time | relevance | path

Searched refs:char_count (Results 1 – 16 of 16) sorted by relevance

/art/test/ti-agent/
Dti_utf.h110 inline void ConvertUtf16ToUtf8(const uint16_t* utf16, size_t char_count, Append&& append) { in ConvertUtf16ToUtf8() argument
123 for (size_t i = 0u; i < char_count; ++i) { in ConvertUtf16ToUtf8()
124 auto has_trail = [&]() { return i + 1u != char_count && is_trail(utf16[i + 1u]); }; in ConvertUtf16ToUtf8()
161 size_t char_count) { in ConvertUtf16ToModifiedUtf8() argument
162 if (LIKELY(byte_count == char_count)) { in ConvertUtf16ToModifiedUtf8()
164 const uint16_t *utf16_end = utf16_in + char_count; in ConvertUtf16ToModifiedUtf8()
176 /*kReplaceBadSurrogates=*/ false>(utf16_in, char_count, append); in ConvertUtf16ToModifiedUtf8()
179 inline size_t CountModifiedUtf8BytesInUtf16(const uint16_t* chars, size_t char_count) { in CountModifiedUtf8BytesInUtf16() argument
185 /*kReplaceBadSurrogates=*/ false>(chars, char_count, append); in CountModifiedUtf8BytesInUtf16()
Djni_binder.cc35 size_t char_count = ti::CountModifiedUtf8Chars(s.c_str(), s.length()); in MangleForJni() local
37 for (size_t i = 0; i < char_count; ++i) { in MangleForJni()
/art/libdexfile/dex/
Dutf_test.cc232 static size_t CountModifiedUtf8BytesInUtf16_reference(const uint16_t* chars, size_t char_count) { in CountModifiedUtf8BytesInUtf16_reference() argument
234 while (char_count--) { in CountModifiedUtf8BytesInUtf16_reference()
239 if (char_count > 0) { in CountModifiedUtf8BytesInUtf16_reference()
246 char_count--; in CountModifiedUtf8BytesInUtf16_reference()
267 size_t char_count) { in ConvertUtf16ToModifiedUtf8_reference() argument
268 while (char_count--) { in ConvertUtf16ToModifiedUtf8_reference()
277 if ((ch >= 0xd800 && ch <= 0xdbff) && (char_count > 0)) { in ConvertUtf16ToModifiedUtf8_reference()
285 char_count--; in ConvertUtf16ToModifiedUtf8_reference()
316 static void testConversions(uint16_t *buf, int char_count) { in testConversions() argument
323 byte_count_reference = CountModifiedUtf8BytesInUtf16_reference(buf, char_count); in testConversions()
[all …]
Dutf.cc125 const uint16_t* utf16_in, size_t char_count) { in ConvertUtf16ToModifiedUtf8() argument
126 if (LIKELY(byte_count == char_count)) { in ConvertUtf16ToModifiedUtf8()
128 const uint16_t *utf16_end = utf16_in + char_count; in ConvertUtf16ToModifiedUtf8()
140 /*kReplaceBadSurrogates=*/ false>(utf16_in, char_count, append); in ConvertUtf16ToModifiedUtf8()
209 size_t CountModifiedUtf8BytesInUtf16(const uint16_t* chars, size_t char_count) { in CountModifiedUtf8BytesInUtf16() argument
215 /*kReplaceBadSurrogates=*/ false>(chars, char_count, append); in CountModifiedUtf8BytesInUtf16()
239 size_t char_count = CountModifiedUtf8Chars(p); in PrintableString() local
240 for (size_t i = 0; i < char_count; ++i) { in PrintableString()
265 DCHECK_LT(i, char_count); in PrintableString()
Dutf.h79 void ConvertUtf16ToUtf8(const uint16_t* utf16, size_t char_count, Append&& append);
85 size_t CountModifiedUtf8BytesInUtf16(const uint16_t* chars, size_t char_count);
94 const uint16_t* utf16_in, size_t char_count);
100 int32_t ComputeUtf16Hash(const MemoryType* chars, size_t char_count) { in ComputeUtf16Hash() argument
106 while (char_count--) { in ComputeUtf16Hash()
Dutf-inl.h98 inline void ConvertUtf16ToUtf8(const uint16_t* utf16, size_t char_count, Append&& append) { in ConvertUtf16ToUtf8() argument
111 for (size_t i = 0u; i < char_count; ++i) { in ConvertUtf16ToUtf8()
112 auto has_trail = [&]() { return i + 1u != char_count && is_trail(utf16[i + 1u]); }; in ConvertUtf16ToUtf8()
Ddescriptors_names.cc173 size_t char_count = CountModifiedUtf8Chars(s.c_str()); in MangleForJni() local
175 for (size_t i = 0; i < char_count; ++i) { in MangleForJni()
/art/libartbase/base/
Dendian_utils.h49 inline void AppendUtf16BE(std::vector<uint8_t>& bytes, const uint16_t* chars, size_t char_count) { in AppendUtf16BE() argument
50 Append4BE(bytes, char_count); in AppendUtf16BE()
51 for (size_t i = 0; i < char_count; ++i) { in AppendUtf16BE()
58 size_t char_count) { in AppendUtf16CompressedBE() argument
59 Append4BE(bytes, char_count); in AppendUtf16CompressedBE()
60 for (size_t i = 0; i < char_count; ++i) { in AppendUtf16CompressedBE()
/art/runtime/native/
Djava_lang_StringFactory.cc60 JNIEnv* env, jclass, jbyteArray java_data, jint offset, jint char_count) { in StringFactory_newStringFromUtf16Bytes() argument
72 static_cast<uint32_t>(char_count) > (static_cast<uint32_t>(data_size - offset) >> 1)) { in StringFactory_newStringFromUtf16Bytes()
77 char_count); in StringFactory_newStringFromUtf16Bytes()
82 char_count, in StringFactory_newStringFromUtf16Bytes()
91 jint char_count, jcharArray java_data) { in StringFactory_newStringFromChars() argument
98 char_count, in StringFactory_newStringFromChars()
/art/runtime/mirror/
Dstring-alloc-inl.h265 int32_t char_count, in AllocFromUtf16ByteArray() argument
274 uint32_t byte_count = (static_cast<uint32_t>(char_count) << 1); in AllocFromUtf16ByteArray()
282 const int32_t length_with_flag = String::GetFlaggedCount(char_count, compressible); in AllocFromUtf16ByteArray()
Dstring.cc238 size_t char_count = CountModifiedUtf8Chars(utf, byte_count); in AllocFromModifiedUtf8() local
239 return AllocFromModifiedUtf8(self, char_count, utf, byte_count); in AllocFromModifiedUtf8()
Dstring.h147 int32_t char_count,
/art/runtime/entrypoints/quick/
Dquick_alloc_entrypoints.cc114 int32_t offset, int32_t char_count, mirror::CharArray* char_array, Thread* self) \
119 self, char_count, handle_array, offset, allocator_type).Ptr(); \
/art/runtime/
Ddebugger.cc310 size_t char_count = (name != nullptr) ? name->GetLength() : 0; in DdmSendThreadNotification() local
318 AppendUtf16CompressedBE(bytes, chars_compressed, char_count); in DdmSendThreadNotification()
320 AppendUtf16BE(bytes, chars, char_count); in DdmSendThreadNotification()
322 CHECK_EQ(bytes.size(), char_count*2 + sizeof(uint32_t)*2); in DdmSendThreadNotification()
/art/runtime/jni/
Djni_internal.cc1975 static jstring NewString(JNIEnv* env, const jchar* chars, jsize char_count) { in NewString() argument
1976 if (UNLIKELY(char_count < 0)) { in NewString()
1977 JavaVmExtFromEnv(env)->JniAbortF("NewString", "char_count < 0: %d", char_count); in NewString()
1980 if (UNLIKELY(chars == nullptr && char_count > 0)) { in NewString()
1985 ObjPtr<mirror::String> result = mirror::String::AllocFromUtf16(soa.Self(), char_count, chars); in NewString()
/art/runtime/interpreter/
Dunstarted_runtime.cc1435 jint char_count = shadow_frame->GetVReg(arg_offset + 1); in UnstartedStringFactoryNewStringFromChars() local
1436 DCHECK_GE(char_count, 0); in UnstartedStringFactoryNewStringFromChars()
1443 mirror::String::AllocFromCharArray(self, char_count, h_char_array, offset, allocator)); in UnstartedStringFactoryNewStringFromChars()