verify.c: extract some helper functions for isl based verification