Services - tools - models - for embedded software development
Embecosm divider strip
  Next

Howto: Porting the GNU Debugger

Practical Experience with the OpenRISC 1000 Architecture

Jeremy Bennett

Embecosm

Application Note 3. Issue 2

November 2008


Table of Contents

1. Introduction
1.1. Rationale
1.2. Target Audience
1.3. Further Sources of Information
1.3.1. Written Documentation
1.3.2. Other Information Channels
1.4. About Embecosm
2. Overview of GDB Internals
2.1. GDB Nomenclature
2.2. Main Functional Areas and Data Structures
2.2.1. Binary File Description (BFD)
2.2.2. Architecture Description
2.2.3. Target Operations
2.2.4. Adding Commands to GDB
2.3. GDB Architecture Specification
2.3.1. Looking up an Existing Architecture
2.3.2. Creating a New Architecture
2.3.3. Specifying the Hardware Data Representation
2.3.4. Specifying the Hardware Architecture and ABI
2.3.5. Specifying the Register Architecture
2.3.6. Specifying Frame Handling
2.4. Target Operations
2.4.1. Target Strata
2.4.2. Specifying a New Target
2.4.3. struct target_ops Functions and Variables Providing Information
2.4.4. struct target_ops Functions Controlling the Target Connection
2.4.5. struct target_ops Functions to Access Memory and Registers
2.4.6. struct target_ops Functions to Handle Breakpoints and Watchpoints
2.4.7. struct target_ops Functions to Control Execution
2.5. Adding Commands to GDB
2.6. Simulators
2.7. Remote Serial Protocol (RSP)
2.7.1. RSP Client Implementation
2.7.2. RSP Server Implementation
2.8. GDB File Organization
2.9. Testing GDB
2.10. Documentation
2.11. Example Procedure Flows in GDB
2.11.1. Initial Start Up
2.11.2. The GDB target Command
2.11.3. The GDB load Command
2.11.4. The GDB break Command
2.11.5. The GDB run Command
2.11.6. The GDB backtrace Command
2.11.7. The GDB continue Command after a Breakpoint
2.12. Summary: Steps to Port a New Architecture to GDB
3. The OpenRISC 1000 Architecture
3.1. The OpenRISC 1000 JTAG Interface
3.2. The OpenRISC 1000 Remote JTAG Protocol
3.3. Application Binary Interface (ABI)
3.4. Or1ksim: the OpenRISC 1000 Architectural Simulator
4. Porting the OpenRISC 1000 Architecture
4.1. BFD Specification
4.2. OpenRISC 1000 Architecture Specification
4.2.1. Creating struct gdbarch
4.2.2. OpenRISC 1000 Hardware Data Representation
4.2.3. Information Functions for the OpenRISC 1000 Architecture
4.2.4. OpenRISC 1000 Register Architecture
4.2.5. OpenRISC 1000 Frame Handling
4.3. OpenRISC 1000 JTAG Remote Target Specification
4.3.1. Creating struct target_ops for OpenRISC 1000
4.3.2. OpenRISC 1000 Target Functions and Variables Providing Information
4.3.3. OpenRISC 1000 Target Functions Controlling the Connection
4.3.4. OpenRISC 1000 Target Functions to Access Memory and Registers
4.3.5. OpenRISC 1000 Target Functions to Handle Breakpoints and Watchpoints
4.3.6. OpenRISC 1000 Target Functions to Control Execution
4.3.7. OpenRISC 1000 Target Functions to Execute Commands
4.3.8. The Low Level JTAG Interface
4.4. The OpenRISC 1000 Disassembler
4.5. OpenRISC 1000 Specific Commands for GDB
4.5.1. The info spr Command
4.5.2. The spr Command
5. Summary
Glossary
References
Index
Embecosm divider strip