Program being debugged

Before debugging, another thing to consider is the type of program that is being debugged. The image being debugged determines the level of complexity for both the debug operations and the information that you obtain from a debugger.

Here is a list of different types of programs that you might work with, and some things to remember about each of them:

Bare-metal and boot code
  • Directly uses the architectural features of a processor
  • Usually contains a mix of source and assembly files
  • Usually less overhead when performing debug operations
  • Easy to determine the order of execution
  • Debug information is usually not complex
  • Program memory layout is usually easy to understand
  • Memory map generally does not change during execution
  • Usually has one execution thread
  • May cross multiple Execution levels (ELs)
OS kernel
  • Directly uses the architectural features of a processor
  • Usually contains a mix of source and assembly files
  • Harder to determine the order of execution
  • Debug information is usually more complex
  • Program memory layout is more complex
  • Memory map can change during execution
  • May have more than one execution thread
OS application and OS module or driver
  • More difficult to see how processor architecture features are used
  • Usually made up of source files
  • May rely on library for which you do not have the source code
  • Harder to determine the order of execution
  • Debug information is usually very complex
  • Program memory layout is very complex
  • Memory map can change during execution
  • Usually has more than one execution thread
  • Usually requires the debugger to have some awareness of the OS being used
Previous Next