On Fri, Apr 19, 2024 at 1:42 PM Paul Smith <psm...@gnu.org> wrote:
> The main advantages to alloca are twofold:
>
> 1) efficiency for small local buffers, which GNU Make uses a lot.
>
> 2) simplification of the code because you don't have to track this
> memory and ensure it's freed regardless of how the function returns.

Dennis, do you see an alternative that is at least equally efficient,
simple and portable?
One alternative that is equally efficient and simple is variable length arrays.
However, there is a question about portability of vla vs alloca.

regards, Dmitry

  • Re: GNU Make 4.4... Paul Smith
    • Re: GNU Mak... Dennis Clarke via Bug reports and discussion for GNU make
      • Re: GNU... Paul Smith
        • Re:... Dmitry Goncharov
          • ... Dennis Clarke via Bug reports and discussion for GNU make
          • ... Paul Smith
            • ... Dennis Clarke via Bug reports and discussion for GNU make

Reply via email to