Difference between revisions of "GDB"

From SEGGER Wiki
Jump to: navigation, search
(Created page with "Category:Knowledge Base GDB stands for GNU Debugger. GDB is a command line debugger available on many systems. GDB is free software released under the GNU General Public L...")
(No difference)

Revision as of 22:04, 15 August 2019

GDB stands for GNU Debugger. GDB is a command line debugger available on many systems. GDB is free software released under the GNU General Public License (GPL).


History

GDB was modeled after the DBX debugger, which came with Berkeley Unix distributions. The initial GDB was written by Richard Stallman, who started in 1986. Now it is maintained by the GDB Steering Committee which is appointed by the Free Software Foundation.

Remote operation

When debugging an Embedded System with GDB, the remote mode is used. Remote operation is when GDB runs on one machine and the program being debugged runs on another.
In this situation, GDB is the Client, talking to a remote "stub". The GDB protocol can use a serial link (UART) or TCP/IP. Modern systems almost always use TCP/IP. Typically, the remote stub is a debug probe such as J-Link, using a GDB-Server, and communicating with GDB via TCP/IP.

GDB Protocol

The GDB Protocol has evolved over the years. It is used by GDB, but has no been adopted as a somewhat standardized way for debuggers to communicate to debug probes via TCP/IP. In this scenario, the debugger is acting as client, connecting to the debug probe, acting as server. In most cases, the client (debugger) and the server run on the same machine, so the client connects to a port on localhost.