implement vsfsm_sync_t which can be critical or semaphore