summaryrefslogtreecommitdiffstats
path: root/fs/gfs2/glock.c
diff options
context:
space:
mode:
authorBob Peterson <rpeterso@redhat.com>2007-12-11 19:00:16 -0600
committerSteven Whitehouse <swhiteho@redhat.com>2008-01-25 08:13:31 +0000
commit5fdc2eeb5d1d3800367f471690b01fcd1fd5b963 (patch)
treed1e138b18a74541570736f933d938aa7f6e2d376 /fs/gfs2/glock.c
parent0d0868bde33273a200b33e54f4fad6099ad0c566 (diff)
downloadop-kernel-dev-5fdc2eeb5d1d3800367f471690b01fcd1fd5b963.zip
op-kernel-dev-5fdc2eeb5d1d3800367f471690b01fcd1fd5b963.tar.gz
[GFS2] Run through full bitmaps quicker in gfs2_bitfit
I eliminated the passing of an unused parameter into gfs2_bitfit called rgd. This also changes the gfs2_bitfit code that searches for free (or used) blocks. Before, the code was trying to check for bytes that indicated 4 blocks in the undesired state. The problem is, it was spending more time trying to do this than it actually was saving. This version only optimizes the case where we're looking for free blocks, and it checks a machine word at a time. So on 32-bit machines, it will check 32-bits (16 blocks) and on 64-bit machines, it will check 64-bits (32 blocks) at a time. The compiler optimizes that quite well and we save some time, especially when running through full bitmaps (like the bitmaps allocated for the journals). There's probably a more elegant or optimized way to do this, but I haven't thought of it yet. I'm open to suggestions. Signed-off-by: Bob Peterson <rpeterso@redhat.com> Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/gfs2/glock.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud