#include "UT_Assert.h"#include <alloca.h>Go to the source code of this file.
Defines | |
| #define | UT_STACK_LIMIT 131072 |
| #define | UT_STACK_ALLOCA 100 |
| #define | UT_STACK_MALLOC 200 |
| #define | UTstackAlloc(size) |
| #define | UTstackFree(ptr) |
| #define UT_STACK_ALLOCA 100 |
Definition at line 38 of file UT_StackAlloc.h.
| #define UT_STACK_LIMIT 131072 |
Definition at line 35 of file UT_StackAlloc.h.
| #define UT_STACK_MALLOC 200 |
Definition at line 39 of file UT_StackAlloc.h.
| #define UTstackAlloc | ( | size | ) |
Value:
(void *)(&((size < UT_STACK_LIMIT) ? \ (*((int32 *)::alloca(size+2*sizeof(int32))) = UT_STACK_ALLOCA) : \ (*((int32 *)::malloc(size+2*sizeof(int32))) = UT_STACK_MALLOC)) + 2)
Definition at line 41 of file UT_StackAlloc.h.
| #define UTstackFree | ( | ptr | ) |
Value:
{ \
UT_ASSERT_P(*((int32 *)ptr - 2) == UT_STACK_MALLOC || \
*((int32 *)ptr - 2) == UT_STACK_ALLOCA); \
if (*((int32 *)ptr - 2) == UT_STACK_MALLOC) \
::free(((int32 *)ptr - 2)); \
}
Definition at line 45 of file UT_StackAlloc.h.
1.5.9