Joel Becker e798b3f8a9 ocfs2: Don't hand-code xor in ocfs2_hamming_encode().
When I wrote ocfs2_hamming_encode(), I was following documentation of
the algorithm and didn't have quite the (possibly still imperfect) grasp
of it I do now.  As part of this, I literally hand-coded xor.  I would
test a bit, and then add that bit via xor to the parity word.

I can, of course, just do a single xor of the parity word and the source
word (the code buffer bit offset).  This cuts CPU usage by 53% on a
mostly populated buffer (an inode containing utmp.h inline).

Joel

Signed-off-by: Joel Becker <joel.becker@oracle.com>
Signed-off-by: Mark Fasheh <mfasheh@suse.com>
2009-01-05 08:40:34 -08:00
..
2008-12-04 17:16:36 +11:00
2009-01-05 08:34:20 -08:00
2009-01-05 08:34:20 -08:00
2009-01-05 08:40:32 -08:00
2009-01-05 08:40:32 -08:00
2007-10-16 09:42:58 -07:00
2008-01-25 14:45:34 -08:00
2008-10-13 13:57:57 -07:00
2008-10-13 13:57:57 -07:00
2008-02-03 17:33:42 +02:00
2009-01-05 08:40:34 -08:00
2009-01-05 08:40:34 -08:00
2008-10-13 17:02:44 -07:00
2008-10-13 13:57:57 -07:00
2008-01-25 15:05:46 -08:00
2009-01-05 08:40:32 -08:00