i guess offset can be a size of global vector. if yes, we need to use PetscInt here.