Add iteration counter for easy debug