diff --git a/libcelt/arch.h b/libcelt/arch.h index 70f1d90527f128f6284d83eee40f2d277b5c5cbe..f5a253a258ff7ef3c816f59211bd3f71905befb3 100644 --- a/libcelt/arch.h +++ b/libcelt/arch.h @@ -237,6 +237,12 @@ typedef float celt_mask_t; #endif /* !CONFIG_TI_C54X */ - +#ifndef GLOBAL_STACK_SIZE +#ifdef FIXED_POINT +#define GLOBAL_STACK_SIZE 25000 +#else +#define GLOBAL_STACK_SIZE 40000 +#endif +#endif #endif /* ARCH_H */ diff --git a/libcelt/stack_alloc.h b/libcelt/stack_alloc.h index 5be97273b093c0af49747d718b22d0cddd421e1e..9fae6f53f575d711ee6681a1288bd81b1c700007 100644 --- a/libcelt/stack_alloc.h +++ b/libcelt/stack_alloc.h @@ -131,7 +131,7 @@ extern char *global_stack; #define VARDECL(type, var) type *var #define ALLOC(var, size, type) var = PUSH(global_stack, size, type) #define SAVE_STACK char *_saved_stack = global_stack; -#define ALLOC_STACK (global_stack = (global_stack==0) ? celt_alloc_scratch(25000) : global_stack) +#define ALLOC_STACK (global_stack = (global_stack==0) ? celt_alloc_scratch(GLOBAL_STACK_SIZE) : global_stack) #endif