CPU Optimized the functions.
Signed-off-by: Somnath Roy <somnath.roy@sandisk.com>