speed up record toArray