Make struct sm_state more compact.