summaryrefslogtreecommitdiffstats
path: root/crypto/cipher.c
diff options
context:
space:
mode:
authorBob Peterson2007-12-12 02:00:16 +0100
committerSteven Whitehouse2008-01-25 09:13:31 +0100
commit5fdc2eeb5d1d3800367f471690b01fcd1fd5b963 (patch)
treed1e138b18a74541570736f933d938aa7f6e2d376 /crypto/cipher.c
parent[GFS2] Get rid of useless "found" variable in quota.c (diff)
downloadkernel-qcow2-linux-5fdc2eeb5d1d3800367f471690b01fcd1fd5b963.tar.gz
kernel-qcow2-linux-5fdc2eeb5d1d3800367f471690b01fcd1fd5b963.tar.xz
kernel-qcow2-linux-5fdc2eeb5d1d3800367f471690b01fcd1fd5b963.zip
[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 'crypto/cipher.c')
0 files changed, 0 insertions, 0 deletions