This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: dwarf2/ACCUMULATE_OUTGOING_ARGS fix


>>>>> "Jan" == Jan Hubicka <jh@suse.cz> writes:

>> > Simply because the i386 "pascal" convention makes function to
>> > deallocate the stack after return.  This needs to be handled with
>> > -maccumulate-outgoing-args by adjusting stack back after the return.
>> 
>> Why does this need to happen for EH unwinding?  If we're returning via
>> exception, we won't have run the epilogue which would have deallocated
>> the stack.  The args_size stuff is there to handle caller-pop semantics.

> You've missed what I am saying.  The sequence is

> pascal function call changing stack pointer
> ..
> <some code>
> ..
> lazy update of stack back to original value
> <some branch>

> If exception happends in <some code>, the information about stack offset is
> bogus.  This is rare case, but can actually happen.

It can?  But the adjustment is emitted immediately after the call, and only
calls can throw.  Surely the scheduler wouldn't move a stack adjustment
past a call?

Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]