Checkpoint.
Split into a separate module.