iminmaxstack