Lines Matching refs:body
230 String8 timestamp, body; in dump() local
237 it = handleFormat(FormatEntry(it), ×tamp, &body); in dump()
241 body.appendFormat("EVENT_LATENCY,%.3f", latencyMs); in dump()
245 body.appendFormat("EVENT_OVERRUN,%lld", static_cast<long long>(ts)); in dump()
249 body.appendFormat("EVENT_THREAD_INFO,%d,%s", static_cast<int>(info.id), in dump()
254 body.appendFormat("EVENT_UNDERRUN,%lld", static_cast<long long>(ts)); in dump()
258 body.appendFormat("EVENT_WARMUP_TIME,%.3f", timeMs); in dump()
262 body.appendFormat("EVENT_WORK_TIME,%lld", static_cast<long long>(monotonicNs)); in dump()
266 body.appendFormat("EVENT_THREAD_PARAMS,%zu,%u", params.frameCount, params.sampleRate); in dump()
271 body.appendFormat("warning: unexpected event %d", it->type); in dump()
276 if (!body.isEmpty()) { in dump()
277 dprintf(fd, "%.*s%s %s\n", (int)indent, "", timestamp.string(), body.string()); in dump()
278 body.clear(); in dump()
285 String8 *timestamp, String8 *body) in handleFormat() argument
292 if (body == nullptr) { in handleFormat()
293 body = &bodyLocal; in handleFormat()
305 body->appendFormat("%.4X-%d ", (int)(hash >> 16) & 0xFFFF, (int) hash & 0xFFFF); in handleFormat()
308 handleAuthor(fmtEntry, body); in handleFormat()
318 body->append(&fmt[fmt_offset], 1); // TODO optimize to write consecutive strings at once in handleFormat()
323 body->append("%"); in handleFormat()
347 body->append((const char*) datum, length); in handleFormat()
353 appendTimestamp(body, datum); in handleFormat()
359 appendInt(body, datum); in handleFormat()
365 appendFloat(body, datum); in handleFormat()
371 appendPID(body, datum, length); in handleFormat()
383 void DumpReader::appendInt(String8 *body, const void *data) in appendInt() argument
385 if (body == nullptr || data == nullptr) { in appendInt()
391 body->appendFormat("<%d>", x); in appendInt()
394 void DumpReader::appendFloat(String8 *body, const void *data) in appendFloat() argument
396 if (body == nullptr || data == nullptr) { in appendFloat()
401 body->appendFormat("<%f>", f); in appendFloat()
404 void DumpReader::appendPID(String8 *body, const void* data, size_t length) in appendPID() argument
406 if (body == nullptr || data == nullptr) { in appendPID()
411 body->appendFormat("<PID: %d, name: %.*s>", id, (int) (length - sizeof(pid_t)), name); in appendPID()
414 void DumpReader::appendTimestamp(String8 *body, const void *data) in appendTimestamp() argument
416 if (body == nullptr || data == nullptr) { in appendTimestamp()
421 body->appendFormat("[%d.%03d]", (int) (ts / (1000 * 1000 * 1000)), in appendTimestamp()