Macro based records for LMS.

Review by @TiarkRompf @namin