Lines Matching defs:packet

98   LLDB_LOGF(log, "<%4" PRIu64 "> send packet: %c", (uint64_t)bytes_written, ch);
108 LLDB_LOGF(log, "<%4" PRIu64 "> send packet: %c", (uint64_t)bytes_written, ch);
115 StreamString packet(0, 4, eByteOrderBig);
116 packet.PutChar('$');
117 packet.Write(payload.data(), payload.size());
118 packet.PutChar('#');
119 packet.PutHex8(CalculcateChecksum(payload));
120 std::string packet_str = std::string(packet.GetString());
132 // packet.
134 StreamString packet(0, 4, eByteOrderBig);
135 packet.PutChar('%');
136 packet.Write(notify_type.data(), notify_type.size());
137 packet.PutChar(':');
138 packet.Write(payload.data(), payload.size());
139 packet.PutChar('#');
140 packet.PutHex8(CalculcateChecksum(payload));
141 ret = SendRawPacketNoLock(packet.GetString(), true);
149 GDBRemoteCommunication::SendRawPacketNoLock(llvm::StringRef packet,
154 const char *packet_data = packet.data();
155 const size_t packet_length = packet.size();
171 // logs all of the packet will set a boolean so that we don't dump this
179 strm.Printf("<%4" PRIu64 "> send packet: %.*s", (uint64_t)bytes_written,
190 LLDB_LOGF(log, "<%4" PRIu64 "> send packet: %.*s",
194 m_history.AddPacket(packet.str(), packet_length,
203 LLDB_LOGF(log, "error: failed to send packet: %.*s", (int)packet_length,
211 StringExtractorGDBRemote packet;
212 PacketResult result = WaitForPacketNoLock(packet, GetPacketTimeout(), false);
214 if (packet.GetResponseType() ==
237 LLDB_LOG(log, "discarding spurious `{0}` packet", response.GetStringRef());
242 GDBRemoteCommunication::WaitForPacketNoLock(StringExtractorGDBRemote &packet,
250 // Check for a packet from our cache first without trying any reading...
251 if (CheckForPacket(nullptr, 0, packet) != PacketType::Invalid)
267 if (CheckForPacket(buffer, bytes_read, packet) != PacketType::Invalid)
277 /// Sends a "qEcho" packet and makes sure it gets the exact packet
278 /// echoed back. If the qEcho packet isn't supported, we send a qC
279 /// packet and make sure we get a valid thread ID back. We use the
280 /// "qC" packet since its response if very unique: is responds with
282 /// makes the response unique enough from other packet responses to
285 /// This packet is needed after we time out sending a packet so we
286 /// can ensure that we are getting the response for the packet we
289 /// so if you timeout sending packet "abc", you might then send
290 /// packet "cde" and get the response for the previous "abc" packet.
333 // response, it probably is the response to the packet we
336 packet = echo_response;
342 break; // Something else went wrong getting the packet back, we
353 // before the successful reply to our qEcho packet, so lets say
379 packet.Clear();
396 // Smallest possible compressed packet is $N#00 - an uncompressed empty
397 // reply, most commonly indicating an unsupported packet. Anything less than
398 // 5 characters, it's definitely not a compressed packet.
421 // compressed/not-compressed text of the packet
427 // multiple packets. size_of_first_packet is the size of the initial packet
435 // the <binary> part of the packet.
483 // This packet was not compressed -- delete the 'N' character at the start
484 // and the packet may be processed as-is.
618 StringExtractorGDBRemote &packet) {
619 // Put the packet data into the buffer in a thread safe fashion
637 // end_idx must be one past the last valid packet byte. Start it off with
644 // Size of packet before it is decompressed, for logging purposes
648 packet.Clear();
660 case '%': // Async notify packet
665 // Look for a standard gdb packet?
690 // (NACK), \x03 (CTRL+C interrupt), or '$' character (start of packet
716 packet.Clear();
720 // We have a valid packet...
730 // that logs all of the packet will set a boolean so that we don't dump
750 strm.Printf("<%4" PRIu64 ":%" PRIu64 "> read packet: %c",
754 strm.Printf("<%4" PRIu64 "> read packet: %c",
757 // Remove binary escaped bytes when displaying the packet...
774 LLDB_LOGF(log, "<%4" PRIu64 ":%" PRIu64 "> read packet: %.*s",
778 LLDB_LOGF(log, "<%4" PRIu64 "> read packet: %.*s",
787 // Copy the packet from m_bytes to packet_str expanding the run-length
791 packet = StringExtractorGDBRemote(packet_str);
818 LLDB_LOGF(log, "error: invalid checksum in packet: '%s'\n",
824 packet.SetFilePos(0);
832 packet.Clear();
1304 std::string GDBRemoteCommunication::ExpandRLE(std::string packet) {
1307 decoded.reserve(packet.size());
1308 for (std::string::const_iterator c = packet.begin(); c != packet.end(); ++c) {
1316 // packet.