simplify rmq in rmm tree