This is the mail archive of the
mailing list for the GCC project.
Re: Mapping calls to declarations
- To: Richard Henderson <rth at redhat dot com>
- Subject: Re: Mapping calls to declarations
- From: James Montgomerie <jrmg at dcs dot ed dot ac dot uk>
- Date: Tue, 14 Aug 2001 22:24:29 +0100
- CC: Daniel Berlin <dan at cgsoftware dot com>,<gcc at gcc dot gnu dot org>
on 14/8/01 5:19 pm, Richard Henderson at email@example.com wrote:
> On Tue, Aug 14, 2001 at 04:34:06PM +0100, James Montgomerie wrote: This seems
> to work, but the casting from pointers to ints and back makes me generally
> 'nervous'. If there's another, less messy, solution, I'd still be grateful if
> it was pointed out.
> Make the int be an index into an array in the backend.
I thought about this at first (both having an array of information and
having an array of pointers to allocated information), but thought it was
unsuitable because it would mean imposing a hard limit on the number of
function calls that can be made. What number would you say is a reasonable
limit? [Is there already a fixed limit imposed by the standard or the
>> Also, my knowledge of the garbage collector is near to zero - is this a safe
>> way to allocate and use memory (i.e. my memory's not going to be de-allocated
>> before I use it)?
I take it this is 'No, it's not safe, your memory might bbe deallocated
before you use it'. Is there no safe way to dynamically allocate
garbage-collected memory in the backend?
Thanks for your help,