lkml.org 
[lkml]   [2013]   [Apr]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] bitmap: speedup in bitmap_find_free_region when order is 0
On Tue, 9 Apr 2013 15:34:44 +0900 "Chanho Min" <chanho.min@lge.com> wrote:

> >It seems excessively complicated to me. Why not change
> >bitmap_find_free_region() to skip the leading all-ones words and when
> >it finds a not-all-ones word, adjust `pos' then fall into the existing
> >bit-at-a-time search?
>
> Do we need the additional 'if' inside the for loop for implementing it?

It was just a concept - there are various ways of optimizing a real
implementation. Move the code into userspace then run some
microbenchmarks.

> I thought the separation of the routine for order=0 is the way to avoid
> the impact on the existing codes and its performance.

The existing code doesn't have any performance ;) It's so darn slow
that even a minor effort here will yield large (ie order-of-magnitude)
performance improvements.


\
 
 \ /
  Last update: 2013-04-10 04:41    [W:0.053 / U:0.908 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site