alloca(3BSD) (BSD System Compatibility) alloca(3BSD)
NAME
alloca - (BSD) memory allocator
SYNOPSIS
/usr/ucb/cc [flag . . . ] file . . .
#include <alloca.h>
char *alloca(int size);
DESCRIPTION
alloca allocates size bytes of space in the stack frame of the
caller, and returns a pointer to the allocated block. This
temporary space is automatically freed when the caller
returns. Note: if the allocated block is beyond the current
stack limit, the resulting behavior is undefined.
REFERENCES
brk(2), csh(1), getrlimit(2), ld(1), malloc(3C),
sigstack(3BSD), sigvec(3BSD)
Stephenson, C.J., Fast Fits, in Proceedings of the ACM 9th
Symposium on Operating Systems, SIGOPS Operating Systems
Review, vol. 17, no. 5, October 1983
Core Wars, in Scientific American, May 1984
NOTICES
alloca is machine-, compiler-, and most of all, system-
dependent. Its use is strongly discouraged.
Copyright 1994 Novell, Inc. Page 1