Datasheet

The C and C++ Libraries
4-102 Copyright © 1999-2001 ARM Limited. All rights reserved. ARM DUI 0067D
alloca()
must not be called through a function pointer. You must take care when using
alloca()
and
setjmp()
in the same function, because memory allocated by
alloca()
between calling
setjmp()
and
longjmp()
is deallocated by the call to
longjmp()
.
This function is a common nonstandard extension to many C libraries.
Syntax
void* alloca(size_t size)
4.14.9 _fisatty()
The
_fisatty()
functiondetermines whether the given
stdio
stream is attached to a
terminal device or a normal file. It calls the
_sys_istty()
low-level function (see
Tailoring the input/output functions on page 4-75) on the underlying file handle.
This function is an ARM-specific library extension.
Syntax
int _fisatty(FILE *stream)
The return value indicates the stream destination:
0 A file.
1 A terminal.
Negative An error.
4.14.10 __heapstats()
The
__heapstats()
functiondisplays statistics on the state of the storage allocation heap.
It calls the
__Heap_Stats()
function, which you can re-implement if you choose to do
your own storage management (see __Heap_Stats() on page 4-65). The ARM default
implementation gives information on how many free blocks exist, and estimates their
size ranges.
Example 4-20 on page 4-103 shows an example of the output from
__heapstats()
. Line
1 of the output displays the total number of bytes, the number of free blocks, and the
average size. The following lines give an estimate the size of each block in bytes,
expressed as a range.
__heapstats()
does not give information on the number of used
blocks.