Re: [PATCH] mm/page_alloc.c: drop dead destroy_compound_page()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jan 09, 2015 at 04:24:19PM -0800, Andrew Morton wrote:
> On Thu,  8 Jan 2015 16:10:04 +0200 (EET) "Kirill A. Shutemov" <kirill.shutemov@xxxxxxxxxxxxxxx> wrote:
> 
> > Something like this?
> > 
> > >From 5fd481c1c521112e9cea407f5a2644c9f93d0e14 Mon Sep 17 00:00:00 2001
> > From: "Kirill A. Shutemov" <kirill.shutemov@xxxxxxxxxxxxxxx>
> > Date: Thu, 8 Jan 2015 15:59:23 +0200
> > Subject: [PATCH] mm: more checks on free_pages_prepare() for tail pages
> > 
> > Apart form being dead, destroy_compound_page() did some potentially
> > useful checks. Let's re-introduce them in free_pages_prepare(), where
> > they can be acctually triggered.
> > 
> > compound_order() assert is already in free_pages_prepare(). We have few
> > checks for tail pages left.
> > 
> 
> I'm thinking we avoid the overhead unless CONFIG_DEBUG_VM?

That's why there's "if (!IS_ENABLED(CONFIG_DEBUG_VM))". Is it wrong in
some way?
I didn't check, but I assume compiler is smart enough to get rid of
free_tail_pages_check() if CONFIG_DEBUG_VM is not defined. No?


-- 
 Kirill A. Shutemov

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]