aboutsummaryrefslogtreecommitdiff
path: root/gcc/doc
diff options
context:
space:
mode:
authorKai Tietz <kai.tietz@onevision.com>2010-04-09 08:58:00 +0000
committerKai Tietz <ktietz@gcc.gnu.org>2010-04-09 10:58:00 +0200
commit3e65f25191da23215ba847ed49d10af5cf207490 (patch)
treef27eae49df0a1d17560380b81541562295afd47c /gcc/doc
parentc688a8b0d72f822e1bb6541bd97814ee6e88614a (diff)
downloadgcc-3e65f25191da23215ba847ed49d10af5cf207490.zip
gcc-3e65f25191da23215ba847ed49d10af5cf207490.tar.gz
gcc-3e65f25191da23215ba847ed49d10af5cf207490.tar.bz2
cygming.h (TARGET_OS_CPP_BUILTINS): Add __thiscall and _thiscall as predefined macros.
2010-04-09 Kai Tietz <kai.tietz@onevision.com> * config/i386/cygming.h (TARGET_OS_CPP_BUILTINS): Add __thiscall and _thiscall as predefined macros. * config/i386/i386.c (ix86_handle_cconv_attribute): Add thiscall attribute handling. (ix86_comp_type_attributes): Likewise. (ix86_function_regparm): Likewise. (ix86_return_pops_args): Likewise. (init_cumulative_args): Likewise. (find_drap_reg): Likewise. (ix86_static_chain): Likewise. (x86_this_parameter): Likewise. (x86_output_mi_thunk): Likewise. (ix86_attribute_table): Add description for thiscall attribute. * config/i386/i386.h (ix86_args): Adjust comment for member fastcall. * doc/extend.texi: Add documentation for thiscall. From-SVN: r158155
Diffstat (limited to 'gcc/doc')
-rw-r--r--gcc/doc/extend.texi12
1 files changed, 12 insertions, 0 deletions
diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi
index 78d9093..0e499cc 100644
--- a/gcc/doc/extend.texi
+++ b/gcc/doc/extend.texi
@@ -2323,6 +2323,18 @@ and other typed arguments are passed on the stack. The called function will
pop the arguments off the stack. If the number of arguments is variable all
arguments are pushed on the stack.
+@item thiscall
+@cindex functions that pop the argument stack on the 386
+On the Intel 386, the @code{thiscall} attribute causes the compiler to
+pass the first argument (if of integral type) in the register ECX.
+Subsequent and other typed arguments are passed on the stack. The called
+function will pop the arguments off the stack.
+If the number of arguments is variable all arguments are pushed on the
+stack.
+The @code{thiscall} attribute is intended for C++ non-static member functions.
+As gcc extension this calling convention can be used for C-functions
+and for static member methods.
+
@item format (@var{archetype}, @var{string-index}, @var{first-to-check})
@cindex @code{format} function attribute
@opindex Wformat