ex23 performance tests for memcpy and memmove along with refactoring