Revised for speed.