diff options
author | Mark Mitchell <mark@codesourcery.com> | 2002-10-18 23:35:40 +0000 |
---|---|---|
committer | Mark Mitchell <mmitchel@gcc.gnu.org> | 2002-10-18 23:35:40 +0000 |
commit | 483ab821df8b418706ca1763088b1f2f9171fc16 (patch) | |
tree | 17088ab6800bbdff9c6f83a72299fa33aada4853 /gcc/doc | |
parent | 90e021a061203481abb6d80e59e3b83ac26fb05d (diff) | |
download | gcc-483ab821df8b418706ca1763088b1f2f9171fc16.zip gcc-483ab821df8b418706ca1763088b1f2f9171fc16.tar.gz gcc-483ab821df8b418706ca1763088b1f2f9171fc16.tar.bz2 |
target-def.h (TARGET_ASM_OUTPUT_MI_THUNK): Default to NULL.
* target-def.h (TARGET_ASM_OUTPUT_MI_THUNK): Default to NULL.
(TARGET_ASM_OUTPUT_MI_VCALL_THUNK): Likewise.
(TARGET_ASM_OUT): Add them.
* target.h (asm_out): Add output_mi_thunk and
output_mi_vcall_thunk.
* config/alpha/alpha.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/arm/arm-protos.h (arm_output_mi_thunk): Declare.
* config/arm/arm.c (arm_output_mi_thunk): Define.
* config/arm/arm.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/cris/cris.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/frv/frv.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/i386/i386-protos.h (x86_output_mi_thunk): Adjust
prototype.
(x86_output_mi_vcall_thunk): Declare.
* config/i386/i386.c (override_options): Clear
output_mi_vcall_thunk in 64-bit mode.
(ix86_fntype_regparm): New function.
(ix86_return_pops_args): Use it.
(ia32_this_parameter): New function.
(x86_output_mi_vcall_thunk): New function.
(x86_output_mi_thunk): Use it
* config/i386/unix.h (TARGET_ASM_OUTPUT_MI_THUNK): Adjust.
(TARGET_ASM_OUTPUT_MI_VCALL_THUNK): Define.
* config/i960/i960-protos.h (i960_output_mi_thunk): Declare.
* config/i960/i960.c (i960_output_mi_thunk): New function.
* config/i960/i960.h (ASM_OUTPUT_MI_THUNK): Adjust.
* config/ia64/ia64-protos.h (ia64_output_mi_thunk): Declare.
* config/ia64/ia64.c (ia64_output_mi_thunk): Define.
* config/ia64/ia64.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/m68k/m68k-protos.h (m68k_output_mi_thunk): New function.
* config/m68k/linux.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/m68k/netbsd-elf.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/mmix/mmix.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/pa/pa.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/rs6000/sysv4.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/s390/s390-protos.h (s390_output_mi_thunk): Declare.
* config/s390/s390.c (s390_output_mi_thunk): Define.
* config/s390/s390.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/sparc/sparc.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/stormy16/stormy16.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* config/vax/vax-protos.h (vax_output_mi_thunk): Declare.
* config/vax/vax.c (vax_output_mi_thunk): Define.
* config/vax/vax.h (ASM_OUTPUT_MI_THUNK): Rename to ...
(TARGET_ASM_OUTPUT_MI_THUNK): ... this.
* doc/tm.texi: Adjust documentation.
From-SVN: r58293
Diffstat (limited to 'gcc/doc')
-rw-r--r-- | gcc/doc/tm.texi | 27 |
1 files changed, 23 insertions, 4 deletions
diff --git a/gcc/doc/tm.texi b/gcc/doc/tm.texi index c2dfd39..74231e2 100644 --- a/gcc/doc/tm.texi +++ b/gcc/doc/tm.texi @@ -4151,9 +4151,11 @@ outputting the insns in this list, usually by calling You need not define this macro if you did not define @code{DELAY_SLOTS_FOR_EPILOGUE}. -@findex ASM_OUTPUT_MI_THUNK -@item ASM_OUTPUT_MI_THUNK (@var{file}, @var{thunk_fndecl}, @var{delta}, @var{function}) -A C compound statement that outputs the assembler code for a thunk +@end table + +@findex TARGET_ASM_OUTPUT_MI_THUNK +@deftypefn {Target Hook} void TARGET_ASM_OUTPUT_MI_THUNK (FILE *@var{file}, tree @var{thunk_fndecl}, int @var{delta}, tree @var{function}) +A function that outputs the assembler code for a thunk function, used to implement C++ virtual function calls with multiple inheritance. The thunk acts as a wrapper around a virtual function, adjusting the implicit object parameter before handing control off to @@ -4184,7 +4186,24 @@ If you do not define this macro, the target-independent code in the C++ front end will generate a less efficient heavyweight thunk that calls @var{function} instead of jumping to it. The generic approach does not support varargs. -@end table +@end deftypefn + +@findex TARGET_ASM_OUTPUT_MI_VCALL_THUNK +@deftypefn {Target Hook} void TARGET_ASM_OUTPUT_MI_VCALL_THUNK (FILE *@var{file}, tree @var{thunk_fndecl}, int @var{delta}, int @var{vcall_offset}, tree @var{function}) +A function like @code{TARGET_ASM_OUTPUT_MI_THUNK}, except that if +@var{vcall_offset} is non-zero, an additional adjustment should be made +after adding @code{delta}. In particular, if @var{p} is the +adjusted pointer, the following adjustment should be made: + +@example +p += (*((ptrdiff_t **)p))[vcall_offset/sizeof(ptrdiff_t)] +@end example + +@noindent +If this function is defined, it will always be used in place of +@code{TARGET_ASM_OUTPUT_MI_THUNK}. + +@end deftypefn @node Profiling @subsection Generating Code for Profiling |