Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Maxim Grigoriev <maxim@tensilica.com>
To: Jim Blandy <jimb@codesourcery.com>
Cc: Maxim Grigoriev <maxim@tensilica.com>,
	  gdb-patches@sources.redhat.com,
	Bob Wilson <bwilson@tensilica.com>,
	  chris Zankel <zankel@tensilica.com>
Subject: Re: Xtensa port
Date: Fri, 22 Sep 2006 23:59:00 -0000	[thread overview]
Message-ID: <451478E8.3060603@hq.tensilica.com> (raw)
In-Reply-To: <m3odt74p5x.fsf@codesourcery.com>

Hi Jim,
> I haven't looked at the code closely, but I have a few questions.
>
> - Where does xtensa-config.h come from?
>   
It's been already submitted as a part of Xtensa BFD. It comes from
/cvs/src/src/include/xtensa-config.h
> - Does xtensa-config.c need to be listed in ALLDEPFILES as well?
>   
You're right, thank you. I modified Makefile.in. So it will be reflected 
in the corrected patch I send after all the suggestions are handled 
properly.
> - I don't see anything that actually plugs in xtensa-linux-tdep.o.
>   Should that be kept out until the linux target is ready?
>   
I don't know. I was thinking in advance. The next update is supposed to 
be submitted shortly after the first one.
> - In your DejaGnu config files, there is a way to tell GDB not to run
>   tests that depend on the inferior being able to do I/O; this is used
>   to run the tests against embedded systems that don't implement the
>   semi-hosting protocol packets, like yours.  Look for uses of
>   'gdb_skip_stdio_test'.
>   
Some of the functionality covered in "stdio.h" is implemented on the 
level of FILEIO protocol, which I treat as a subset of GDB remote 
protocol. Tensilica OCD daemon supports FILEIO. And, I introduced a 
target library, which, when linked with a stand-alone Xtensa program, 
allows to use FILEIO through OCD. So I think using "gdb_skip_stdio_test" 
would be too restrictive.
> - Can you explain more about the differences between the
>   Xtensa-generated DWARF and what GDB expects?  Ideally, GDB should
>   accept DWARF from any compiler, but because DWARF is so flexible
>   it's easy for inappropriate expectations to creep in.
>   
In most such cases, I'd treat Tensilica compiler misbehavior as a bug. 
As a matter of fact, many of these cases are already filed as "Problem 
Reports" against compiler in Tensilica GNUTS. Examples:

1) Wrong line-number information for multi-line source code:
1:if (a
2: && b
3: && c)
the debugging information for the if-clause points to line 3 in XCC.

2) Sometimes, Tensilica compiler drops type qualifiers, such as volatile 
and const.

3) In some cases, typedef'd types have no debugging information. Example:

typedef int t_int;
int main(void) { return 0; }

4) When the program is compiled with "-O2 -g", there are issues with 
scoping for variables;

5) Tensilica compiler does not always add a file information in the 
debugging information;

There is more stuff like this, but this is all about our compiler, which 
is probably not interesting for the GDB community.

I hope I answered your questions.

-- Maxim









      reply	other threads:[~2006-09-22 23:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-22 18:25 Maxim Grigoriev
2006-09-22 18:52 ` Michael Snyder
2006-09-22 19:11   ` Maxim Grigoriev
2006-09-22 20:11     ` Michael Snyder
2006-09-22 21:48       ` Maxim Grigoriev
2006-09-22 23:53         ` Daniel Jacobowitz
2006-09-22 19:07 ` Daniel Jacobowitz
2006-09-22 19:39   ` Maxim Grigoriev
2006-09-22 20:32 ` Jim Blandy
2006-09-22 23:59   ` Maxim Grigoriev [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=451478E8.3060603@hq.tensilica.com \
    --to=maxim@tensilica.com \
    --cc=bwilson@tensilica.com \
    --cc=gdb-patches@sources.redhat.com \
    --cc=jimb@codesourcery.com \
    --cc=zankel@tensilica.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox