Phase stability of glasses