aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@gcc.gnu.org>2004-10-13 14:09:05 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2004-10-13 14:09:05 +0000
commit65e71cd6353d3b269d6fa13a48f4cc87edcb184a (patch)
tree402f646b4bc79cb380c0b2c3a633faae0120a075
parentb9bf58e5fa4b31a077b5fe0711b7884f5d0148ed (diff)
downloadgcc-65e71cd6353d3b269d6fa13a48f4cc87edcb184a.zip
gcc-65e71cd6353d3b269d6fa13a48f4cc87edcb184a.tar.gz
gcc-65e71cd6353d3b269d6fa13a48f4cc87edcb184a.tar.bz2
Fix incomplete commit.
From-SVN: r88986
-rw-r--r--gcc/doc/tm.texi31
1 files changed, 16 insertions, 15 deletions
diff --git a/gcc/doc/tm.texi b/gcc/doc/tm.texi
index 8ca2a9a..dbdb614 100644
--- a/gcc/doc/tm.texi
+++ b/gcc/doc/tm.texi
@@ -4374,7 +4374,7 @@ You need not define this macro if you did not define
@code{DELAY_SLOTS_FOR_EPILOGUE}.
@end defmac
-@deftypefn {Target Hook} void TARGET_ASM_OUTPUT_MI_THUNK (FILE *@var{file}, tree @var{thunk_fndecl}, HOST_WIDE_INT @var{delta}, tree @var{function})
+@deftypefn {Target Hook} void TARGET_ASM_OUTPUT_MI_THUNK (FILE *@var{file}, tree @var{thunk_fndecl}, HOST_WIDE_INT @var{delta}, HOST_WIDE_INT @var{vcall_offset}, 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,
@@ -4388,7 +4388,15 @@ in C++. This is the incoming argument @emph{before} the function prologue,
e.g.@: @samp{%o0} on a sparc. The addition must preserve the values of
all other incoming arguments.
-After the addition, emit code to jump to @var{function}, which is a
+Then, if @var{vcall_offset} is nonzero, 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:
+
+@smallexample
+p += (*((ptrdiff_t **)p))[vcall_offset/sizeof(ptrdiff_t)]
+@end smallexample
+
+After the additions, emit code to jump to @var{function}, which is a
@code{FUNCTION_DECL}. This is a direct pure jump, not a call, and does
not touch the return address. Hence returning from @var{FUNCTION} will
return to whoever called the current @samp{thunk}.
@@ -4408,19 +4416,12 @@ front end will generate a less efficient heavyweight thunk that calls
not support varargs.
@end deftypefn
-@deftypefn {Target Hook} void TARGET_ASM_OUTPUT_MI_VCALL_THUNK (FILE *@var{file}, tree @var{thunk_fndecl}, HOST_WIDE_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 nonzero, 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:
-
-@smallexample
-p += (*((ptrdiff_t **)p))[vcall_offset/sizeof(ptrdiff_t)]
-@end smallexample
-
-@noindent
-If this function is defined, it will always be used in place of
-@code{TARGET_ASM_OUTPUT_MI_THUNK}.
+@deftypefn {Target Hook} bool TARGET_ASM_CAN_OUTPUT_MI_THUNK (tree @var{thunk_fndecl}, HOST_WIDE_INT @var{delta}, HOST_WIDE_INT @var{vcall_offset}, tree @var{function})
+A function that returns true if TARGET_ASM_OUTPUT_MI_THUNK would be able
+to output the assembler code for the thunk function specified by the
+arguments it is passed, and false otherwise. In the latter case, the
+generic approach will be used by the C++ front end, with the limitations
+previously exposed.
@end deftypefn
@node Profiling