Home
last modified time | relevance | path

Searched refs:byte_count (Results 1 – 25 of 36) sorted by relevance

12

/art/compiler/linker/
Dbuffered_output_stream.cc32 bool BufferedOutputStream::WriteFully(const void* buffer, size_t byte_count) { in WriteFully() argument
33 if (byte_count > kBufferSize) { in WriteFully()
37 return out_->WriteFully(buffer, byte_count); in WriteFully()
39 if (used_ + byte_count > kBufferSize) { in WriteFully()
45 memcpy(&buffer_[used_], src, byte_count); in WriteFully()
46 used_ += byte_count; in WriteFully()
Dvector_output_stream.h34 bool WriteFully(const void* buffer, size_t byte_count) OVERRIDE { in WriteFully() argument
37 vector_->insert(vector_->end(), &start[0], &start[byte_count]); in WriteFully()
38 offset_ += byte_count; in WriteFully()
40 off_t new_offset = offset_ + byte_count; in WriteFully()
42 memcpy(&(*vector_)[offset_], buffer, byte_count); in WriteFully()
Derror_delaying_output_stream.h37 bool WriteFully(const void* buffer, size_t byte_count) OVERRIDE { in WriteFully() argument
39 if (!output_->WriteFully(buffer, byte_count)) { in WriteFully()
40 PLOG(ERROR) << "Failed to write " << byte_count in WriteFully()
45 output_offset_ += byte_count; in WriteFully()
Dfile_output_stream.cc28 bool FileOutputStream::WriteFully(const void* buffer, size_t byte_count) { in WriteFully() argument
29 return file_->WriteFully(buffer, byte_count); in WriteFully()
Dfile_output_stream.h32 bool WriteFully(const void* buffer, size_t byte_count) OVERRIDE;
Dbuffered_output_stream.h34 bool WriteFully(const void* buffer, size_t byte_count) OVERRIDE;
Doutput_stream.h44 virtual bool WriteFully(const void* buffer, size_t byte_count) = 0;
/art/runtime/base/unix_file/
Dfd_file.cc192 int64_t FdFile::Read(char* buf, int64_t byte_count, int64_t offset) const { in Read() argument
194 int rc = TEMP_FAILURE_RETRY(pread64(fd_, buf, byte_count, offset)); in Read()
196 int rc = TEMP_FAILURE_RETRY(pread(fd_, buf, byte_count, offset)); in Read()
218 int64_t FdFile::Write(const char* buf, int64_t byte_count, int64_t offset) { in Write() argument
221 int rc = TEMP_FAILURE_RETRY(pwrite64(fd_, buf, byte_count, offset)); in Write()
223 int rc = TEMP_FAILURE_RETRY(pwrite(fd_, buf, byte_count, offset)); in Write()
251 static bool ReadFullyGeneric(int fd, void* buffer, size_t byte_count, size_t offset) { in ReadFullyGeneric() argument
253 while (byte_count > 0) { in ReadFullyGeneric()
254 ssize_t bytes_read = TEMP_FAILURE_RETRY(read_func(fd, ptr, byte_count, offset)); in ReadFullyGeneric()
260 byte_count -= bytes_read; // Reduce the number of remaining bytes. in ReadFullyGeneric()
[all …]
Dfd_file.h93 int64_t Read(char* buf, int64_t byte_count, int64_t offset) const OVERRIDE WARN_UNUSED;
96 int64_t Write(const char* buf, int64_t byte_count, int64_t offset) OVERRIDE WARN_UNUSED;
125 bool ReadFully(void* buffer, size_t byte_count) WARN_UNUSED;
126 bool PreadFully(void* buffer, size_t byte_count, size_t offset) WARN_UNUSED;
127 bool WriteFully(const void* buffer, size_t byte_count) WARN_UNUSED;
128 bool PwriteFully(const void* buffer, size_t byte_count, size_t offset) WARN_UNUSED;
179 bool WriteFullyGeneric(const void* buffer, size_t byte_count, size_t offset);
Drandom_access_file.h45 virtual int64_t Read(char* buf, int64_t byte_count, int64_t offset) const = 0;
60 virtual int64_t Write(const char* buf, int64_t byte_count, int64_t offset) = 0;
/art/runtime/base/
Dhex_dump.cc55 size_t byte_count = byte_count_; in Dump() local
57 while (byte_count > 0) { in Dump()
71 size_t count = std::min(byte_count, 16 - gap); in Dump()
104 byte_count -= count; in Dump()
106 if (byte_count > 0) { in Dump()
Dhex_dump.h32 HexDump(const void* address, size_t byte_count, bool show_actual_addresses, const char* prefix) in HexDump() argument
33 : address_(address), byte_count_(byte_count), show_actual_addresses_(show_actual_addresses), in HexDump()
/art/runtime/gc/
Dheap-inl.h46 size_t byte_count, in AllocObjectWithAllocator() argument
50 CheckPreconditionsForAllocObject(klass, byte_count); in AllocObjectWithAllocator()
64 if (kCheckLargeObject && UNLIKELY(ShouldAllocLargeObject(klass, byte_count))) { in AllocObjectWithAllocator()
65 obj = AllocLargeObject<kInstrumented, PreFenceVisitor>(self, &klass, byte_count, in AllocObjectWithAllocator()
82 byte_count = RoundUp(byte_count, space::BumpPointerSpace::kAlignment); in AllocObjectWithAllocator()
85 if (IsTLABAllocator(allocator) && byte_count <= self->TlabSize()) { in AllocObjectWithAllocator()
86 obj = self->AllocTlab(byte_count); in AllocObjectWithAllocator()
92 bytes_allocated = byte_count; in AllocObjectWithAllocator()
98 (obj = rosalloc_space_->AllocThreadLocal(self, byte_count, &bytes_allocated)) != nullptr && in AllocObjectWithAllocator()
111 obj = TryToAllocate<kInstrumented, false>(self, allocator, byte_count, &bytes_allocated, in AllocObjectWithAllocator()
[all …]
Dallocation_listener.h42 virtual void ObjectAllocated(Thread* self, ObjPtr<mirror::Object>* obj, size_t byte_count)
Dallocation_record.cc268 size_t byte_count) { in RecordAllocation() argument
312 Put(obj->Ptr(), AllocRecord(byte_count, (*obj)->GetClass(), std::move(trace))); in RecordAllocation()
/art/test/ti-agent/
Dti_utf.h28 inline size_t CountModifiedUtf8Chars(const char* utf8, size_t byte_count) { in CountModifiedUtf8Chars() argument
29 DCHECK_LE(byte_count, strlen(utf8)); in CountModifiedUtf8Chars()
31 const char* end = utf8 + byte_count; in CountModifiedUtf8Chars()
108 size_t byte_count, in ConvertUtf16ToModifiedUtf8() argument
111 if (LIKELY(byte_count == char_count)) { in ConvertUtf16ToModifiedUtf8()
/art/runtime/native/
Djava_lang_StringFactory.cc33 jint high, jint offset, jint byte_count) { in StringFactory_newStringFromBytes() argument
42 if ((offset | byte_count) < 0 || byte_count > data_size - offset) { in StringFactory_newStringFromBytes()
45 offset, byte_count); in StringFactory_newStringFromBytes()
50 byte_count, in StringFactory_newStringFromBytes()
/art/runtime/
Dmem_map.h66 size_t byte_count,
77 static MemMap* MapDummy(const char* name, uint8_t* addr, size_t byte_count);
83 static MemMap* MapFile(size_t byte_count, in MapFile() argument
92 byte_count, in MapFile()
112 size_t byte_count,
Dutf.cc46 size_t CountModifiedUtf8Chars(const char* utf8, size_t byte_count) { in CountModifiedUtf8Chars() argument
47 DCHECK_LE(byte_count, strlen(utf8)); in CountModifiedUtf8Chars()
49 const char* end = utf8 + byte_count; in CountModifiedUtf8Chars()
120 void ConvertUtf16ToModifiedUtf8(char* utf8_out, size_t byte_count, in ConvertUtf16ToModifiedUtf8() argument
122 if (LIKELY(byte_count == char_count)) { in ConvertUtf16ToModifiedUtf8()
Dutf.h37 size_t CountModifiedUtf8Chars(const char* utf8, size_t byte_count);
71 void ConvertUtf16ToModifiedUtf8(char* utf8_out, size_t byte_count,
Dmem_map.cc224 static bool CheckMapRequest(uint8_t* expected_ptr, void* actual_ptr, size_t byte_count, in CheckMapRequest() argument
235 uintptr_t limit = expected + byte_count; in CheckMapRequest()
242 int result = munmap(actual_ptr, byte_count); in CheckMapRequest()
244 PLOG(WARNING) << StringPrintf("munmap(%p, %zd) failed", actual_ptr, byte_count); in CheckMapRequest()
291 size_t byte_count, in MapAnonymous() argument
301 if (byte_count == 0) { in MapAnonymous()
304 size_t page_aligned_byte_count = RoundUp(byte_count, kPageSize); in MapAnonymous()
312 DCHECK(ContainedWithinExistingMap(expected_ptr, byte_count, error_msg)) << *error_msg; in MapAnonymous()
383 return new MemMap(name, reinterpret_cast<uint8_t*>(actual), byte_count, actual, in MapAnonymous()
387 MemMap* MemMap::MapDummy(const char* name, uint8_t* addr, size_t byte_count) { in MapDummy() argument
[all …]
Dutils.cc271 std::string PrettySize(int64_t byte_count) { in PrettySize() argument
283 if (byte_count < 0) { in PrettySize()
285 byte_count = -byte_count; in PrettySize()
289 if (byte_count >= kUnitThresholds[i]) { in PrettySize()
294 negative_str, byte_count / kBytesPerUnit[i], kUnitStrings[i]); in PrettySize()
/art/runtime/entrypoints/quick/
Dquick_alloc_entrypoints.cc44 size_t byte_count = klass->GetObjectSize(); in artAllocObjectFromCode() local
45 byte_count = RoundUp(byte_count, gc::space::BumpPointerSpace::kAlignment); in artAllocObjectFromCode()
47 if (LIKELY(byte_count < self->TlabSize())) { in artAllocObjectFromCode()
48 obj = self->AllocTlab(byte_count); in artAllocObjectFromCode()
93 mirror::ByteArray* byte_array, int32_t high, int32_t offset, int32_t byte_count, \
99 return mirror::String::AllocFromByteArray<instrumented_bool>(self, byte_count, handle_array, \
/art/runtime/mirror/
Dstring.cc198 size_t byte_count = strlen(utf); in AllocFromModifiedUtf8() local
199 size_t char_count = CountModifiedUtf8Chars(utf, byte_count); in AllocFromModifiedUtf8()
200 return AllocFromModifiedUtf8(self, char_count, utf, byte_count); in AllocFromModifiedUtf8()
318 size_t byte_count = GetUtfLength(); in ToModifiedUtf8() local
319 std::string result(byte_count, static_cast<char>(0)); in ToModifiedUtf8()
321 for (size_t i = 0; i < byte_count; ++i) { in ToModifiedUtf8()
326 ConvertUtf16ToModifiedUtf8(&result[0], byte_count, chars, GetLength()); in ToModifiedUtf8()
/art/runtime/jdwp/
Djdwp_priv.h83 void ConsumeBytes(size_t byte_count);

12