Cleaning up mpi pack/unpack calls