From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13962 invoked by alias); 15 Jun 2004 22:42:36 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 13952 invoked from network); 15 Jun 2004 22:42:35 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 15 Jun 2004 22:42:35 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.10/8.12.10) with ESMTP id i5FMgYe1010955 for ; Tue, 15 Jun 2004 18:42:34 -0400 Received: from zenia.home.redhat.com (porkchop.devel.redhat.com [172.16.58.2]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i5FMgX005923; Tue, 15 Jun 2004 18:42:33 -0400 To: "Xinan Tang" Cc: Subject: Re: "Info reg doesn't work" References: From: Jim Blandy Date: Tue, 15 Jun 2004 22:42:00 -0000 In-Reply-To: Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2004-06/txt/msg00160.txt.bz2 "Xinan Tang" writes: > I am porting gdb (6.1) to a new target. After adding a new target that is > similar to an existing RISC 32bit architecture, I found out two problems: > > 1. `info register' does not work. For example, if I type in `info reg', > the content of all registers are showing ZERO except PC no matter how many > instructions are executed. > > 2. Gdb can start execution from _start but can not enter main. > > Could someone please point to me which files I should take a look to fix > this problem? Or is there any FAQ to explain how to add a new target based > on an existing architecture. Well, you might try looking at gdb/doc/gdbint.texi, the GDB internals documentation. But it sounds to me like your target is having trouble supplying register values to GDB. How is GDB communicating with the debuggee? Via the remote protocol? Via ptrace? Something else?