Optimize out some state machine spillage