Sun Feb 8 00:09:59 1998 Jeffrey A Law (law@cygnus.com)
+ * expr.c (clear_pending_stack_adjust): Handle case where a function
+ calls alloca, but the user has specified -fomit-fframe-pointer.
+
* function.c (assign_parms): Fix typo in last change.
Sat Feb 7 23:54:29 1998 Robert Lipe <robertl@dgii.com>
}
/* When exiting from function, if safe, clear out any pending stack adjust
- so the adjustment won't get done. */
+ so the adjustment won't get done.
+
+ Note, if the current function calls alloca, then it must have a
+ frame pointer regardless of the value of flag_omit_frame_pointer. */
void
clear_pending_stack_adjust ()
{
#ifdef EXIT_IGNORE_STACK
if (optimize > 0
- && ! flag_omit_frame_pointer && EXIT_IGNORE_STACK
+ && (! flag_omit_frame_pointer || current_function_calls_alloca)
+ && EXIT_IGNORE_STACK
&& ! (DECL_INLINE (current_function_decl) && ! flag_no_inline)
&& ! flag_inline_functions)
pending_stack_adjust = 0;