All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Laight <david.laight.linux@gmail.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Al Viro <viro@zeniv.linux.org.uk>,
	linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
	Christian Brauner <brauner@kernel.org>, Jan Kara <jack@suse.cz>
Subject: Re: [PATCH next 1/1] fs: Mark get_sigset_argpack() __always_inline
Date: Sat, 8 Feb 2025 19:06:00 +0000	[thread overview]
Message-ID: <20250208190600.18075c88@pumpkin> (raw)
In-Reply-To: <CAHk-=wicUO4WaEE6b010icQPpq+Gk_ZK5V2hF2iBQe-FqmBc3Q@mail.gmail.com>

On Sat, 8 Feb 2025 10:53:38 -0800
Linus Torvalds <torvalds@linux-foundation.org> wrote:

> On Sat, 8 Feb 2025 at 07:14, David Laight <david.laight.linux@gmail.com> wrote:
> >
> > Since the function is 'hot enough' to worry about avoiding the
> > overhead of copy_from_user() it must be worth forcing it to be
> > inlined.  
> 
> Hmm. gcc certainly inlines this one for me regardless.
> 
> So it's either a gcc version issue (I have gcc-14.2.1), or it's some
> build configuration thing that makes the function big enough in your
> case that gcc decides not to inline things. Do you perhaps have some
> debugging options enabled? At that point, inlining is the least of all
> problems.

gcc 12.2.0 (from debian) - so not THAT old.
clang 18 does inline it.
I've turned off pretty much everything (except page table separation).
And there isn't much unexpected in the object code.

Can the 'alternatives' be flipped so the .o doesn't contain loads of nops?
It'd be nice to see the clac and lfence.

	David

  parent reply	other threads:[~2025-02-08 19:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-08 15:13 [PATCH next 1/1] fs: Mark get_sigset_argpack() __always_inline David Laight
2025-02-08 18:53 ` Linus Torvalds
2025-02-08 18:57   ` David Laight
2025-02-08 19:06   ` David Laight [this message]
2025-02-08 20:03     ` Linus Torvalds
2025-02-08 23:05       ` David Laight
2025-02-10 13:59         ` Mateusz Guzik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250208190600.18075c88@pumpkin \
    --to=david.laight.linux@gmail.com \
    --cc=brauner@kernel.org \
    --cc=jack@suse.cz \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.