This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [PATCH] ia64-tdep.c: Only warn about slot numbers > 2
- To: Kevin Buettner <kevinb at cygnus dot com>
- Subject: Re: [PATCH] ia64-tdep.c: Only warn about slot numbers > 2
- From: Andrew Cagney <ac131313 at cygnus dot com>
- Date: Thu, 22 Mar 2001 10:49:02 -0500
- Cc: gdb-patches at sources dot redhat dot com,"Trond Eivind Glomsrød" <teg at redhat dot com>
- References: <1010322023410.ZM13601@ocotillo.lan>
Kevin Buettner wrote:
> + /* Warn about slot numbers greater than 2. We used to generate
> + an error here on the assumption that the user entered an invalid
> + address. But, sometimes GDB itself requests an invalid address.
> + This can (easily) happen when execution stops in a function for
> + which there are no symbols. The prologue scanner will attempt to
> + find the beginning of the function - if the nearest symbol
> + happens to not be aligned on a bundle boundary (16 bytes), the
> + resulting starting address will cause GDB to think that the slot
> + number is too large.
> +
> + So we warn about it and set the slot number to zero. It is
> + not necessarily a fatal condition, particularly if debugging
> + at the assembly language level. */
Is this a warning or an internal warning? Hmm, that in turn begs the
question: Should there be the function internal_warning() to match
internal_error()?
One of those secret plans involves adding the code:
static int been_here_before = 0;
if (! been_here_before && warning_deprecated)
{
been_here_before = 1;
internal_warning (__FILE__, __LINE__, __FUNCTION__,
"deprecated function called");
}
to all deprecated functions.
Andrew