From: "Måns Rullgård" <mans@mansr.com>
To: Behan Webster <behanw@converseincode.com>
Cc: Christoph Hellwig <hch@infradead.org>,
dl9pf@gmx.de, David Woodhouse <David.Woodhouse@intel.com>,
Matthew Garrett <matthew.garrett@nebula.com>,
ibm-acpi-devel@lists.sourceforge.net,
platform-driver-x86@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] x86, acpi: LLVMLinux: Remove nested functions from Thinkpad ACPI
Date: Wed, 12 Feb 2014 21:27:59 +0000 [thread overview]
Message-ID: <yw1xzjlw58dc.fsf@unicorn.mansr.com> (raw)
In-Reply-To: <52FBE5A5.3040602@converseincode.com> (Behan Webster's message of "Wed, 12 Feb 2014 13:20:37 -0800")
Behan Webster <behanw@converseincode.com> writes:
> On 02/12/14 13:11, Christoph Hellwig wrote:
>> On Wed, Feb 12, 2014 at 09:58:46PM +0100, dl9pf@gmx.de wrote:
>>> being able to compile the Linux kernel with Clang. The use of nested functions
>>> blocks this effort.
>> Is there any good way to make gcc warn about the use of nested functions?
> Interesting idea.
>
> '-Wtrampolines'
> Warn about trampolines generated for pointers to nested functions.
>
> A trampoline is a small piece of data or code that is created at
> run time on the stack when the address of a nested function is
> taken, and is used to call the nested function indirectly. For
> some targets, it is made up of data only and thus requires no
> special treatment. But, for most targets, it is made up of code
> and thus requires the stack to be made executable in order for the
> program to work properly.
>
> That might work.
That sounds like it will only warn if a trampoline is needed. A nested
function whose address isn't taken, as is the case here, wouldn't
trigger this warning.
--
Måns Rullgård
mans@mansr.com
next prev parent reply other threads:[~2014-02-12 21:34 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-12 20:58 [PATCH] x86, acpi: LLVMLinux: Remove nested functions from Thinkpad ACPI dl9pf
2014-02-12 21:11 ` Christoph Hellwig
2014-02-12 21:20 ` Behan Webster
2014-02-12 21:27 ` Måns Rullgård [this message]
2014-02-12 21:32 ` Richard Weinberger
2014-02-12 21:54 ` David Rientjes
2014-02-12 22:01 ` Al Viro
2014-02-13 13:03 ` Henrique de Moraes Holschuh
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=yw1xzjlw58dc.fsf@unicorn.mansr.com \
--to=mans@mansr.com \
--cc=David.Woodhouse@intel.com \
--cc=behanw@converseincode.com \
--cc=dl9pf@gmx.de \
--cc=hch@infradead.org \
--cc=ibm-acpi-devel@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=matthew.garrett@nebula.com \
--cc=platform-driver-x86@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