factoring out FSM in CU