Crate ckb_gdb_remote_protocol

Source
Expand description

An implementation of the server side of the GDB Remote Serial Protocol – the protocol used by GDB and LLDB to talk to remote targets.

This library attempts to hide many of the protocol warts from server implementations. It is also mildly opinionated, in that it implements certain features itself and requires users of the library to conform. For example, it unconditionally implements the multiprocess and non-stop modes.

§Protocol Documentation

Structs§

Breakpoint
A descriptor for a breakpoint. The particular implementation technique of the breakpoint, hardware or software, is handled elsewhere.
Bytecode
Target-specific bytecode.
HostMode
Host file permissions.
HostOpenFlags
Host flags for opening files.
MemoryRegion
A descriptor for a region of memory.
ThreadId
A thread identifier. In the RSP this is just a numeric handle that is passed across the wire. It needn’t correspond to any real thread or process id (though obviously it may be more convenient when it does).
Watchpoint
A descriptor for a watchpoint. The particular semantics of the watchpoint (watching memory for read or write access) are addressed elsewhere.

Enums§

Error
An error as returned by a Handler method.
HostErrno
Errno values for Host I/O operations.
Id
Part of a process id.
ProcessType
The qAttached packet lets the client distinguish between attached and created processes, so that it knows whether to send a detach request when disconnecting.
SetThreadFor
Defines target for the set_current_thread command.
Signal
All signals that GDB define. These are cross-platform numbers.
StopReason
The possible reasons for a thread to stop.
SymbolLookupResponse
Symbol lookup response.
VCont
vCont commands
VContFeature
The name of certain vCont features to be addressed when queried for which are supported.

Traits§

FileSystem
TODO: doc
Handler
This trait should be implemented by servers. Methods in the trait generally default to returning Error::Unimplemented; but some exceptions are noted below. Methods that must be implemented in order for the server to work at all do not have a default implementation.

Functions§

process_packets_from
Read gdbserver packets from reader and call methods on handler to handle them and write responses to writer.

Type Aliases§

IOResult
The result type for host I/O operations. Return error if the operation in question is not implemented. Otherwise, the success type indicates whether the operation succeeded, with HostErrno values for failure.