On phase transition and vortex stability in the generalized XY models