Home
last modified time | relevance | path

Searched refs:proto_utils (Results 1 – 25 of 85) sorted by relevance

1234

/external/perfetto/include/perfetto/protozero/
Dfield.h62 proto_utils::ProtoWireType type() const { in type()
63 auto res = static_cast<proto_utils::ProtoWireType>(type_); in type()
64 PERFETTO_DCHECK(res == proto_utils::ProtoWireType::kVarInt || in type()
65 res == proto_utils::ProtoWireType::kLengthDelimited || in type()
66 res == proto_utils::ProtoWireType::kFixed32 || in type()
67 res == proto_utils::ProtoWireType::kFixed64); in type()
72 PERFETTO_DCHECK(!valid() || type() == proto_utils::ProtoWireType::kVarInt); in as_bool()
77 PERFETTO_DCHECK(!valid() || type() == proto_utils::ProtoWireType::kVarInt || in as_uint32()
78 type() == proto_utils::ProtoWireType::kFixed32); in as_uint32()
83 PERFETTO_DCHECK(!valid() || type() == proto_utils::ProtoWireType::kVarInt || in as_int32()
[all …]
Dfield_writer.h26 template <proto_utils::ProtoSchemaType proto_schema_type>
28 static_assert(proto_schema_type != proto_utils::ProtoSchemaType::kMessage,
33 struct FieldWriter<proto_utils::ProtoSchemaType::kDouble> {
40 struct FieldWriter<proto_utils::ProtoSchemaType::kFloat> {
47 struct FieldWriter<proto_utils::ProtoSchemaType::kBool> {
54 struct FieldWriter<proto_utils::ProtoSchemaType::kInt32> {
63 struct FieldWriter<proto_utils::ProtoSchemaType::kInt64> {
72 struct FieldWriter<proto_utils::ProtoSchemaType::kUint32> {
81 struct FieldWriter<proto_utils::ProtoSchemaType::kUint64> {
90 struct FieldWriter<proto_utils::ProtoSchemaType::kSint32> {
[all …]
Dmessage.h97 uint8_t buffer[proto_utils::kMaxSimpleFieldEncodedSize]; in AppendVarInt()
100 pos = proto_utils::WriteVarInt(proto_utils::MakeTagVarInt(field_id), pos); in AppendVarInt()
102 pos = proto_utils::WriteVarInt(value, pos); in AppendVarInt()
109 AppendVarInt(field_id, proto_utils::ZigZagEncode(value)); in AppendSignedVarInt()
119 uint8_t buffer[proto_utils::kMaxSimpleFieldEncodedSize]; in AppendTinyVarInt()
122 pos = proto_utils::WriteVarInt(proto_utils::MakeTagVarInt(field_id), pos); in AppendTinyVarInt()
133 uint8_t buffer[proto_utils::kMaxSimpleFieldEncodedSize]; in AppendFixed()
136 pos = proto_utils::WriteVarInt(proto_utils::MakeTagFixed<T>(field_id), pos); in AppendFixed()
Dproto_decoder.h172 template <proto_utils::ProtoWireType wire_type, typename CppType>
181 using proto_utils::ProtoWireType; in PackedRepeatedFieldIterator()
211 using proto_utils::ProtoWireType;
224 proto_utils::ParseVarInt(read_ptr_, data_end_, &new_value);
310 template <proto_utils::ProtoWireType wire_type, typename cpp_type>
/external/perfetto/src/protozero/
Dmessage.cc77 PERFETTO_DCHECK(size < proto_utils::kMaxMessageLength); in AppendBytes()
79 uint8_t buffer[proto_utils::kMaxSimpleFieldEncodedSize]; in AppendBytes()
81 pos = proto_utils::WriteVarInt(proto_utils::MakeTagLengthDelimited(field_id), in AppendBytes()
83 pos = proto_utils::WriteVarInt(static_cast<uint32_t>(size), pos); in AppendBytes()
98 PERFETTO_DCHECK(size < proto_utils::kMaxMessageLength); in AppendScatteredBytes()
100 uint8_t buffer[proto_utils::kMaxSimpleFieldEncodedSize]; in AppendScatteredBytes()
102 pos = proto_utils::WriteVarInt(proto_utils::MakeTagLengthDelimited(field_id), in AppendScatteredBytes()
104 pos = proto_utils::WriteVarInt(static_cast<uint32_t>(size), pos); in AppendScatteredBytes()
126 PERFETTO_DCHECK(size_ < proto_utils::kMaxMessageLength); in Finalize()
128 proto_utils::WriteRedundantVarInt(size_ - size_already_written_, in Finalize()
[all …]
Dmessage_unittest.cc243 uint8_t root_msg_size[proto_utils::kMessageLengthFieldSize] = {}; in TEST_F()
325 uint8_t msg1_size[proto_utils::kMessageLengthFieldSize] = {}; in TEST_F()
326 uint8_t msg2_size[proto_utils::kMessageLengthFieldSize] = {}; in TEST_F()
327 uint8_t msg3_size[proto_utils::kMessageLengthFieldSize] = {}; in TEST_F()
387 memset(size_msg_1, 0, proto_utils::kMessageLengthFieldSize); in TEST_F()
392 memset(size_msg_2, 0, proto_utils::kMessageLengthFieldSize); in TEST_F()
410 uint8_t msg_size[proto_utils::kMessageLengthFieldSize] = {}; in TEST_F()
/external/perfetto/src/protozero/filtering/
Dmessage_filter.cc35 *out = proto_utils::WriteVarInt(proto_utils::MakeTagVarInt(field_id), *out); in AppendVarInt()
36 *out = proto_utils::WriteVarInt(value, *out); in AppendVarInt()
42 *out = proto_utils::WriteVarInt(proto_utils::MakeTagFixed<INT_T>(field_id), in AppendFixed()
62 *out = proto_utils::WriteVarInt(proto_utils::MakeTagLengthDelimited(field_id), in AppendLenDelim()
65 *out = proto_utils::WriteVarInt(len, *out); in AppendLenDelim()
165 case proto_utils::ProtoWireType::kVarInt: in FilterOneByte()
169 case proto_utils::ProtoWireType::kFixed32: in FilterOneByte()
174 case proto_utils::ProtoWireType::kFixed64: in FilterOneByte()
179 case proto_utils::ProtoWireType::kLengthDelimited: in FilterOneByte()
245 proto_utils::WriteRedundantVarInt(msg_bytes_written, state->size_field, in FilterOneByte()
[all …]
Dmessage_tokenizer.h48 proto_utils::ProtoWireType type;
68 using protozero::proto_utils::ProtoWireType; in Push()
140 if (payload_len > protozero::proto_utils::kMaxMessageLength) { in Push()
/external/perfetto/src/tracing/core/
Dtrace_writer_for_testing.cc78 uint8_t data[protozero::proto_utils::kMaxTagEncodedSize]; in NewTracePacket()
79 uint8_t* data_end = protozero::proto_utils::WriteVarInt( in NewTracePacket()
80 protozero::proto_utils::MakeTagLengthDelimited( in NewTracePacket()
87 stream_.ReserveBytes(protozero::proto_utils::kMessageLengthFieldSize)); in NewTracePacket()
Dtrace_packet.cc50 using protozero::proto_utils::MakeTagLengthDelimited; in GetProtoPreamble()
51 using protozero::proto_utils::WriteVarInt; in GetProtoPreamble()
Dpacket_stream_validator.cc32 using protozero::proto_utils::ProtoWireType;
123 if (varint > protozero::proto_utils::kMaxMessageLength) { in Push()
/external/perfetto/src/trace_processor/rpc/
Dproto_ring_buffer.cc40 namespace proto_utils = protozero::proto_utils; in TryReadMessage()
42 auto* start_of_len = proto_utils::ParseVarInt(start, end, &field_tag); in TryReadMessage()
48 static_cast<uint32_t>(proto_utils::ProtoWireType::kLengthDelimited)) { in TryReadMessage()
54 auto* start_of_msg = proto_utils::ParseVarInt(start_of_len, end, &msg_len); in TryReadMessage()
Dproto_ring_buffer_unittest.cc69 namespace proto_utils = protozero::proto_utils; in MakeProtoMessage()
78 auto tag = proto_utils::MakeTagLengthDelimited(field_id); in MakeProtoMessage()
79 wptr = proto_utils::WriteVarInt(tag, wptr); in MakeProtoMessage()
80 wptr = proto_utils::WriteVarInt(len, wptr); in MakeProtoMessage()
/external/tensorflow/tensorflow/core/util/proto/
DBUILD66 name = "proto_utils",
67 srcs = ["proto_utils.cc"],
68 hdrs = ["proto_utils.h"],
83 ":proto_utils",
Dproto_utils_test.cc25 using proto_utils::ParseTextFormatFromString;
26 using proto_utils::StringErrorCollector;
/external/perfetto/include/perfetto/tracing/
Dtraced_proto.h89 using ProtoSchemaType = protozero::proto_utils::ProtoSchemaType;
90 using RepetitionType = protozero::proto_utils::RepetitionType;
164 protozero::proto_utils::internal::FieldMetadataHelper<FieldMetadataType>, in WriteIntoTracedProto()
167 std::is_base_of<protozero::proto_utils::FieldMetadataBase, in WriteIntoTracedProto()
/external/perfetto/tools/protoprofile/
Dmain.cc38 using protozero::proto_utils::ProtoWireType;
127 case protozero::proto_utils::ProtoWireType::kVarInt: in GetFieldSize()
129 protozero::proto_utils::WriteVarInt(f.as_uint64(), buf) - buf); in GetFieldSize()
130 case protozero::proto_utils::ProtoWireType::kLengthDelimited: in GetFieldSize()
132 case protozero::proto_utils::ProtoWireType::kFixed32: in GetFieldSize()
134 case protozero::proto_utils::ProtoWireType::kFixed64: in GetFieldSize()
/external/perfetto/src/trace_processor/
Dread_trace.cc87 uint8_t buffer[protozero::proto_utils::kMaxSimpleFieldEncodedSize]; in Parse()
90 pos = protozero::proto_utils::WriteVarInt(kTracePacketTag, pos); in Parse()
91 pos = protozero::proto_utils::WriteVarInt(packet.length(), pos); in Parse()
104 protozero::proto_utils::MakeTagLengthDelimited(
/external/perfetto/src/traced/probes/ftrace/
Devent_info_constants.h145 protozero::proto_utils::ProtoSchemaType proto_field_type;
171 protozero::proto_utils::ProtoSchemaType proto,
/external/perfetto/include/perfetto/tracing/internal/
Dwrite_track_event_args.h99 std::is_base_of<protozero::proto_utils::FieldMetadataBase,
103 protozero::proto_utils::internal::FieldMetadataHelper<FieldMetadataType> in WriteTrackEventArgs()
/external/perfetto/src/protozero/test/
Dprotozero_conformance_unittest.cc191 EXPECT_EQ(proto_utils::MakeTagLengthDelimited( in TEST()
219 EXPECT_EQ(proto_utils::MakeTagLengthDelimited( in TEST()
248 EXPECT_EQ(proto_utils::MakeTagLengthDelimited( in TEST()
273 EXPECT_EQ(proto_utils::MakeTagLengthDelimited( in TEST()
/external/perfetto/src/trace_processor/importers/proto/
Dproto_trace_tokenizer.h64 const uint8_t* next = protozero::proto_utils::ParseVarInt( in Tokenize()
111 protozero::proto_utils::MakeTagLengthDelimited(
166 ptr = protozero::proto_utils::ParseVarInt(++ptr, end, &packet_size); in ParsePacket()
/external/perfetto/src/trace_processor/util/
Dproto_to_args_parser.h91 protozero::proto_utils::internal::FieldMetadataHelper<FieldMetadata>, in GetInternedMessage()
93 static_assert(std::is_base_of<protozero::proto_utils::FieldMetadataBase, in GetInternedMessage()
/external/perfetto/src/kallsyms/
Dkernel_symbol_map.cc347 wptr = protozero::proto_utils::WriteVarInt(delta, wptr); in Parse()
356 wptr = protozero::proto_utils::WriteVarInt(token_id, wptr); in Parse()
404 rdptr = protozero::proto_utils::ParseVarInt(rdptr, buf_end, &v); in Lookup()
439 rdptr = protozero::proto_utils::ParseVarInt(rdptr, buf_end, &v); in Lookup()
/external/tensorflow/tensorflow/compiler/xla/service/gpu/
Dgpu_conv_algorithm_picker.cc493 *result.mutable_run_time() = tensorflow::proto_utils::ToDurationProto( in PickBestAlgorithmNoCacheCuda()
644 return tensorflow::proto_utils::FromDurationProto(lhs.run_time()) < in PickBestAlgorithmNoCacheCuda()
645 tensorflow::proto_utils::FromDurationProto(rhs.run_time()); in PickBestAlgorithmNoCacheCuda()
707 *result.mutable_run_time() = tensorflow::proto_utils::ToDurationProto( in PickBestAlgorithmNoCacheRocm()
746 *result.mutable_run_time() = tensorflow::proto_utils::ToDurationProto( in PickBestAlgorithmNoCacheRocm()
753 return tensorflow::proto_utils::FromDurationProto(lhs.run_time()) < in PickBestAlgorithmNoCacheRocm()
754 tensorflow::proto_utils::FromDurationProto(rhs.run_time()); in PickBestAlgorithmNoCacheRocm()

1234