public inbox for linux-crypto@vger.kernel.org
 help / color / mirror / Atom feed
From: "Arnd Bergmann" <arnd@arndb.de>
To: "Alexander Potapenko" <glider@google.com>,
	"Arnd Bergmann" <arnd@kernel.org>
Cc: "David S . Miller" <davem@davemloft.net>,
	"Herbert Xu" <herbert@gondor.apana.org.au>,
	linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] crypto: wp512: disable kmsan checks in wp512_process_buffer()
Date: Fri, 16 Dec 2022 19:29:53 +0100	[thread overview]
Message-ID: <aa26bed0-dd8e-4fac-9606-91769eee96b8@app.fastmail.com> (raw)
In-Reply-To: <20221216160841.2061759-1-glider@google.com>

On Fri, Dec 16, 2022, at 17:08, Alexander Potapenko wrote:
>> The memory sanitizer causes excessive register spills in this function:
>
>> crypto/wp512.c:782:13: error: stack frame size (2104) exceeds limit (2048) in 'wp512_process_buffer' [-Werror,-Wframe-larger-than]
>
>> Assume that this one is safe, and mark it as needing no checks to
>> get the stack usage back down to the normal level.
>
> KMSAN indeed bloats the stack frames heavily.
> Wouldn't it be more preferable to further increase KMSAN's 
> -Wframe-larger-than limit instead?
> It is not intended for production anyway, and detecting a runtime stack 
> overflow in the debug mode should not be a problem.

I don't actually see a lot of compiler warnings with KMSAN
hitting the limit, I think we can deal with them individually.

I'd rather not raise the limit more, as that makes it harder
to identify functions that use more stack than they should.

    Arnd

  reply	other threads:[~2022-12-16 18:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-15 16:29 [PATCH] crypto: wp512: disable kmsan checks in wp512_process_buffer() Arnd Bergmann
2022-12-16 16:08 ` Alexander Potapenko
2022-12-16 18:29   ` Arnd Bergmann [this message]
2022-12-30 15:14 ` Herbert Xu

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=aa26bed0-dd8e-4fac-9606-91769eee96b8@app.fastmail.com \
    --to=arnd@arndb.de \
    --cc=arnd@kernel.org \
    --cc=davem@davemloft.net \
    --cc=glider@google.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox