Restoration of arg pointer in expand_builtin_setjmp_receiver
John David Anglin
dave@hiauly1.hia.nrc.ca
Thu Aug 23 20:54:00 GMT 2001
> 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)
More information about the Gcc-bugs
mailing list