1 //===-- GDBRemoteCommunicationClient.h --------------------------*- C++ -*-===// 2 // 3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4 // See https://llvm.org/LICENSE.txt for license information. 5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6 // 7 //===----------------------------------------------------------------------===// 8 9 #ifndef LLDB_SOURCE_PLUGINS_PROCESS_GDB_REMOTE_GDBREMOTECOMMUNICATIONCLIENT_H 10 #define LLDB_SOURCE_PLUGINS_PROCESS_GDB_REMOTE_GDBREMOTECOMMUNICATIONCLIENT_H 11 12 #include "GDBRemoteClientBase.h" 13 14 #include <chrono> 15 #include <map> 16 #include <mutex> 17 #include <string> 18 #include <vector> 19 20 #include "lldb/Host/File.h" 21 #include "lldb/Utility/ArchSpec.h" 22 #include "lldb/Utility/GDBRemote.h" 23 #include "lldb/Utility/ProcessInfo.h" 24 #include "lldb/Utility/StructuredData.h" 25 #include "lldb/Utility/TraceGDBRemotePackets.h" 26 #if defined(_WIN32) 27 #include "lldb/Host/windows/PosixApi.h" 28 #endif 29 30 #include "llvm/ADT/Optional.h" 31 #include "llvm/Support/VersionTuple.h" 32 33 namespace lldb_private { 34 namespace process_gdb_remote { 35 36 /// The offsets used by the target when relocating the executable. Decoded from 37 /// qOffsets packet response. 38 struct QOffsets { 39 /// If true, the offsets field describes segments. Otherwise, it describes 40 /// sections. 41 bool segments; 42 43 /// The individual offsets. Section offsets have two or three members. 44 /// Segment offsets have either one of two. 45 std::vector<uint64_t> offsets; 46 }; 47 inline bool operator==(const QOffsets &a, const QOffsets &b) { 48 return a.segments == b.segments && a.offsets == b.offsets; 49 } 50 llvm::raw_ostream &operator<<(llvm::raw_ostream &os, const QOffsets &offsets); 51 52 class GDBRemoteCommunicationClient : public GDBRemoteClientBase { 53 public: 54 GDBRemoteCommunicationClient(); 55 56 ~GDBRemoteCommunicationClient() override; 57 58 // After connecting, send the handshake to the server to make sure 59 // we are communicating with it. 60 bool HandshakeWithServer(Status *error_ptr); 61 62 // For packets which specify a range of output to be returned, 63 // return all of the output via a series of request packets of the form 64 // <prefix>0,<size> 65 // <prefix><size>,<size> 66 // <prefix><size>*2,<size> 67 // <prefix><size>*3,<size> 68 // ... 69 // until a "$l..." packet is received, indicating the end. 70 // (size is in hex; this format is used by a standard gdbserver to 71 // return the given portion of the output specified by <prefix>; 72 // for example, "qXfer:libraries-svr4:read::fff,1000" means 73 // "return a chunk of the xml description file for shared 74 // library load addresses, where the chunk starts at offset 0xfff 75 // and continues for 0x1000 bytes"). 76 // Concatenate the resulting server response packets together and 77 // return in response_string. If any packet fails, the return value 78 // indicates that failure and the returned string value is undefined. 79 PacketResult 80 SendPacketsAndConcatenateResponses(const char *send_payload_prefix, 81 std::string &response_string); 82 83 bool GetThreadSuffixSupported(); 84 85 // This packet is usually sent first and the boolean return value 86 // indicates if the packet was send and any response was received 87 // even in the response is UNIMPLEMENTED. If the packet failed to 88 // get a response, then false is returned. This quickly tells us 89 // if we were able to connect and communicate with the remote GDB 90 // server 91 bool QueryNoAckModeSupported(); 92 93 void GetListThreadsInStopReplySupported(); 94 95 lldb::pid_t GetCurrentProcessID(bool allow_lazy = true); 96 97 bool GetLaunchSuccess(std::string &error_str); 98 99 bool LaunchGDBServer(const char *remote_accept_hostname, lldb::pid_t &pid, 100 uint16_t &port, std::string &socket_name); 101 102 size_t QueryGDBServer( 103 std::vector<std::pair<uint16_t, std::string>> &connection_urls); 104 105 bool KillSpawnedProcess(lldb::pid_t pid); 106 107 /// Sends a GDB remote protocol 'A' packet that delivers program 108 /// arguments to the remote server. 109 /// 110 /// \param[in] launch_info 111 /// A NULL terminated array of const C strings to use as the 112 /// arguments. 113 /// 114 /// \return 115 /// Zero if the response was "OK", a positive value if the 116 /// the response was "Exx" where xx are two hex digits, or 117 /// -1 if the call is unsupported or any other unexpected 118 /// response was received. 119 int SendArgumentsPacket(const ProcessLaunchInfo &launch_info); 120 121 /// Sends a "QEnvironment:NAME=VALUE" packet that will build up the 122 /// environment that will get used when launching an application 123 /// in conjunction with the 'A' packet. This function can be called 124 /// multiple times in a row in order to pass on the desired 125 /// environment that the inferior should be launched with. 126 /// 127 /// \param[in] name_equal_value 128 /// A NULL terminated C string that contains a single environment 129 /// in the format "NAME=VALUE". 130 /// 131 /// \return 132 /// Zero if the response was "OK", a positive value if the 133 /// the response was "Exx" where xx are two hex digits, or 134 /// -1 if the call is unsupported or any other unexpected 135 /// response was received. 136 int SendEnvironmentPacket(char const *name_equal_value); 137 int SendEnvironment(const Environment &env); 138 139 int SendLaunchArchPacket(const char *arch); 140 141 int SendLaunchEventDataPacket(const char *data, 142 bool *was_supported = nullptr); 143 144 /// Sends a "vAttach:PID" where PID is in hex. 145 /// 146 /// \param[in] pid 147 /// A process ID for the remote gdb server to attach to. 148 /// 149 /// \param[out] response 150 /// The response received from the gdb server. If the return 151 /// value is zero, \a response will contain a stop reply 152 /// packet. 153 /// 154 /// \return 155 /// Zero if the attach was successful, or an error indicating 156 /// an error code. 157 int SendAttach(lldb::pid_t pid, StringExtractorGDBRemote &response); 158 159 /// Sends a GDB remote protocol 'I' packet that delivers stdin 160 /// data to the remote process. 161 /// 162 /// \param[in] data 163 /// A pointer to stdin data. 164 /// 165 /// \param[in] data_len 166 /// The number of bytes available at \a data. 167 /// 168 /// \return 169 /// Zero if the attach was successful, or an error indicating 170 /// an error code. 171 int SendStdinNotification(const char *data, size_t data_len); 172 173 /// Sets the path to use for stdin/out/err for a process 174 /// that will be launched with the 'A' packet. 175 /// 176 /// \param[in] file_spec 177 /// The path to use for stdin/out/err 178 /// 179 /// \return 180 /// Zero if the for success, or an error code for failure. 181 int SetSTDIN(const FileSpec &file_spec); 182 int SetSTDOUT(const FileSpec &file_spec); 183 int SetSTDERR(const FileSpec &file_spec); 184 185 /// Sets the disable ASLR flag to \a enable for a process that will 186 /// be launched with the 'A' packet. 187 /// 188 /// \param[in] enable 189 /// A boolean value indicating whether to disable ASLR or not. 190 /// 191 /// \return 192 /// Zero if the for success, or an error code for failure. 193 int SetDisableASLR(bool enable); 194 195 /// Sets the DetachOnError flag to \a enable for the process controlled by the 196 /// stub. 197 /// 198 /// \param[in] enable 199 /// A boolean value indicating whether to detach on error or not. 200 /// 201 /// \return 202 /// Zero if the for success, or an error code for failure. 203 int SetDetachOnError(bool enable); 204 205 /// Sets the working directory to \a path for a process that will 206 /// be launched with the 'A' packet for non platform based 207 /// connections. If this packet is sent to a GDB server that 208 /// implements the platform, it will change the current working 209 /// directory for the platform process. 210 /// 211 /// \param[in] working_dir 212 /// The path to a directory to use when launching our process 213 /// 214 /// \return 215 /// Zero if the for success, or an error code for failure. 216 int SetWorkingDir(const FileSpec &working_dir); 217 218 /// Gets the current working directory of a remote platform GDB 219 /// server. 220 /// 221 /// \param[out] working_dir 222 /// The current working directory on the remote platform. 223 /// 224 /// \return 225 /// Boolean for success 226 bool GetWorkingDir(FileSpec &working_dir); 227 228 lldb::addr_t AllocateMemory(size_t size, uint32_t permissions); 229 230 bool DeallocateMemory(lldb::addr_t addr); 231 232 Status Detach(bool keep_stopped); 233 234 Status GetMemoryRegionInfo(lldb::addr_t addr, MemoryRegionInfo &range_info); 235 236 Status GetWatchpointSupportInfo(uint32_t &num); 237 238 Status GetWatchpointSupportInfo(uint32_t &num, bool &after, 239 const ArchSpec &arch); 240 241 Status GetWatchpointsTriggerAfterInstruction(bool &after, 242 const ArchSpec &arch); 243 244 const ArchSpec &GetHostArchitecture(); 245 246 std::chrono::seconds GetHostDefaultPacketTimeout(); 247 248 const ArchSpec &GetProcessArchitecture(); 249 250 void GetRemoteQSupported(); 251 252 bool GetVContSupported(char flavor); 253 254 bool GetpPacketSupported(lldb::tid_t tid); 255 256 bool GetxPacketSupported(); 257 258 bool GetVAttachOrWaitSupported(); 259 260 bool GetSyncThreadStateSupported(); 261 262 void ResetDiscoverableSettings(bool did_exec); 263 264 bool GetHostInfo(bool force = false); 265 266 bool GetDefaultThreadId(lldb::tid_t &tid); 267 268 llvm::VersionTuple GetOSVersion(); 269 270 llvm::VersionTuple GetMacCatalystVersion(); 271 272 bool GetOSBuildString(std::string &s); 273 274 bool GetOSKernelDescription(std::string &s); 275 276 ArchSpec GetSystemArchitecture(); 277 278 uint32_t GetAddressingBits(); 279 280 bool GetHostname(std::string &s); 281 282 lldb::addr_t GetShlibInfoAddr(); 283 284 bool GetSupportsThreadSuffix(); 285 286 bool GetProcessInfo(lldb::pid_t pid, ProcessInstanceInfo &process_info); 287 288 uint32_t FindProcesses(const ProcessInstanceInfoMatch &process_match_info, 289 ProcessInstanceInfoList &process_infos); 290 291 bool GetUserName(uint32_t uid, std::string &name); 292 293 bool GetGroupName(uint32_t gid, std::string &name); 294 295 bool HasFullVContSupport() { return GetVContSupported('A'); } 296 297 bool HasAnyVContSupport() { return GetVContSupported('a'); } 298 299 bool GetStopReply(StringExtractorGDBRemote &response); 300 301 bool GetThreadStopInfo(lldb::tid_t tid, StringExtractorGDBRemote &response); 302 303 bool SupportsGDBStoppointPacket(GDBStoppointType type) { 304 switch (type) { 305 case eBreakpointSoftware: 306 return m_supports_z0; 307 case eBreakpointHardware: 308 return m_supports_z1; 309 case eWatchpointWrite: 310 return m_supports_z2; 311 case eWatchpointRead: 312 return m_supports_z3; 313 case eWatchpointReadWrite: 314 return m_supports_z4; 315 default: 316 return false; 317 } 318 } 319 320 uint8_t SendGDBStoppointTypePacket( 321 GDBStoppointType type, // Type of breakpoint or watchpoint 322 bool insert, // Insert or remove? 323 lldb::addr_t addr, // Address of breakpoint or watchpoint 324 uint32_t length, // Byte Size of breakpoint or watchpoint 325 std::chrono::seconds interrupt_timeout); // Time to wait for an interrupt 326 327 bool SetNonStopMode(const bool enable); 328 329 void TestPacketSpeed(const uint32_t num_packets, uint32_t max_send, 330 uint32_t max_recv, uint64_t recv_amount, bool json, 331 Stream &strm); 332 333 // This packet is for testing the speed of the interface only. Both 334 // the client and server need to support it, but this allows us to 335 // measure the packet speed without any other work being done on the 336 // other end and avoids any of that work affecting the packet send 337 // and response times. 338 bool SendSpeedTestPacket(uint32_t send_size, uint32_t recv_size); 339 340 bool SetCurrentThread(uint64_t tid); 341 342 bool SetCurrentThreadForRun(uint64_t tid); 343 344 bool GetQXferAuxvReadSupported(); 345 346 void EnableErrorStringInPacket(); 347 348 bool GetQXferLibrariesReadSupported(); 349 350 bool GetQXferLibrariesSVR4ReadSupported(); 351 352 uint64_t GetRemoteMaxPacketSize(); 353 354 bool GetEchoSupported(); 355 356 bool GetQPassSignalsSupported(); 357 358 bool GetAugmentedLibrariesSVR4ReadSupported(); 359 360 bool GetQXferFeaturesReadSupported(); 361 362 bool GetQXferMemoryMapReadSupported(); 363 364 LazyBool SupportsAllocDeallocMemory() // const 365 { 366 // Uncomment this to have lldb pretend the debug server doesn't respond to 367 // alloc/dealloc memory packets. 368 // m_supports_alloc_dealloc_memory = lldb_private::eLazyBoolNo; 369 return m_supports_alloc_dealloc_memory; 370 } 371 372 std::vector<std::pair<lldb::pid_t, lldb::tid_t>> 373 GetCurrentProcessAndThreadIDs(bool &sequence_mutex_unavailable); 374 375 size_t GetCurrentThreadIDs(std::vector<lldb::tid_t> &thread_ids, 376 bool &sequence_mutex_unavailable); 377 378 lldb::user_id_t OpenFile(const FileSpec &file_spec, File::OpenOptions flags, 379 mode_t mode, Status &error); 380 381 bool CloseFile(lldb::user_id_t fd, Status &error); 382 383 lldb::user_id_t GetFileSize(const FileSpec &file_spec); 384 385 void AutoCompleteDiskFileOrDirectory(CompletionRequest &request, 386 bool only_dir); 387 388 Status GetFilePermissions(const FileSpec &file_spec, 389 uint32_t &file_permissions); 390 391 Status SetFilePermissions(const FileSpec &file_spec, 392 uint32_t file_permissions); 393 394 uint64_t ReadFile(lldb::user_id_t fd, uint64_t offset, void *dst, 395 uint64_t dst_len, Status &error); 396 397 uint64_t WriteFile(lldb::user_id_t fd, uint64_t offset, const void *src, 398 uint64_t src_len, Status &error); 399 400 Status CreateSymlink(const FileSpec &src, const FileSpec &dst); 401 402 Status Unlink(const FileSpec &file_spec); 403 404 Status MakeDirectory(const FileSpec &file_spec, uint32_t mode); 405 406 bool GetFileExists(const FileSpec &file_spec); 407 408 Status RunShellCommand( 409 llvm::StringRef command, 410 const FileSpec &working_dir, // Pass empty FileSpec to use the current 411 // working directory 412 int *status_ptr, // Pass nullptr if you don't want the process exit status 413 int *signo_ptr, // Pass nullptr if you don't want the signal that caused 414 // the process to exit 415 std::string 416 *command_output, // Pass nullptr if you don't want the command output 417 const Timeout<std::micro> &timeout); 418 419 bool CalculateMD5(const FileSpec &file_spec, uint64_t &high, uint64_t &low); 420 421 lldb::DataBufferSP ReadRegister( 422 lldb::tid_t tid, 423 uint32_t 424 reg_num); // Must be the eRegisterKindProcessPlugin register number 425 426 lldb::DataBufferSP ReadAllRegisters(lldb::tid_t tid); 427 428 bool 429 WriteRegister(lldb::tid_t tid, 430 uint32_t reg_num, // eRegisterKindProcessPlugin register number 431 llvm::ArrayRef<uint8_t> data); 432 433 bool WriteAllRegisters(lldb::tid_t tid, llvm::ArrayRef<uint8_t> data); 434 435 bool SaveRegisterState(lldb::tid_t tid, uint32_t &save_id); 436 437 bool RestoreRegisterState(lldb::tid_t tid, uint32_t save_id); 438 439 bool SyncThreadState(lldb::tid_t tid); 440 441 const char *GetGDBServerProgramName(); 442 443 uint32_t GetGDBServerProgramVersion(); 444 445 bool AvoidGPackets(ProcessGDBRemote *process); 446 447 StructuredData::ObjectSP GetThreadsInfo(); 448 449 bool GetThreadExtendedInfoSupported(); 450 451 bool GetLoadedDynamicLibrariesInfosSupported(); 452 453 bool GetSharedCacheInfoSupported(); 454 455 /// Use qOffsets to query the offset used when relocating the target 456 /// executable. If successful, the returned structure will contain at least 457 /// one value in the offsets field. 458 llvm::Optional<QOffsets> GetQOffsets(); 459 460 bool GetModuleInfo(const FileSpec &module_file_spec, 461 const ArchSpec &arch_spec, ModuleSpec &module_spec); 462 463 llvm::Optional<std::vector<ModuleSpec>> 464 GetModulesInfo(llvm::ArrayRef<FileSpec> module_file_specs, 465 const llvm::Triple &triple); 466 467 bool ReadExtFeature(const lldb_private::ConstString object, 468 const lldb_private::ConstString annex, std::string &out, 469 lldb_private::Status &err); 470 471 void ServeSymbolLookups(lldb_private::Process *process); 472 473 // Sends QPassSignals packet to the server with given signals to ignore. 474 Status SendSignalsToIgnore(llvm::ArrayRef<int32_t> signals); 475 476 /// Return the feature set supported by the gdb-remote server. 477 /// 478 /// This method returns the remote side's response to the qSupported 479 /// packet. The response is the complete string payload returned 480 /// to the client. 481 /// 482 /// \return 483 /// The string returned by the server to the qSupported query. 484 const std::string &GetServerSupportedFeatures() const { 485 return m_qSupported_response; 486 } 487 488 /// Return the array of async JSON packet types supported by the remote. 489 /// 490 /// This method returns the remote side's array of supported JSON 491 /// packet types as a list of type names. Each of the results are 492 /// expected to have an Enable{type_name} command to enable and configure 493 /// the related feature. Each type_name for an enabled feature will 494 /// possibly send async-style packets that contain a payload of a 495 /// binhex-encoded JSON dictionary. The dictionary will have a 496 /// string field named 'type', that contains the type_name of the 497 /// supported packet type. 498 /// 499 /// There is a Plugin category called structured-data plugins. 500 /// A plugin indicates whether it knows how to handle a type_name. 501 /// If so, it can be used to process the async JSON packet. 502 /// 503 /// \return 504 /// The string returned by the server to the qSupported query. 505 lldb_private::StructuredData::Array *GetSupportedStructuredDataPlugins(); 506 507 /// Configure a StructuredData feature on the remote end. 508 /// 509 /// \see \b Process::ConfigureStructuredData(...) for details. 510 Status 511 ConfigureRemoteStructuredData(ConstString type_name, 512 const StructuredData::ObjectSP &config_sp); 513 514 llvm::Expected<TraceSupportedResponse> 515 SendTraceSupported(std::chrono::seconds interrupt_timeout); 516 517 llvm::Error SendTraceStart(const llvm::json::Value &request, 518 std::chrono::seconds interrupt_timeout); 519 520 llvm::Error SendTraceStop(const TraceStopRequest &request, 521 std::chrono::seconds interrupt_timeout); 522 523 llvm::Expected<std::string> 524 SendTraceGetState(llvm::StringRef type, 525 std::chrono::seconds interrupt_timeout); 526 527 llvm::Expected<std::vector<uint8_t>> 528 SendTraceGetBinaryData(const TraceGetBinaryDataRequest &request, 529 std::chrono::seconds interrupt_timeout); 530 531 protected: 532 LazyBool m_supports_not_sending_acks; 533 LazyBool m_supports_thread_suffix; 534 LazyBool m_supports_threads_in_stop_reply; 535 LazyBool m_supports_vCont_all; 536 LazyBool m_supports_vCont_any; 537 LazyBool m_supports_vCont_c; 538 LazyBool m_supports_vCont_C; 539 LazyBool m_supports_vCont_s; 540 LazyBool m_supports_vCont_S; 541 LazyBool m_qHostInfo_is_valid; 542 LazyBool m_curr_pid_is_valid; 543 LazyBool m_qProcessInfo_is_valid; 544 LazyBool m_qGDBServerVersion_is_valid; 545 LazyBool m_supports_alloc_dealloc_memory; 546 LazyBool m_supports_memory_region_info; 547 LazyBool m_supports_watchpoint_support_info; 548 LazyBool m_supports_detach_stay_stopped; 549 LazyBool m_watchpoints_trigger_after_instruction; 550 LazyBool m_attach_or_wait_reply; 551 LazyBool m_prepare_for_reg_writing_reply; 552 LazyBool m_supports_p; 553 LazyBool m_supports_x; 554 LazyBool m_avoid_g_packets; 555 LazyBool m_supports_QSaveRegisterState; 556 LazyBool m_supports_qXfer_auxv_read; 557 LazyBool m_supports_qXfer_libraries_read; 558 LazyBool m_supports_qXfer_libraries_svr4_read; 559 LazyBool m_supports_qXfer_features_read; 560 LazyBool m_supports_qXfer_memory_map_read; 561 LazyBool m_supports_augmented_libraries_svr4_read; 562 LazyBool m_supports_jThreadExtendedInfo; 563 LazyBool m_supports_jLoadedDynamicLibrariesInfos; 564 LazyBool m_supports_jGetSharedCacheInfo; 565 LazyBool m_supports_QPassSignals; 566 LazyBool m_supports_error_string_reply; 567 LazyBool m_supports_multiprocess; 568 569 bool m_supports_qProcessInfoPID : 1, m_supports_qfProcessInfo : 1, 570 m_supports_qUserName : 1, m_supports_qGroupName : 1, 571 m_supports_qThreadStopInfo : 1, m_supports_z0 : 1, m_supports_z1 : 1, 572 m_supports_z2 : 1, m_supports_z3 : 1, m_supports_z4 : 1, 573 m_supports_QEnvironment : 1, m_supports_QEnvironmentHexEncoded : 1, 574 m_supports_qSymbol : 1, m_qSymbol_requests_done : 1, 575 m_supports_qModuleInfo : 1, m_supports_jThreadsInfo : 1, 576 m_supports_jModulesInfo : 1; 577 578 lldb::pid_t m_curr_pid; 579 lldb::tid_t m_curr_tid; // Current gdb remote protocol thread index for all 580 // other operations 581 lldb::tid_t m_curr_tid_run; // Current gdb remote protocol thread index for 582 // continue, step, etc 583 584 uint32_t m_num_supported_hardware_watchpoints; 585 uint32_t m_addressing_bits; 586 587 ArchSpec m_host_arch; 588 ArchSpec m_process_arch; 589 llvm::VersionTuple m_os_version; 590 llvm::VersionTuple m_maccatalyst_version; 591 std::string m_os_build; 592 std::string m_os_kernel; 593 std::string m_hostname; 594 std::string m_gdb_server_name; // from reply to qGDBServerVersion, empty if 595 // qGDBServerVersion is not supported 596 uint32_t m_gdb_server_version; // from reply to qGDBServerVersion, zero if 597 // qGDBServerVersion is not supported 598 std::chrono::seconds m_default_packet_timeout; 599 uint64_t m_max_packet_size; // as returned by qSupported 600 std::string m_qSupported_response; // the complete response to qSupported 601 602 bool m_supported_async_json_packets_is_valid; 603 lldb_private::StructuredData::ObjectSP m_supported_async_json_packets_sp; 604 605 std::vector<MemoryRegionInfo> m_qXfer_memory_map; 606 bool m_qXfer_memory_map_loaded; 607 608 bool GetCurrentProcessInfo(bool allow_lazy_pid = true); 609 610 bool GetGDBServerVersion(); 611 612 // Given the list of compression types that the remote debug stub can support, 613 // possibly enable compression if we find an encoding we can handle. 614 void MaybeEnableCompression( 615 llvm::ArrayRef<llvm::StringRef> supported_compressions); 616 617 bool DecodeProcessInfoResponse(StringExtractorGDBRemote &response, 618 ProcessInstanceInfo &process_info); 619 620 void OnRunPacketSent(bool first) override; 621 622 PacketResult SendThreadSpecificPacketAndWaitForResponse( 623 lldb::tid_t tid, StreamString &&payload, 624 StringExtractorGDBRemote &response); 625 626 Status SendGetTraceDataPacket(StreamGDBRemote &packet, lldb::user_id_t uid, 627 lldb::tid_t thread_id, 628 llvm::MutableArrayRef<uint8_t> &buffer, 629 size_t offset); 630 631 Status LoadQXferMemoryMap(); 632 633 Status GetQXferMemoryMapRegionInfo(lldb::addr_t addr, 634 MemoryRegionInfo ®ion); 635 636 LazyBool GetThreadPacketSupported(lldb::tid_t tid, llvm::StringRef packetStr); 637 638 private: 639 GDBRemoteCommunicationClient(const GDBRemoteCommunicationClient &) = delete; 640 const GDBRemoteCommunicationClient & 641 operator=(const GDBRemoteCommunicationClient &) = delete; 642 }; 643 644 } // namespace process_gdb_remote 645 } // namespace lldb_private 646 647 #endif // LLDB_SOURCE_PLUGINS_PROCESS_GDB_REMOTE_GDBREMOTECOMMUNICATIONCLIENT_H 648