Re: [PATCH 17 of 66] add pmd mangling generic functions

From: Linus Torvalds
Date: Thu Nov 18 2010 - 12:33:42 EST


On Thu, Nov 18, 2010 at 4:52 AM, Mel Gorman <mel@xxxxxxxxx> wrote:
> On Wed, Nov 03, 2010 at 04:27:52PM +0100, Andrea Arcangeli wrote:
>> From: Andrea Arcangeli <aarcange@xxxxxxxxxx>
>>
>> Some are needed to build but not actually used on archs not supporting
>> transparent hugepages. Others like pmdp_clear_flush are used by x86 too.
>>
>> Signed-off-by: Andrea Arcangeli <aarcange@xxxxxxxxxx>
>> Acked-by: Rik van Riel <riel@xxxxxxxxxx>
>
> Acked-by: Mel Gorman <mel@xxxxxxxxx>

I dunno. Those macros are _way_ too big and heavy to be macros or
inline functions. Why aren't pmdp_splitting_flush() etc just
functions?

There is no performance advantage to inlining them - the TLB flush is
going to be expensive enough that there's no point in avoiding a
function call. And that header file really does end up being _really_
ugly.

Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/