This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Question about memory allocation in ifcvt.c


On Sun, Oct 14, 2012 at 1:40 AM, Andrew Pinski <pinskia@gmail.com> wrote:
>
> Maybe Ian can mention why he used alloca there instead of xmalloc.

It was a long time ago, but I expect it was just because alloca is
usually fine for memory that has to live for just a single function.
As a single-threaded program, GCC doesn't normally have severe limits
on stack size.  This can't have been too big a problem, as I added the
code in GCC 4.2 and this is the first complaint I've seen.

In any case, as Steven points out, this has been fixed in mainline.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]