[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAFPAmTSKXCiXNnFK0zR651ONju+ZBYE0qWUhCF9GXZRy=ieSJw@mail.gmail.com>
Date: Thu, 8 Dec 2011 12:56:22 +0530
From: Kautuk Consul <consul.kautuk@...il.com>
To: David Rientjes <rientjes@...gle.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Joe Perches <joe@...ches.com>,
Minchan Kim <minchan.kim@...il.com>,
David Vrabel <david.vrabel@...rix.com>, linux-mm@...ck.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/1] vmalloc: purge_fragmented_blocks: Acquire spinlock
before reading vmap_block
>
> That's intentional as an optimization, we don't care if
> vb->free + vb->dirty == VMAP_BBMAP_BITS && vb->dirty != VMAP_BBMAP_BITS
> would speculatively be true after we grab vb->lock, we'll have to purge it
> next time instead. We certainly don't want to grab vb->lock for blocks
> that aren't candidates, so this optimization is a singificant speedup.
Ah, I agree.
Anyway, the probability of there being too many vmap_blocks being
missed due to concurrent changes
is not quite high, so I guess its okay that a few vmap_blocks get
purged next time.
Thanks.
--
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