| In our country, the development of embedded hardware changes with each passing day. Some CPU has been developed, such as Dragon Chip, Area Chip, China Core and so on. Whether it is for the needs of hardware generalization or the needs in developing complex embedded software, a suitable development tools must be provided which can obviously improve the efficiency of development, and the debugger is an absolutely necessary part. Currently, the study on technology about debugger is less in our country, most of the debugger tools are provided by foreign company. So it is meaning to study the debugging technology deeply and develop the debugger of ourselves.The author studyed the source code of GDB, maked an improvement, and developed a special cross debugger for M*Core/C*Core successfully, this debugger has been widely used.This paper introduced the concept of embedded system, the embedded software integrated development environment, the debugger and the theory concerned with the debugger design&implementation. Because the design and implementation of the debugger is concerned with the special object file format and debug information format, so this paper put emphasis on introduction of the ELF object file format and the Stabs format for debug information, and also provided the data struct for operating the debug information. This paper also introduced the implementation of the basic function of the debugger, the remote communication protocol, the MI mode of the GDB. And at last an encapsulation of the GDB is implemented, the definition of the interface is also provided. |