added max stage