Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 0d84909d authored by Sandeep Dhavale's avatar Sandeep Dhavale
Browse files

libsnapshot: Use words for xor ops



Use words instead of doing xor byte-by-byte for the entire buffer.
Profiling this with unittest, I can see the xor ops is much faster.

Also handle the word size appropriately for 32bit and 64bit platforms.

simpleperf shows that ProcessXorOp() is atleast 30% faster.
Similar improvement is seen for ProcessXorData().

Test: snapuserd_test
Bug: 369905394
Change-Id: I0bd8586f7fc1bf184f19320667b8195b07f9cdf2
Signed-off-by: default avatarSandeep Dhavale <dhavale@google.com>
parent 14807185
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment