Updated comments; only saving checkpoint if something has changed.