This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: basic_block index negative?
- To: Daniel Egger <degger at fhm dot edu>
- Subject: Re: basic_block index negative?
- From: Diego Novillo <dnovillo at redhat dot com>
- Date: Wed, 17 Oct 2001 11:11:55 -0400
- Cc: GCC Mailinglist <gcc at gcc dot gnu dot org>
- Organization: Red Hat Canada
- References: <1003321482.21926.4.camel@sonja>
On Wed, 17 Oct 2001, Daniel Egger wrote:
> I'm heftyly whacking the gcc sources at the moment because of all this
> signedness in the sources. Can someone please explain to me how the
> index of a basic_block is supposed to become negative? And if not,
> how can the return in this snippet
>
> if (then_bb->index < 0)
> return FALSE;
>
ENTRY_BLOCK_PTR and EXIT_BLOCK_PTR have negative index numbers
(-1 and -2 respectively).
It's also important to keep the index as a signed int to allow
reverse traversals of the bb array.
Diego.