This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: Restoration of arg pointer in expand_builtin_setjmp_receiver
- To: rth at redhat dot com (Richard Henderson)
- Subject: Re: Restoration of arg pointer in expand_builtin_setjmp_receiver
- From: "John David Anglin" <dave at hiauly1 dot hia dot nrc dot ca>
- Date: Thu, 23 Aug 2001 23:54:39 -0400 (EDT)
- Cc: gcc-bugs at gcc dot gnu dot org
> Try this.
>
> * function.c (expand_function_end): Don't init arg_pointer_save_area.
> (get_arg_pointer_save_area): New. Create an init it here.
> (fix_lexical_addr): Use it.
> * function.h: Declare it.
> * builtins.c (expand_builtin_setjmp_receiver): Use it.
> * stmt.c (expand_nl_goto_receiver): Use it.
Looks promising. I did a quick check using a cross compiler and it now
looks like the "arg pointer" is saved and restored properly. I will run
more tests tomorrow. The vax is presently running the testsuite which
I would like to let it complete for reference.
The code generated is a bit peculiar:
addl3 ap,$4,-48(fp)
...
subl3 $4,-48(fp),ap
Why are we using `virtual_incoming_args_rtx' rather than `arg_pointer_rtx'?
There is a 4 byte offset between the two on the vax because calls pushes
an argument count. It seems a bit strange to be saving and restoring
a virtual register.
Dave
--
J. David Anglin dave.anglin@nrc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6605)