From: Arkadiusz Drabczyk Date: Tue, 20 Oct 2015 05:52:00 +0000 (+0000) Subject: [PATCH] c/67925 - update documentation on `inline' X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=620cf5ea84a3da4730462b553c5e3c17e39d8ed9;p=gcc.git [PATCH] c/67925 - update documentation on `inline' * doc/extend.texi: Update documentation WRT inline functions. From-SVN: r229020 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a342d6a9618..7f5cbf0c5a2 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2015-10-20 Arkadiusz Drabczyk + + * doc/extend.texi: Update documentation WRT inline functions. + 2015-10-20 Alan Modra PR go/66870 diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi index 60e47e1d52e..bdbf51340d2 100644 --- a/gcc/doc/extend.texi +++ b/gcc/doc/extend.texi @@ -7088,21 +7088,19 @@ function are integrated into the caller, and the function's address is never used, then the function's own assembler code is never referenced. In this case, GCC does not actually output assembler code for the function, unless you specify the option @option{-fkeep-inline-functions}. -Some calls cannot be integrated for various reasons (in particular, -calls that precede the function's definition cannot be integrated, and -neither can recursive calls within the definition). If there is a -nonintegrated call, then the function is compiled to assembler code as -usual. The function must also be compiled as usual if the program -refers to its address, because that can't be inlined. +If there is a nonintegrated call, then the function is compiled to +assembler code as usual. The function must also be compiled as usual if +the program refers to its address, because that can't be inlined. @opindex Winline Note that certain usages in a function definition can make it unsuitable -for inline substitution. Among these usages are: variadic functions, use of -@code{alloca}, use of variable-length data types (@pxref{Variable Length}), -use of computed goto (@pxref{Labels as Values}), use of nonlocal goto, -and nested functions (@pxref{Nested Functions}). Using @option{-Winline} -warns when a function marked @code{inline} could not be substituted, -and gives the reason for the failure. +for inline substitution. Among these usages are: variadic functions, +use of @code{alloca}, use of computed goto (@pxref{Labels as Values}), +use of nonlocal goto, use of nested functions, use of @code{setjmp}, use +of @code{__builtin_longjmp} and use of @code{__builtin_return} or +@code{__builtin_apply_args}. Using @option{-Winline} warns when a +function marked @code{inline} could not be substituted, and gives the +reason for the failure. @cindex automatic @code{inline} for C++ member fns @cindex @code{inline} automatic for C++ member fns