From: David Miller <davem@davemloft.net>
To: arnd@arndb.de
Cc: f.fainelli@gmail.com, jakub.kicinski@netronome.com,
jiri@mellanox.com, wang6495@umn.edu, mkubecek@suse.cz,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] [v2] ethtool: reduce stack usage with clang
Date: Thu, 07 Mar 2019 09:46:00 -0800 (PST) [thread overview]
Message-ID: <20190307.094600.334828809875646248.davem@davemloft.net> (raw)
In-Reply-To: <20190307160017.3120362-1-arnd@arndb.de>
From: Arnd Bergmann <arnd@arndb.de>
Date: Thu, 7 Mar 2019 16:58:35 +0100
> clang inlines the dev_ethtool() more aggressively than gcc does, leading
> to a larger amount of used stack space:
>
> net/core/ethtool.c:2536:24: error: stack frame size of 1216 bytes in function 'dev_ethtool' [-Werror,-Wframe-larger-than=]
>
> Marking the sub-functions that require the most stack space as
> noinline_for_stack gives us reasonable behavior on all compilers.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> v2: don't annotate dev_ethtool itself, as pointed out by Michal Kubecek
I'll apply this, but as Michal said this is just papering over the problem,
the aggregate stack allocation is still the same and very large.
next prev parent reply other threads:[~2019-03-07 17:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-07 15:58 [PATCH] [v2] ethtool: reduce stack usage with clang Arnd Bergmann
2019-03-07 16:41 ` Michal Kubecek
2019-03-07 17:46 ` David Miller [this message]
2019-03-07 22:03 ` Arnd Bergmann
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=20190307.094600.334828809875646248.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=arnd@arndb.de \
--cc=f.fainelli@gmail.com \
--cc=jakub.kicinski@netronome.com \
--cc=jiri@mellanox.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mkubecek@suse.cz \
--cc=netdev@vger.kernel.org \
--cc=wang6495@umn.edu \
/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;
as well as URLs for NNTP newsgroup(s).