#include "petscis.h" PetscErrorCode ISSetPermutation(IS is)Logically Collective on IS
The debug version of the libraries (./configure --with-debugging=1) checks if the index set is actually a permutation. The optimized version just believes you.
Note: The IS will be considered a permutation permanently, even if indices have been changes (for example, with ISGeneralSetIndices()). It's a good idea to only set this property if the IS will not change in the future. To clear this property, use ISClearInfoCache().