It's simple maths, dividing 1 by the time taken per revolution gives you revs per second, you then multiply that by 60 to give RPM. I've shown that as two steps, but in practice you would do it in a single step.
Presume one revolution takes 10mS (0.01 seconds), you simply divide 60 by 0.01 to give 6000 RPM.
If you have more than one pulse per revolution, you just alter the top value accordingly - so if you had two pulses per revolution then you would divide into 30 instead of 60.