[v2,3/3] doc: -falign-functions is ignored for cold/size-optimized functions

Message ID 20221011210156.7710-4-palmer@rivosinc.com
State Accepted, archived
Headers
Series doc: -falign-functions improvements |

Checks

Context Check Description
snail/gcc-patch-check success Github commit url

Commit Message

Palmer Dabbelt Oct. 11, 2022, 9:01 p.m. UTC
  gcc/doc/ChangeLog

	* invoke.texi (-falign-functions): Mention cold/size-optimized
	functions.
---
 gcc/doc/invoke.texi | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
  

Comments

Richard Biener Nov. 14, 2022, 2:54 p.m. UTC | #1
On Tue, Oct 11, 2022 at 11:02 PM Palmer Dabbelt <palmer@rivosinc.com> wrote:
>
> gcc/doc/ChangeLog

OK.

>         * invoke.texi (-falign-functions): Mention cold/size-optimized
>         functions.
> ---
>  gcc/doc/invoke.texi | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
> index a24798d5029..6af18ae9bfd 100644
> --- a/gcc/doc/invoke.texi
> +++ b/gcc/doc/invoke.texi
> @@ -13138,7 +13138,8 @@ equal to @var{n}, skipping up to @var{m}-1 bytes.  This ensures that at
>  least the first @var{m} bytes of the function can be fetched by the CPU
>  without crossing an @var{n}-byte alignment boundary.  This does not override
>  functions that otherwise specify their own alignment constraints, such as via
> -an alignment attribute.
> +an alignment attribute.  Functions that are optimized for size, for example
> +cold functions, are not aligned.
>
>  If @var{m} is not specified, it defaults to @var{n}.
>
> --
> 2.34.1
>
  

Patch

diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index a24798d5029..6af18ae9bfd 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -13138,7 +13138,8 @@  equal to @var{n}, skipping up to @var{m}-1 bytes.  This ensures that at
 least the first @var{m} bytes of the function can be fetched by the CPU
 without crossing an @var{n}-byte alignment boundary.  This does not override
 functions that otherwise specify their own alignment constraints, such as via
-an alignment attribute.
+an alignment attribute.  Functions that are optimized for size, for example
+cold functions, are not aligned.
 
 If @var{m} is not specified, it defaults to @var{n}.