[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFx8nksLjQt3aECVk2Ni5FNPXxL988mEqfFgqbbubZho6w@mail.gmail.com>
Date: Tue, 18 Feb 2014 14:20:29 -0800
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: "Eric W. Biederman" <ebiederm@...ssion.com>
Cc: Miklos Szeredi <miklos@...redi.hu>,
Al Viro <viro@...iv.linux.org.uk>,
"Serge E. Hallyn" <serge@...lyn.com>,
Linux-Fsdevel <linux-fsdevel@...r.kernel.org>,
Kernel Mailing List <linux-kernel@...r.kernel.org>,
Andy Lutomirski <luto@...capital.net>,
Rob Landley <rob@...dley.net>,
Christoph Hellwig <hch@...radead.org>,
Karel Zak <kzak@...hat.com>,
"J. Bruce Fields" <bfields@...ldses.org>
Subject: Re: [PATCH 03/11] vfs: Don't allow overwriting mounts in the current
mount namespace
On Tue, Feb 18, 2014 at 1:28 PM, Eric W. Biederman
<ebiederm@...ssion.com> wrote:
>
>>
>> Minor nit: return value of any is_* function is either true or false, so why not
>> declare it bool?
>
> Because I am working on the core of the kernel and C compilers do weird
> things with bool variables (storing them in bytes...). I expected a
> type that the C compiler does not do weird things with would be more
> readily received on a path whose performance people are interested in.
Yeah, I have to say that I'm not a huge fan of "bool". It has some odd
properties, especially in memory (ie as a structure member).
For this kind of function return value it actually tends to work very
well, and in fact often generates slightly better code than "int". So
I don't _hate_ bool, and we've certainly had a lot more use creep in
lately, but I also don't really see "bool" as much of an upside.
Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists